javascript - Why is my alert not displaying on page load, but it will display if I do it immediately? -


i have simple script:

$(document).ready(function() {     alert("hi"); )}; 

alert never shows though. if remove document.ready part, load immediately. have idea why?

you've got typo. last line should }); not )};.


Comments

Popular posts from this blog

c# - Send Image in Json : 400 Bad request -

jquery - Fancybox - apply a function to several elements -

An easy way to program an Android keyboard layout app -