code help, form values
- Started
- Last post
- 8 Responses
- ********
Can I change the input text in a form element from a link?
I've been trying with JavaScript/PHP to no avail...
- rabattski0
yes. you can use javascript and/or php to read a link and use it's values. depending on what you use (e.g. php) you generate that form based on that value. i would advise php though to make sure it works 100% since javascript has it nags cross browser / cross platform.
- ********0
ok.. next question - how? I'm calling a php value as a link, and on-click trying to pass the same value to an input box... But I'm stuck. cant work it...
- rabattski0
hope this works, since posting code here doesn't work 100%. but let's say you have an url like index.php?txt=yadda. you can use php to set the value of that form element. e.g. since $txt = "yadda" yadda will be displayed in that text element.
- rabattski0
obviously it didn't work.
- ********0
lol - no it didn't.
- rabattski0
you so lucky i have time :)
here, hope this helps:
http://www.sckr4bmb.com/dropbox/…
- ********0
i am ;)
Thanks fella. I've got that working a treat!
- rabattski0
cool. i just luv php.