Why is the value of the first time taken?
while ($row =mysql_fetch_array ($query))
{
?>
(note: Up to four words!) )
}
?>
function check (ID)
{
var Tit=document.getelementbyid (' title '). Value;
alert (tit);
S_xmlhttprequest ();//Introduce the above object in order to use the above method.
Xmlhttp.open ("GET", "changelink.php?title=" +tit+ "&id=" +id,true); Xmlhttprequest.open (delivery method, address, whether asynchronous request)
xmlhttp.onreadystatechange=byphp; Ready to execute, call the following method
Xmlhttp.send (null);//Send
}
function Check1 (ID)
{
var Lin=document.getelementbyid (' link '). value;
S_xmlhttprequest ();//Introduce the above object in order to use the above method.
Xmlhttp.open ("GET", "changelink.php?link=" +lin+ "&id=" +id,true); Xmlhttprequest.open (delivery method, address, whether asynchronous request)
xmlhttp.onreadystatechange=byphp; Ready to execute, call the following method
Xmlhttp.send (null);//Send
}
Why every time I take is the first time that the ID of the change, I each row of the ID are different, should be taken to the corresponding value of the different IDs to Ah, get a half-day, or do not know what to do, seek expert guidance, thank you!
------Solution--------------------
The ID of the title of your loop output is the same, you can only take the first one.
function check (ID)
{
var Tit=document.getelementbyid (' title ' +id). Value;
alert (tit);
...............
The following link is also true
------Solution--------------------
Reference:
the ID of the title of your loop output is the same, you can only take the first one.