Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    Regular Coder
    Join Date
    Feb 2006
    Posts
    138
    Thanks
    11
    Thanked 0 Times in 0 Posts

    How to keep form values from resetting when using $_SERVER['PHP_SELF'];

    I have a form that sends its values to a php scrpt that is on the same page as the form, hence the $_SERVER['PHP_SELF']; target for the form.

    What I'm trying to do is not have the form values reset when the form submits..

    ANy ideas?

  • #2
    Regular Coder
    Join Date
    May 2006
    Location
    Wales
    Posts
    820
    Thanks
    1
    Thanked 82 Times in 79 Posts
    Code:
    <form id="form" onLoad="document.getElementById('form').reset();">
    Some thing like that... That is probably wrong also btw

  • #3
    Regular Coder
    Join Date
    Feb 2006
    Posts
    138
    Thanks
    11
    Thanked 0 Times in 0 Posts
    That didn't work...

    Thanks for trying though...

  • #4
    New Coder
    Join Date
    Aug 2006
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Hmmm...

    Do you have your values set to the variable you're entereing?

    Code:
    <input type=\"text\" name=\"value1\" value=\"$value1\">


  •  

    Posting Permissions

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