PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
It could be because your HTML isn't exactly 'neat'.
but also you can't do PHP and javascript like that...
You can create something similar using AJAX or something along the lines of AJAX.
If you wait a few hours, i'll have posted my AJAX tutorial.
Basicly what AJAX would do is.
1. User does something to trigger function 'copyValue' (in this case, onChange)
2. Server sends a hidden request to server and then parses response and throws the output back to javascript.
3. You make it do what you want with response... mainly place it in the second box.
No the html isnt very need. I could have it return a value by just using return $val with the php function but it seems that by throwing in the query it stopped doing what i wanted to do..
Thanks.. i would indeed like that.What ever it takes to make that piece working
I tried some of the AJAX which is pretty need, however i think ( if i am correct ) that it can not be used to have it filled in multiple input boxes having the same name or id. they all have to be unique. so no array[]
You see anytime you use " inside an echo that you are using " to tell what in it, the php code will get confused. Therefor if you are using " in the echo, start the echo off with '.
That may be why you don't see any input boxes or anything.[/quote]