|
I am new to web programming, and so far have found that trying to get stuff that seems straight forward with desktop applications to work via the web can be complicated. So if any of the assumptions I make below are incorrect let me know:
Having looked at ASP samples using VB script, buttons on a form have various properties defined in HTML (input type, name, and value).
It seems that input type defines what it is ('submit' seems to mean a button that refreshes the whole page without performing any extra code such as calling a function, etc.)
It seems that name defines the name of a button (or other object) in the samples I have seen, the name of the buttons seems to also be 'submit'? Which is a little confusing!
Finally, value appears to indicate the caption on the button itself, which if true is also kind of misleading (it should really be something like 'caption' or 'text')
Anyway in all the samples that I have, there is never more than one button on the screen, so what happens when you want two buttons on a page?
Lets say for the sake of an example, you want to have one button that when pressed displays "Hello World" in a textbox (and does this using VBScript) and another button, which when pressed displays "Good Bye World" in the same textbox?
If someone could provide a simple bit of code with this functionality (using VB Script), it would really help me to understand how buttons work on an ASP page.
Thanks in Advance,
Gareth
Last edited by gfunkera; 04-17-2006 at 04:38 PM..
|