I am using document.observe("dom:loaded", function() in global.js ,Its giving error document.observe is not an
function.
I am using document.observe("dom:loaded", function() in global.js ,Its giving error document.observe is not an
function.
Have you included the prototype javascript files in your layout?
You can add this line in element of your layout file (/app/views/layout/.html.erb)
<%= javascript_include_tag :defaults %>
Also global.js should be loaded after <%= javascript_include_tag :defaults %> .
Robert Pankowecki