SO,
I\'ve been working on some html/javascript/css recently to create an online table for my students to view details, scores and various bits of information but I\'ve
1) You have to realize that you're not scrolling the page like you would do that with your scroll on a mouse. You're actually manipulating margin-left and this behaviour causes that you give it very large values. Then, it looks like you have told. There's a huge space between table and end of your screen. To solve it, you have to add an if statement that is going to check if you're trying to increase margin-left too much.
$("a.def").click(function() {
$("#gradient-style").each(function(){
var margin =$(this).css("margin-left");
if(margin > -204)
$(this).animate({"margin-left":"+=204px"},200);
else
$(this).animate({"margin-left":"+=" +(-margin)},200);
});
});
5) You could use localStorage variable which is built-in JavaScript feature. You can simply define any variable and use it over session. Here's example:
localStorage.numberOfRow =1;
console.log(localStorage.numberOfRow); //1