cawte,
mam kod ktory mi obnovuje obsah v divu a potrebujema by mi to obnovovalo v 2 odlisnych divoch
ajax:
<script type="text/javascript">
function Ajax(){
var xmlHttp;
try{
xmlHttp=new XMLHttpRequest();// Firefox, Opera 8.0+, Safari
}
catch (e){
try{
xmlHttp=new ActiveXObject("Msxml2.XMLHTTP"); // Internet Explorer
}
catch (e){
try{
xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
}
catch (e){
alert("No AJAX!?");
return false;
}
}
}
xmlHttp.onreadystatechange=function(){
if(xmlHttp.readyState==4){
document.getElementById('open_tiket').innerHTML=xmlHttp.responseText;
setTimeout('Ajax()',1);
}
}
xmlHttp.open("GET","http://skuska.pantoflesport.cz/test2.php",true);
xmlHttp.send(null);
}
window.onload=function(){
setTimeout('Ajax()',1);
}
</script>
<script type="text/javascript">
function Ajax_stranka(){
var xmlHttp;
try{
xmlHttp=new XMLHttpRequest();// Firefox, Opera 8.0+, Safari
}
catch (e){
try{
xmlHttp=new ActiveXObject("Msxml2.XMLHTTP"); // Internet Explorer
}
catch (e){
try{
xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
}
catch (e){
alert("No AJAX!?");
return false;
}
}
}
xmlHttp.onreadystatechange=function(){
if(xmlHttp.readyState==4){
document.getElementById('stranka').innerHTML=xmlHttp.responseText;
setTimeout('Ajax_stranka()',10);
}
}
xmlHttp.open("GET","http://skuska.pantoflesport.cz/test3.php",true);
xmlHttp.send(null);
}
window.onload=function(){
setTimeout('Ajax_stranka()',800);
}
</script>
html:
<div id="stranka">
<img src="http://www.sanbaldo.com/wordpress/wp-content/rotating_arrow.gif" />
</div>
<div id="open_tiket">
<img src="http://www.sanbaldo.com/wordpress/wp-content/rotating_arrow.gif" />
</div>
ale nacita mi to len do toho prveho divu "stranka"
dakujem za pomoc