-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
wqweto
IMO the query string should not be escaped/decoded. My observations are that WinHttp converts query strings to utf-8 and encodes every byte with highest bit set using %XY in hex to be able to "smuggle" headers through 7-bit networks probably (no idea actually).
Perhaps I've misunderstood - but I think we have to be prepared to decode the query string (and the rest of the URL) server-side, because most browsers will encode the path/query portion of the URL. For example, this (insane) URL entered into the address bar (in Firefox):
Code:
http://127.0.0.1:8080/"test"?x=ABC DEF+"12345"
Gets sent to the server encoded:
Code:
GET /%22test%22?x=ABC%20DEF+%2212345%22 HTTP/1.1
Are you suggesting the the server should decode it, but the application on the server-side should if it wants to?
Quote:
Originally Posted by
wqweto
I think URLs are a big mess already,
Ain't that the truth ;)
Quote:
Originally Posted by
wqweto
probably would be best to make possible to submit to the http server *any* Unicode string in the query string with high fidelity i.e. convert to utf-8 and don't massage/process it too much.
Sounds like the new URLRaw property will do that, and allow the server-side app to deal with URLs (exactly as passed) however they see fit.
-
1 Attachment(s)
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
jpbro
Here's a very simple example that will evaluate formulas entered into your browsers address bar at the "evaluate/" path.
Andt how do it not through a query string, but through a simple html (or, VBML) page, as if the user is entering text?
so the plan is:
- 1) the user follows the link /calculator
- 2) enters an expression in the text box
- 3) presses the button and the request goes to the our server
- 4) the server returns the result of the expression to this page
for example like here
Attachment 183585
Purely for understanding how the user interacts with the page and the server processes the received requests.
-
Re: VB6 Web Site/App Server
Can you post the HTML source for that page? I will show you what to put on the server side.
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
jpbro
Code:
http://127.0.0.1:8080/"test"?x=ABC DEF+"12345"
Gets sent to the server encoded:
Code:
GET /%22test%22?x=ABC%20DEF+%2212345%22 HTTP/1.1
The point is that the same URL using WinHttpRequest sends this to server
Code:
GET /%22test%22?x=ABC%20DEF+"12345" HTTP/1.1
. . . and the query string is somewhat *less* encoded than what chome does.
Probably both requests use valid URL encodings because a simple %XY decoder would not be bothered if both spaces and double-quotes are encoded and decode the same query string anyway.
Technically only % character has to be additionally escaped for a simple %XY decoder to produce valid query string. This query string should probably be treated as utf-8 encoded too.
cheers,
</wqw>
-
Re: VB6 Web Site/App Server
-
1 Attachment(s)
Re: VB6 Web Site/App Server
I've just updated the first post with a new version that includes my first pass at a CBuilderHtml class. This is a helper class that makes it a bit quicker/easier to build HTML documents and HTML snippets for serving from your web apps.
Here's a snippet from the demo app that builds and serves HTML when the browser requests the /virtualdoc/ path (e.g. http://127.0.0.1:8080/virtualdoc)
Code:
ElseIf po_Helpers.Regex.Test(po_Req.Url(urlsection_Path), "^virtualdoc(|/)$", False) Then
' Found a request for a "virtual" document
' We will build using the CBuilderHtml helper.
New_C.Timing True
With po_Helpers.Builders.Html.StartDoc ' Start an HTML5 document with the default parameters.
' Now in <head> section
.AddTag "link", .BuildAttributes("rel", "stylesheet", "href", "https://cdn.simplecss.org/simple.min.css")
End With ' <head> section closes when it goes out of scope
With po_Helpers.Builders.Html.AddTag("body")
' Now in the <body> section
.AddTag "h1", , "Welcome!" ' Test of a tag with content (3rd parameter)
With .AddTag("div", .BuildAttributes("id", "content")) ' Test of tag with attributes (2nd parameter)
' Test of build a paragraph with content and inline tags (the long way)
With .AddTag("p", , "This is a test of ")
.AddTag "b", , "VBWebAppServer.CBuilderHtml"
.AddContent "."
End With ' When CHtmlTag object goes out of scope, it automatically adds the closing </p> tag to the generate HTML
.AddTag "hr" ' Test of a self-closing tag. It will automatically be added to the generated HTML and no CHtmlTag will be returned
With .AddTag("p", , "Visit the ")
' Link test
.AddTag "a", _
.BuildAttributes("href", "https://www.vbforums.com/showthread.php?893990-VB6-Web-Site-App-Server"), _
"VBWebAppFCGI thread at VBForums"
.AddContent "."
End With
' Test of simplified inline markdown content (faster way to build paragraph content with simple bold/italic/strike/superscript formatting
.AddTag "p", , "You can also add content with //simplified// inline markdown by passing **convert_InlineMarkdown** as the 2^^nd^^ parameter " & _
"of the ~~AddsContents~~ ``AddContent`` method. Test of escaping\**. [[You can even create links with markdown^^]]((https://www.vbforums.com)), " & _
"**so give the link a visit**!", contenttransform_InlineMarkdown
' Test of adding raw HTML content
.AddContent vbNewLine & "<p>You can even add raw HTML. Just make sure you escape it yourself if necessary and pass <i>contenttransform_None</i> to the second parameter of the <code>AddContent</code> method</p>", contenttransform_None
' Report how long it took to build the page
.AddTag "p", , "This page was generated in " & New_C.Timing
End With
End With
' Return the formula and the result as plain text.
po_Response.SendSimpleHtmlResponse po_Helpers.Builders.Html.HtmlString
The above generates the following HTML:
Code:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>New Page</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
<h1>Welcome!</h1>
<div id="content">
<p>This is a test of <b>VBWebAppServer.CBuilderHtml</b>.</p>
<hr>
<p>Visit the <a href="https://www.vbforums.com/showthread.php?893990-VB6-Web-Site-App-Server">VBWebAppFCGI thread at VBForums</a>.</p>
<p>You can also add content with <i>simplified</i> inline markdown by passing <b>convert_InlineMarkdown</b> as the 2<sup>nd</sup> parameter of the <strike>AddsContents</strike> <code>AddContent</code> method. Test of escaping**. <a href="https://www.vbforums.com">You can even create links with markdown^^</a>, <b>so give the link a visit</b>!</p>
<p>You can even add raw HTML. Just make sure you escape it yourself if necessary and pass <i>contenttransform_None</i> to the second parameter of the <code>AddContent</code> method</p><p>This page was generated in 0.67msec</p>
</div>
</body>
</html>
Which looks like this in the browser:
Attachment 183598
PLEASE NOTE: This is very new code, and is very lightly tested. Bugs are all but guaranteed. Please let me know if you find any and I will fix them. Also, the programming interface may change significantly as I use it more and discover shortcomings, so don't make anything serious that relies on this new feature (or any part of VBWebAppServer for that manner) yet!
Notes on VBWebAppServer's Simplified Inline Markdown
I'm using my own flavour of "markdown" (I know, I know - just what the world needs). It has just a few tags chosen to make it easier to do inline formatting of text content in HTML documents. For example, if you want bold or italic spans in a paragraph. This feature has also been lightly tested, so beware of bugs.
Consider this markdown string:
Code:
"You can also add content with //simplified// inline markdown by passing **convert_InlineMarkdown** as the 2^^nd^^ parameter of the ~~AddsContents~~ ``AddContent`` method. Test of escaping\**. [[You can even create links with markdown^^]]((https://www.vbforums.com)), **so give the link a visit**!"
It will be transformed to the following HTML:
Code:
You can also add content with <i>simplified</i> inline markdown by passing <b>convert_InlineMarkdown</b> as the 2<sup>nd</sup> parameter of the <strike>AddsContents</strike> <code>AddContent</code> method. Test of escaping**. <a href="https://www.vbforums.com">You can even create links with markdown^^</a>, <b>so give the link a visit</b>!
Here are the markdown tags and their respective HTML translations:
Code:
** -> Bold, e.g. <b></b>
// -> Italic, e.g. <i></i>
__ -> Underline, e.g. <u></u>
^^ -> Superscript, e.g. <sup></sup>
~~ -> Strikethrough, e.g. <strike></strike>
`` -> Code, e.g. <code></code>
[[LinkText]]((LinkTarget)) -> Hyperlink. e.g. <a href="LinkTarget">LinkText</a>
Enjoy!
-
Re: VB6 Web Site/App Server
Updated the source in post one, and made some small changes to the CBuilderHtml demo code to show how you can add stuff to the <head> section. Also added some more comments to make it easier to understand what's happening when building an HTML page with the CBuilderHtml class.
-
Re: VB6 Web Site/App Server
Sorry folks, I managed to muck up the last update. It's fixed now in the latest post, so if you had any trouble with yesterday's update, the latest version should be fine.
-
1 Attachment(s)
Re: VB6 Web Site/App Server
Another fun update, demonstrating how you might dynamically generate a QR code JPEG and serve it to the browser.
In the demo app, you can navigate to http://127.0.0.1:8080/qrencode/texttoencode, and a QR code image will appear in your browser. For example, here's what you see if you navigate to http://127.0.0.1:8080/qrencode/https://www.vbforums.com:
Attachment 183609
This is generated using the following code in the demo CApp class:
Code:
ElseIf po_Helpers.Regex.Test(po_Req.Url(urlsection_Path), "^qrencode/", False) Then
' Generate a QR Code image and send it back to the client as a JPEG
Dim l_QrData As String
Dim lo_QrEncode As cQREncode
Dim lo_QrImage As cCairoSurface
Dim la_QrImage() As Byte
Dim l_QrWidth As Long
Dim l_QrHeight As Long
' The portion of the requested path after "qrencode/" is the text that the client wants to encode
l_QrData = Mid$(po_Req.Url(urlsection_Path), Len("qrcode/") + 1)
Set lo_QrEncode = librc6QrEncode
If lo_QrEncode Is Nothing Then
' Uhoh! RC6Widgets.dll not found!
po_Response.SendSimplePlainTextResponse "To use the QR code feature, you must first copy RC6Widgets.dll to " & pathSystem, , 500
Else
' Encode the passed text to a QR Code image surface
Set lo_QrImage = lo_QrEncode.QREncode(StrConv(l_QrData, vbFromUnicode), , , 10)
' Add a white border around the QR code
With lo_QrImage
l_QrWidth = .Width + 20
l_QrHeight = .Height + 20
End With
Set lo_QrImage = lo_QrImage.CropSurface(-10, -10, l_QrWidth, l_QrHeight)
With lo_QrImage.CreateContext
.Rectangle 0, 0, l_QrWidth, l_QrHeight
.Rectangle 10, 10, l_QrWidth - 20, l_QrHeight - 20
.SetSourceColor vbWhite
.FillRule = CAIRO_FILL_RULE_EVEN_ODD
.Fill
End With
' Send the QR Code JPEG to the browser
lo_QrImage.WriteContentToJpgByteArray la_QrImage
po_Response.SendSimpleByteArrayResponse la_QrImage, , , "image/jpeg"
End If
Enjoy! :)
-
Re: VB6 Web Site/App Server
-
Re: VB6 Web Site/App Server
Good project, but would it be possible to do without RC6?
-
Re: VB6 Web Site/App Server
G'Day GB
Quote:
Originally Posted by
germano.barbosa
Good project
100% agree :)
Quote:
Originally Posted by
germano.barbosa
would it be possible to do without RC6?
Why don't you want to use RC6 ?
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
germano.barbosa
Good project, but would it be possible to do without RC6?
Thank you. Yes it would be possible, but a fair amount of work for little (if any) benefit IMHO. You would need to make the following replacements:
- SQLite
Use ADO and Jet instead (in many cases slower)
- cArrayList
Use the vanilla VB6 arrays (maybe better performing, but more painful for things like adding/removing elements)
- cWebServer
Roll your own using winsock API or Winsock control.
- cWebResponse/cWebRequest
Roll your own HTTP header and body parser, and WebSocket stuff (if you want to support WebSockets).
- cSortedDictionary
Use Scripting.Dictionary (slower)
- cStringBuilder
Roll your own or use one found in the codebank. Or just use vanilla VB6 string building (slower)
- cCollection
Use the vanilla VB6 Collection (slower, and without convenience methods like "Exists")
- cFSO
Use Scripting.FileSystemObject (slower)
- cCrypt
Roll your own/Use APIs for: URLEncode/URLDecode, SHA256, Cryptographic random number generation, String to UTF8 conversion.
- Cairo
Roll your own QR Encoding (or find something on the Internet). This one is optional, it was just for the demo app.
There are somewhere around 200 lines of code that use RC6 in this project. At a 10x estimate, you would need to write about 2000 lines of code to replace RC6. That's a conservative estimate, I wouldn't be surprised if you need to write more.
But the source is there if you want to fork it. I know some people don't want to use RC6, so they might appreciate your efforts!
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
jpbro
Thank you. Yes it would be possible, but a fair amount of work for little (if any) benefit IMHO. You would need to make the following replacements:
- SQLite
Use ADO instead (in many cases slower)
- cArrayList
Use the vanilla VB6 arrays (maybe better performing, but more painful for things like adding/removing elements)
- cWebServer
Roll your own using winsock API or Winsock control.
- cWebResponse/cWebRequest
Roll your own HTTP header and body parser, and WebSocket stuff (if you want to support WebSockets).
- cSortedDictionary
Use Scripting.Dictionary (slower)
- cStringBuilder
Roll your own or use one found in the codebank. Or just use vanilla VB6 string building (slower)
- cCollection
Use the vanilla VB6 Collection (slower, and without convenience methods like "Exists")
- cFSO
Use Scripting.FileSystemObject (slower)
- cCrypt
Roll your own/Use APIs for: URLEncode/URLDecode, SHA256, Cryptographic random number generation, String to UTF8 conversion.
- Cairo
Roll your own QR Encoding (or find something on the Internet). This one is optional, it was just for the demo app.
There are somewhere around 200 lines of code that use RC6 in this project. At a 10x estimate, you would need to write about 2000 lines of code to replace RC6. That's a conservative estimate, I wouldn't be surprised if you need to write more.
But the source is there if you want to fork it. I know some people don't want to use RC6, so they might appreciate your efforts!
That's a lot of work and you know I'm not a fan of re-inventing the wheel. I'd recommend that he doesn't try to re-create all this unless he wants to for the challenge of it but there is absolutely no value in reproducing sub-standard versions of something someone already created.
-
Re: VB6 Web Site/App Server
The biggest problem for me is that RC6 is not opensource, I use it for other projects, but the least, if it was opensource I wouldn't worry
-
Re: VB6 Web Site/App Server
Yea, I get it. It's not future-proof while it's survival depends on a single individual. That may change one day perhaps.
-
Re: VB6 Web Site/App Server
If you use multiple commercial controls, which are not open source and are not maintained anymore.
Are they future proof? As long as the OS and development platform supports them.
Is open source future proof? No for same reasons.
I really don't see the drive for having everything open source.
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
Arnoutdv
If you use multiple commercial controls, which are not open source and are not maintained anymore.
Are they future proof? As long as the OS and development platform supports them.
Is open source future proof? No for same reasons.
I really don't see the drive for having everything open source.
Let me highlight the important part:-
Quote:
Yea, I get it. It's not future-proof while it's survival depends on a single individual. That may change one day perhaps.
That changes everything. If Bill Gates kicks the bucket tomorrow, there will still be plenty of people at Microsoft who can make sure VB6 runs on Windows 13. God forbit it, but if Olaf shuffles off his mortal coil, then RC6 is just dead. Who will fix it when it crashes applications on Windows 13 or Windows 26?
-
Re: VB6 Web Site/App Server
And if a product is abandoned then the future is also not clear.
See the multiple threads about commercial components which are not maintained/updated anymore.
Especially for freeware, enjoy it as long as it works.
If at some point it doesn't work anymore on a newer platform I think your "own" product will have more problems then just the single non open source component.
Bet lets agree to disagree.
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
Arnoutdv
And if a product is abandoned then the future is also not clear.
See the multiple threads about commercial components which are not maintained/updated anymore.
Especially for freeware, enjoy it as long as it works.
If at some point it doesn't work anymore on a newer platform I think your "own" product will have more problems then just the single non open source component.
Bet lets agree to disagree.
I can still play the original Prince of Persia on DOSBox so I guess there's that possibility of unnatural longevity with zero developer input. ;)
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
Arnoutdv
If you use multiple commercial controls, which are not open source and are not maintained anymore.
Are they future proof? As long as the OS and development platform supports them.
Is open source future proof? No for same reasons.
I really don't see the drive for having everything open source.
I use 99% open source, not a third party control, only mine or available here on the forum
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
germano.barbosa
I use 99% open source...
Well, that's only (mostly) true when you run your VB6-IDE on Linux+Wine -
and when your customers run your App on Linux as well...
If you develop on Windows (and your compiled App runs on Windows), then you're depending on about 90% closed source -
(the OS-kernel, the OS-specific drivers, and all the libs in SysWow). ;)
Olaf
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
jpbro
Can you post the HTML source for that page? I will show you what to put on the server side.
sorry for late response
this is my html example
Code:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" />
<title>Aligning Buttons</title>
</head>
<body>
<h1 style="color:green;text-align:center;">NumberSender</h1>
<div class="container">
<div class="text-left">
<button type="button">1</button>
<button type="button">2</button>
<button type="button">3</button>
<button type="button">4</button>
<button type="button">5</button>
<button type="button">6</button>
</div>
<table width="500" border="1">
<tr>
<th>ROW #</th>
<th>COLOR #</th>
</tr>
<tr>
<td>ROW 1</td>
<td bgcolor="red">COLOR 2</td>
</tr>
<tr>
<td>ROW 2</td>
<td bgcolor="green">COLOR 5</td>
</tr>
</table>
</body>
<div>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js">
</script>
</body>
</html>
what scenario I'm need:
1) user click any button on the page
2) server receive this number of the button and insert row into table with color
3) user see updated page
-
Re: VB6 Web Site/App Server
Regarding the open/closed source thing, all I'll say is that RC6 (and earlier incarnations) is always the first reference I add to any new project I create. It makes me so much more productive that I am willing to take the risk of Olaf disappearing one day. It's not like it will just suddenly break either, but perhaps eventually an OS update will break it. I suspect that would also mean that VB6 apps will no longer work either, which would mean we even bigger problems to solve.
Anyway, if you don't like the thought of using a closed-source library, that's totally your choice. Like I said, this project is open source and you are more than welcome to fork it if you think there's value in a version without the extra dependency.
-
2 Attachment(s)
Re: VB6 Web Site/App Server
@sergeos
I've modified your HTML a bit to use Jquery for AJAX and modifying the DOM. I'm just familiar with it, so it was easier for me to create the demo. Feel free to substitute your favourite framework or just use vanilla JS if you prefer.
To start, save the following HTML to you web app root folder as "tableaddtest.html":
Code:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" />
<title>Aligning Buttons</title>
</head>
<body>
<h1 style="color:green;text-align:center;">NumberSender</h1>
<div class="container">
<div id='buttons' class="text-left">
<button type="button">1</button>
<button type="button">2</button>
<button type="button">3</button>
<button type="button">4</button>
<button type="button">5</button>
<button type="button">6</button>
</div>
<table id='mytable' width="500" border="1">
<tr>
<th>ROW #</th>
<th>COLOR #</th>
</tr>
<tr>
<td>ROW 1</td>
<td bgcolor="red">COLOR 2</td>
</tr>
<tr>
<td>ROW 2</td>
<td bgcolor="green">COLOR 5</td>
</tr>
</table>
</div>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js"></script>
<script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
<script>
// Hook each # button's click event.
$('#buttons button').click(function() {
// # button clicked
var number = $(this).text();
// Send AJAX query to the server at /numberreceiver/<number>
$.ajax({
url: "/numberreceiver/" + number,
})
.done(function( json ) {
// Add a row to the table using the JSON response from the server
json = $.parseJSON(json);
var markup = "<tr><td>ROW " + ($('#mytable tr').length) + "</td><td bgcolor=" + json.bgcolor + ">COLOR " + number + "</td><</tr>";
$("#mytable").append(markup);
if ( json.status != 200 ) { alert('Error #' + json.status + ': ' + json.errormessage); }
});
});
</script>
</body>
</html>
Then add the following code to the CApp class (somewhere after the If po_Helpers.Regex.Test(po_Req.Url(urlsection_Path), "^showcase/[0-9]+$", False) Then showcase code section:
Code:
ElseIf po_Helpers.Regex.Test(po_Req.Url(urlsection_Path), "^numberreceiver/[0-9]+$", False) Then
' Build JSON response
' JSON helper methods are forthcoming,
' but for now we'll have to use the ComplexResponse and manually add an "Content-Type: application/json" header
With po_Response.ComplexResponse
.AddHeaderEntry "Content-Type", "application/json"
Set lo_Json = New_C.JSONObject
With lo_Json
.Prop("status") = 200
' Get the color index # from the end of the URL path
.Prop("number") = Split(po_Req.Url(urlsection_Path), "/")(1)
Select Case .Prop("number")
Case 1
.Prop("bgcolor") = "purple"
Case 2
.Prop("bgcolor") = "red"
Case 3
.Prop("bgcolor") = "blue"
Case 4
.Prop("bgcolor") = "yellow"
Case 5
.Prop("bgcolor") = "green"
Case Else
' Uhoh! Unknown color index
.Prop("status") = 500
.Prop("errormessage") = "Unknown color index #" & .Prop("number")
.Prop("bgcolor") = "gray"
End Select
End With
.SetResponseDataBytes lo_Json.SerializeToJSONUTF8
End With
Finally, start the app server and navigate to http://127.0.0.1:8080/tableaddtest.html and try clicking some buttons. You should see something like this:
Attachment 183696
Until you click #6, then you will see a simulated error:
Attachment 183697
I hope the code and comments are enough to demonstrate how this type of thing can be done, but let me know if you have any questions.
-
Re: VB6 Web Site/App Server
-
Re: VB6 Web Site/App Server
Are you having a problem using this with IPv6?
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
jpbro
Are you having a problem using this with IPv6?
is it like this?
VbWebApp.exe /spawn 1 /ip 240e:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:6f30 /port 80
it returns this:
***ERROR: -2147221504 Couldn't start Listener on 127.0.0.1:80
ERROR: -2147221504 Could not start app server.
***ERROR: -2147221504 Couldn't start Listener on 127.0.0.1:80
ERROR: -2147221504 Could not start app server.
……………………………………
-
Re: VB6 Web Site/App Server
mind blowing effort!! but need documentation to create complex templates very few examples.
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
silver-surfer
mind blowing effort!! but need documentation to create complex templates very few examples.
This was/is a work in progress so unfortunately there is no documentation at this point. Can you provide more details about what are you hoping to create?
-
Re: VB6 Web Site/App Server
-
Re: VB6 Web Site/App Server
Marry Christmas
it is like php/aspx pages i have to add 3rd party js libraries like ui elements , gauges , charts and many more
-
Re: VB6 Web Site/App Server
How to make a simple web design tool with VB6? Or turn a normal VB control into a web page. The ultimate goal is to achieve cross-platform.
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
silver-surfer
Marry Christmas
A belated Merry Christmas to you :)
Quote:
Originally Posted by
silver-surfer
it is like php/aspx pages i have to add 3rd party js libraries like ui elements , gauges , charts and many more
Yes, anything running on the browser side will need its own browser-native code (JS) and UI elements. Things like gauges and charts could be rendered server side using Cairo or GDI+ though and you could send the PNGs/JPEGs/SVGs to the browser as needed. NOTE: SVGs generation would be done through Cairo only, not GDI+ AFAIK.
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
xiaoyao
How to make a simple web design tool with VB6? Or turn a normal VB control into a web page. The ultimate goal is to achieve cross-platform.
Don't think it's very feasible, but even if do-able it would be an extraordinary amount of work. Best you could hope for is an existing well-separated back-end/front-end VB6 code base, and then you only need to re-write the front-end UI for the web/browsers and get to keep all your back-end VB6 code. In my case I have about a 70/30 back-end/front-end split, so it means only rewriting the 30% front-end for the web and some glue code to convert browser requests into VB6 method calls and reply with JSON results to the browser.
-
Re: VB6 Web Site/App Server
-
Re: VB6 Web Site/App Server
It is said that API can automatically help you create websites as long as you speak.
So there's no need to design the interface anymore, it's possible.
-
Re: VB6 Web Site/App Server
Quote:
Originally Posted by
xiaoyao
It is said that API can automatically help you create websites as long as you speak.
So there's no need to design the interface anymore, it's possible.
Not sure what you're trying to say here. Yes, you can develop an API for your backend server, but it doesn't automatically help you do anything. You will still need an front-end interface unless you want to send raw API requests with Curl or something and manually parse the responses yourself (which I guess is still an interface of sorts).