instagram - Instafeed not loading -


hi trying instagram feed onto website showing user photos. have put javascript @ top of page follows:

<head> <meta charset="utf-8"> <meta http-equiv="x-ua-compatible" content="ie=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>tomsaxby.com</title>  <!-- css ------------------------------------------------------------------------------------------- --> <!-- bootstrap --><!-- latest compiled , minified css --> <link rel="stylesheet" href="http://netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css"> <!-- edits --> <link rel="stylesheet" href="css/style.css">   <!-- fonts --> <link rel="stylesheet" href="fonts/neuzeit/myfontswebfontskit.css" type="text/css" /> <!-- css ------------------------------------------------------------------------------------------- -->  <script type="text/javascript" src="path/to/instafeed.min.js"></script>     <script type="text/javascript"> var feed = new instafeed({     get: 'user',     userid: 904401907,     accesstoken: '904401907.1677ed0.27d4a579f194430cbe77c28af165aae1' }); userfeed.run(); </script> </head> 

i have put div id of "instafeed" body of page. nothing displays either locally or when upload files? know why is?

the cause of problem, instafeed.js trying run before page has been loaded.

to resolve this, make sure have put <div id="instafeed"></div> on page, , loading instafeed.js after page has been loaded:

$(document).ready(function() {   var feed = new instafeed({     get: 'tagged',     tagname: 'awesome',     clientid: clientid   });   feed.run(); }); 

Comments

Popular posts from this blog

html - Difficulties with background-image property -

visual studio code - What does the isShellCommand property actually do and how should you use it? -

ios - Segue not passing data between ViewControllers -