|
Posted by Jonathan N. Little on 12/28/06 19:12
Alex wrote:
> Jonathan N. Little wrote:
>> <form action="/CaseRecord" ...
>>
>>
>>
>> <ul class="tabbedButtons">
>> <li><input type="submit" name="page" value="Surgical"></li>
>> <li><input type="submit" name="page" value="Surgical2"></li>
>> <li><input type="submit" name="page" value="Surgical3"></li>
>> <li><input type="submit" name="page" value="Surgical4"></li>
>> <li><input type="submit" name="page" value="Surgical5"></li>
>> ...
>
> Thanks for the reply, but the only problem I see is that how will the
> browser know what page to forward the user to? If the user clicks the
> tab for say page 3 and they're on page 1, I want it to forward the user
> to page 3 and not whatever page is blindly set by Action in the FORM
> tab.
Simple in my example above whatever your receiving script is at
/CaseRecord, normally you would call a discrete filename like:
"/CaseRecord/getfile.php", your /CaseRecord/?... works on a default
index.php, index.cgi, index.asp etc.
Notice that the submit buttons are named. Naming them means when click
the name=value part will be parsed. In this case page=Surgical#, so
simply fork on the page value will determine which submit button was
press and hence which page page you are on...
>
> As for submit buttons in of themselves, I'm trying to keep a themed
> look and feel with the tabbed menus, and submit buttons up there will
> look odd.
Style them whatever way you want. The advantage of NOT coding in the
1996-way
>
> Thanks again for the suggestion, but I'm not sure if it'll work for my
> application.
Actually it will, much better than any JavaScript method you could
cook-up because it submits at form as it was supposed to be done, with a
submit button!
--
Take care,
Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
Navigation:
[Reply to this message]
|