Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Now that you have the code copied and the top code commented, change the line, line 14 in our code above, so that the data-src points to where your image is hosted. If it is on your server, like our example is, you would not need the full url. Since ours is in an /images folder in our public_html folder on our server, we would put it as the next example shows. You can also see that we changed line 15 16 in our code to add a line of info for the image:
Code Block
languagexml
firstline1
titleFinal Step
linenumberstrue
<div id="main-banner">
<div class="image_load" data-src="./images/banner.jpg"></div>
<div class="image_info">
Great Image!
</div>
</div>

If you want the front image to cycle through various featured photos on your site, this is how to do that.

...