First, you’ll have to create a properly formatted JSON file. Once you’re done with that, getting the current number of objects from that list is a piece of cake.
<script>
$.getJSON('json/myjsonfile.json',function(data){
var json = data;
alert(json.length);
});
</script>
Pull in the feed via getJSON function, toss it into a variable (I called mine json) and grab the length with .length. My example alerts the number of entries but you can do what ever you’d like.
According to W3C, you can add lang=”en” (for english) attribute to your HTML tag and this is still valid for HTML5.
Here are some other options for the lang attribute:
“en”: English
“en-US”: the U.S. version of English.
“en-cockney”: the Cockney version of English.
“i-navajo”: the Navajo language spoken by some Native Americans.
No it is not REQUIRED but yes, we should still use it, allow me to explain.
Modern browsers will add this tag it on render if you do not include it BUT it is suggested that you include it anyway. You will find that you may need to use these tags in the future for example, if you wanted to utilize the manifest attribute (for offline browsing) or you wanted to target your whole page with a CSS class in the event that IE gives you issues. The html tag is also where we specify what language our website is using.
The first line of your HTML5 file should include a doctype, it is case-sensitive with html in all lower case. The doctype tells the browser which specific rendering mode to use and sets the guidelines for HTML validation. If you are writing HTML5, you’ll want to use the following tag:
<!DOCTYPE html>


Build geometric shapes with this vintage toy, designed by Charles & Ray Eames in 1952. The Little Toy was manufactured by Tigrett, featured colorful square and triangle pieces that can be arranged into 3D shapes.

In 1952, Charles and Ray Eames designed the House of Cards – interlocking pictures and patterns. Each design was inspired by nature and culture so the Eameses selected textures from animals, minerals, food, fabrics and patterns.
I finally got myself a set of these cards, totally excited to have found the 1952 version.
First you’ll want to put a DIV somewhere on your page and give it a class, for my example I’m going to call it floatingbanner.
So, our HTML will look like this:
<div class="floatingbanner"> <!-- Banner Appears Here --> </div>
Then we drop in some CSS, setting the image as a centered background and give the div positioning properties so that it’s fixed at 0px from the bottom of the browser window:
.floatingbanner{
background:transparent url(../images/floatingimage.png) no-repeat scroll top center;
bottom:0;
left:0px;
position:fixed;
width:100%;
z-index:9999;
height:80px;
}
Here’s what it looks like:

This can be done with CSS, you’ll need to change button to whatever class, tag or id you need to remove those dotted lines from.
button:focus {outline: none;}
button:focus {outline: none;}
button::-moz-focus-inner {boder:0;}
So you want to know how many items are in that list:
<ul id="imagelist"> <li>Image 1</li> <li>Image 2</li> </ul>
Make sure you’ve got the jQuery libaray running and run the following lines after page load.
$(document).ready(function(){
alert($("#imagelist li").size());
});
You’ll need to add the google servers to your host file.
For Mac:
I manage mine with Gas Mask for Mac (download):
You’ll need to add these two lines:
127.0.0.1 www.google-analytics.com
127.0.0.1 google-analytics.com
127.0.0.1 ssl.google-analytics.com
If you’re on a PC:
Open your hosts file with a text editor to windows/system32/drivers/etc/hosts
You’ll need to add these two lines:
127.0.0.1 www.google-analytics.com
127.0.0.1 google-analytics.com
127.0.0.1 ssl.google-analytics.com
Restart your browser, especially if you’re using IE.
