Files
familyARK/familyark/app/public/js/main.js
T
Gustavo Adolfo Mesa Roldán 223572f952 more style
2020-03-30 03:44:12 +02:00

25 lines
891 B
JavaScript

var species = {};
$('document').ready(function(){
$.get( "/species", function( species_r ) {
species_r.data.map(function(item) {
species[item._id] = item
});
$( "#body" ).load( "/templates/home.html", function(){$("#load").fadeOut("slow");
$.get("/info", function( data ) {
var text = "<table class=\"info\">"
$.each(data, function(i, obj) {
text += "<tr><td>"+i+"</td><td> "+obj+"</td></tr>";
});
text += "</table>"
$( "#info" ).html( text );
$("#load").fadeOut("slow");
});
});
$("body").bgswitcher({
images: ["/images/bg0.jpg", "/images/bg1.jpg", "/images/bg2.jpg", "/images/bg3.jpg", "/images/bg4.jpg"],
loop: true,
duration: 1500
});
});
});