I want to download the AJAX user list available at http://zadanie.ee/users.json, And I would like to display
1.The number of all users, 2.The Number of active users, 3.The Number of active women, 4.The Number of active men,
from JSON API, using jquery/javascript etc,
How can I achieve this? or can some one provide me a simple tutorial to start with?
Here is what I have done so far :
CODE:
<script>
function ViewData()
{
$.getJSON("http://zadanie.ee/users.json",
function(data)
{
var items = [];
$.each(data.Users,
function(key, value)
{
items.push("<li>" +
value.username + "<br />" +
value.active + "<br />" +
+ "</li>");
});
$('<ul/>', {html: items.join(")}).
appendTo('body');
});
}
</script>
Any help or any idea will be appreciated, Thanks.