Textbox-Focus and Checkboxes-Disabled ?

Results 1 to 2 of 2

Thread: Textbox-Focus and Checkboxes-Disabled ?

  1. #1
    Join Date
    Dec 1969

    Default Textbox-Focus and Checkboxes-Disabled ?

    I have a web page, which contains a textbox and two checkboxes. Input in the textbox or a choice of one of the two checkboxes initiates a sql statement. When the user makes a selection on page "send" the results show up on page "receive". No problem there, however, I would like to deselect any checkbox that has been previously selected and give focus totally to the textbox when the user clicks the back button on their browser. I have an if statement that is retrieving the SQL statements associated with each object of the send page, but I can&#039;t get the checkboxes to go back to "unchecked or disabled".<BR>This is what I have, and the textboxes and checkboxes appear twice.<BR>&#060;%<BR>If %&#062;<BR>&#060;input name="Name" type="textbox" value != " " &#062;<BR>&#060;INPUT type="checkbox" name="ShowAll" disabled&#062;<BR>&#060;INPUT type="checkbox" name="ShowMGT" disabled&#062;<BR>&#060;%<BR>else %&#062;<BR>&#060;input name="Name" type="textbox" value=" " &#062;<BR>&#060;/font&#062; --OR-- <BR>&#060;input type="checkbox" name="ShowAll" &#062;<BR>Show All Employees ---OR-- <BR>&#060;input type="checkbox" name="ShowMGT" &#062;<BR>Show Management Staff Only <BR>&#060;input type="submit" /&#062;<BR>&#060;% end if %&#062;<BR>Thank you.<BR><BR>GailG.

  2. #2
    Join Date
    Dec 1969

    Default You could have used the body...

    OnLoad function to trigger a JS function which would have done your job when you hit the back button.<BR><BR>But this event will trigger even when you are coming to the page for the first time.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts