On Sun, 24 Feb 2002 12:15:03 -0800, "BA" <[EMAIL PROTECTED]> wrote: > >hello and thanks for reading this. >i wonder the following: >if i have a page object with two buttons on it. >one button is 'add' and the other button is 'subtract' >i press one of the buttons. >what happens to the page? >1. nothing. pressing a button just calls the proper method. >2. something. the page behaves like a webform and it live ends and the >action of the form is done.
Yes. :) Both options can be implemented, although they do different things. A Webware servlet is always #2. >what i want to create is a simple calculator with webkit. >pressing the buttons calls code in my page and it does not cause the loading >of another page or another instance of the same page. > >did i make sense? Unlike Windows development, in web development you actually have TWO computers involved, and you have to think about where you want a particular action to take place. Things that happen strictly in the computer running the browser are "client side" actions, and things that happen in the computer running the web server are "server side" actions. A particular button or URL can trigger actions on either side. "Client side" actions happen entirely in the web browser. Client side code will almost always be written in either Javascript or VBscript. The code will be sent to the browser as part of the original web page. A calculator is a good example of something that can be done client-side, because you don't really need to communicate with the web server. "Server side" actions happen when the web page sends data back to the server with a form action or a URL click; the server will do whatever computations need to be done with the data, and send back a new page (or a refresh of the same page) to the browser. This is the only way to access a database on the web server; the client side has no connection to the server computer, so it can't access data on the server itself. Manipulating such a database always requires a server round-trip. Webware is entirely on the server side. A Webware servlet can certainly send embedded Javascript code in the pages it sends back to the browser so the user can operate without another round-trip, but most Webware-based apps are based strongly on form actions and URLs so that the web server machine does most of the work. So, the answer to your original question is, "it depends on what you want to do". >i as a mswindows+visual basic background. in vb or delphi or many other >products, i create a form, populate it buttons and then write code. i am >looking for this model for web development. the webware page object seems to >come close, am i right? Server-side web programming is still much more manual than you describe. There ARE tools for doing VB-like drag-and-drop web form development (such as Microsoft Front Page and Visual InterDev are two of them), but they tend to be strongly oriented towards Windows and .ASP pages. I don't know of any WYSIWYG form tools for Webware. The persistent session objects in Webware can give you the illusion of a strong connection between a web browser client and a Webware servlet on the server. However, it is not actually a direct connection. Form actions in Webware are just plain old HTML form actions; they'll send a request to a web server, which eventually sends back a new page. -- - Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. _______________________________________________ Webware-discuss mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/webware-discuss
