javascript - cannot impliment infinite scroll with my code -


i've read multiple examples on infinite scrolling, find hard implement code. here's code, data shown mysql database :

<div class="container" align="center" style="margin-top:100px;margin-bottom:100px"><div class="row"> <?php      $result = mysql_query("select * batai svarbumas=1 order id desc");     while ($row = mysql_fetch_array($result))        {            extract($row);            $link=$row["linkas"];            echo "<div class='col-md-4'>";            $sites_html = file_get_contents($link);            $html = new domdocument();            @$html->loadhtml($sites_html);            $meta_og_img = null;            //get meta tags , loop through them.            foreach($html->getelementsbytagname('meta') $meta) {                //if property attribute of meta tag og:image                if($meta->getattribute('property')=='og:image'){                    //assign value content attribute $meta_og_img                   $meta_og_img = $meta->getattribute('content');                }             }            list($width, $height) = getimagesize($meta_og_img);            $skaicius = abs($width - $height);            if($width > $height) {              echo "<img src=\"$meta_og_img\" style='height:234px;margin-left:-33%' onclick='window.open(\"$link\", \"_blank\");'>";             }            else if($width < $height) {                if($skaicius < 100){                    echo "<img src=\"$meta_og_img\" style='width:234px'     onclick='window.open(\"$link\", \"_blank\");'>";                 }                 else {                    echo "<img src=\"$meta_og_img\" style='width:234px;margin-top:-33%'     onclick='window.open(\"$link\", \"_blank\");'>";                 }            }            echo "</div>";     } ?> 

stored in database link to, example, internet shop page. code takes image facebook preview link stored in db, tagged og:image , positions center. problem page tries load every image , takes ton of time load page, thats why want somehow make load on scroll page. btw, im using bootstrap's grid system here. hope can me. p.s. if don't mean because of bad english, ask me , i'll try answer more clearly


Comments

Popular posts from this blog

facebook - android ACTION_SEND to share with specific application only -

python - Creating a new virtualenv gives a permissions error -

javascript - cocos2d-js draw circle not instantly -