Salve ragazzi,sono giorni che cerco soluzioni a sto problema:
Ho una pagina che "dovrebbe fare" due richieste ajax a due pagine diverse.
Il problema è che se elimino la prima funzione ajax che vi scrivo sotto,la richiesta è completata...se la includo nel codice..non funziona più nulla


Ho questi due div per stampare il contenuto:
codice HTML:
<div id="query_feed">...</div>
codice HTML:
<div id="follow_button_div">...</div>
Ho un codice che richiama due funzioni ajax differenti dal tag <body>
codice HTML:
onload="stringa_vuota = ''; showResultFeed(stringa_vuota); new_follow_feed(stringa_vuota);"
E queste sono le funzioni ajax:

La prima

codice:
// --------------------------------------------------------------------------------SCRIPT PER BOTTONE FOLLOW   
 function new_follow_feed(feed_url_add)    {
    if (window.XMLHttpRequest)    {
// code for IE7+, Firefox, Chrome, Opera, Safari   
 xmlhttp=new XMLHttpRequest(); 
   }   
 else    {
// code for IE6, IE5   
 xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");   
 } 
   xmlhttp.onreadystatechange=function()  
  {    if (xmlhttp.readyState==4 && xmlhttp.status==200) 
   {   
 document.getElementById("follow_button_div").innerHTML=xmlhttp.responseText;    
}    
}  
   var str;     stri = "<? echo $feed;?>";  
   var email;     email = "<? echo $email;?>";    
xmlhttp.open("GET","add_feed.php?feed=" + stri + "&email="+email,true);    xmlhttp.send();    }

La seconda:

codice:
// --------------------------------------------------------------------------------SCRIPT PER I FEED  
  function showResultFeed(stringa_ricerca_bis) 
   {    if (window.XMLHttpRequest)  
  {
// code for IE7+, Firefox, Chrome, Opera, Safari   
 xmlhttp=new XMLHttpRequest();  
  } 
   else  
  {
// code for IE6, IE5   
 xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");  
  }    
xmlhttp.onreadystatechange=function()   
 {  
  if (xmlhttp.readyState==4 && xmlhttp.status==200)   
 {    
document.getElementById("query_feed").innerHTML=xmlhttp.responseText;   
 } 
   } 
    var str;     str = "<? echo $feed;?>";  
  xmlhttp.open("GET","search_feed.php?feed=" + str + "&query_bis="+stringa_ricerca_bis,true); 
   xmlhttp.send();   
 }   
 showResultFeed();

Se riusciste ad aiutarmi ve ne sarei infinitamente grato