Hi, there, I have got a website that fetches news-feeds from different new-sites and present it on one feed-sampler. Actually I do it with a php-script, the site is shown, when all feeds (or an error-message) are loaded. Now I want to relaunch it, showing the site at once and sending requests one after an other so that the users can see the first feeds almost at once. But I've got to jscripts, that did no work. One is the tooltipster.js that makes styled tooltips out of the delivered feedcontent and the second one ist the eqheight.coffee-script, that gives the same height to each of the articles in a row. Actually I include or load the jsscript-file with these two functions at the end of my php-site, but in my new site, I have to call the two functions when the first feeds are there. I tried to build-in the functions at another place of the script but it did not work. Because - to be honest - I don't know much about js. Here are the links to the sites. This is the site with the pure php-script:

http://nachrichtentisch.de/test.php

This is the site with the js-feedloading, but with an old design without tooltipster and eqheight:

http://nachrichtentisch.de/js.php

This is the site in which I tried to combine it:

http://nachrichtentisch.de/test.php

And this is the Code od the new site:

Code:
  <div class="main"  style="margin: 60px 0px 10px 10px;">

  <script type="text/javascript">

//function that loads the feeds

var feedObj = null;
    feedObj = new XMLHttpRequest();
var i = 1;

window.onload = function() {

    function beginneLaden() {

        feedObj.open("GET", "feeds1.php?feedid="+i);   //"feeds1.php" is the file with the feed-urls and that loads the php-file that outputs the content
        feedObj.onreadystatechange = ladeFeeds;
        feedObj.send(null);
      

        function ladeFeeds() {

            var fa = false;
            var anzahl = 18;      // Anzahl der Feeds angeben

            if (feedObj.readyState == 4) {
                document.getElementById("feed"+i).innerHTML += feedObj.responseText;
                i++;
                fa = true;
                if (i > anzahl) {fa = false;
                }
            }
            if (fa != false) {

                beginneLaden();
              
            }
        }
    }
    beginneLaden();
    
$(".main").eqHeight("article", {equalize_interval: 500});



$(window).resize(function(){
  equalheight('.main article');
});


}
</script>

<!--
 Hier so viele Div-Bereiche im Dokument anlegen und mit einer ID versehen,
 wie Feeds in der Seite geladen werden sollen.
-->


   <article id="feed1"> 
               <a href="http://www.tagesschau.de" target='_blank'> 
            <img src="../logos/tagesschau.jpg" alt="Tagesschau" class="img-rounded"/></a>          
        
</article>

  <article id="feed2"> 
  <a href="http://www.deutschlandfunk.de/nachrichten.353.de.html" target='_blank'> 

                       <img src="logos/dlf.jpg" alt="Deutschlandfunk" class="img-rounded"/></a>
         
 </article>
 
  <article id="feed3"> 
  <a href="http://www.spiegel.de/" target='_blank'> 
  <img src="logos/spiegel.png" alt="Der Spiegel" class="img-rounded"/></a>

 </article>
My questions: Where can and should I load the eqheight- and tooltip-function? can I call a jsscript within another jsfunction? How should I solve it all?

Kind regards
Peter