Jquery in my custom zen theme the following is my js file mymodule.js

$(document).ready(function(){

    alert('test');
});


and i just add this file in my customtheme.info .

scripts[] = js/mymodule.js

However, the js code only be executed at some pages, not all pages.

What could the problem will be?

Does anyone have the same situation before?

Please help me fix this.
In Drupal 7 to avoid conflicts with another library you should wrap your code in:

(function ($) {
  // Original JavaScript code.
})(jQuery);


To learn more visit: http://drupal.org/update/modules/6/7#javascript_compatibility