If Else If Else


/ Published in: JavaScript
Save to your folder(s)



Copy this code and paste it in your HTML
  1. if (tab_selected == 0) {
  2. $("td#leftNav").height(tab1 + extra_height)
  3. alert(tab_selected)
  4. return false
  5. } else if (tab_selected == 1)
  6. {
  7. $("td#leftNav").height(tab2 + extra_height + 10)
  8. alert(tab_selected)
  9. return false
  10. }
  11. else
  12. {
  13. $("td#leftNav").height(tab3 + extra_height + 50)
  14. alert(tab_selected)
  15. return false
  16. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.