How do you delete text in inputboxes
Moderator: General Moderators
-
jaymoore_299
- Forum Contributor
- Posts: 128
- Joined: Wed May 11, 2005 6:40 pm
- Contact:
How do you delete text in inputboxes
After I fill out an inputbox and press submit, when I press back or even reload in firefox, the forms continue to have the same values filled out previously. Is there a setting for inputboxes that clears this?
- raghavan20
- DevNet Resident
- Posts: 1451
- Joined: Sat Jun 11, 2005 6:57 am
- Location: London, UK
- Contact:
Usually that is what programmers want to do because that avoids users from inputting information again but that does not happen normally.
for clarity, here is an example....
Usually programmers have to code like this to retain the values filled in by an user
for clarity, here is an example....
Usually programmers have to code like this to retain the values filled in by an user
Code: Select all
<form method = 'post'>
<input type = 'text' name = 'sometext' value = '<?php echo isset($_POST['sometext'])? "" : $_POST['sometext']; ?> ' />
</form>