jQuery Advanced - Part 2

jQuery Advanced - Part 2

Looping over HTML elements

  
  let collection = $(".row").each(function() {
   	let x=$(this).html();
    return x;
  });
  

The above code snippet will store the HTML markup of every element whose class attribute is "row" in collection variable.

Sliding items up and down

  • $("#row").slideUp()
  • $("#row").slideUp("slow")
  • $("#row").slideUp(3000)
  • $("#row").slideDown()
  • $("#row").slideDown("slow")
  • $("#row").slideDown(3000)
  • $("#row").slideToggle()

Comments

Popular posts from this blog

Parallel Database design, query processing

Laravel | PHP | Basics | Part 2

Apache Hadoop | Running MapReduce Jobs