Reputation: 547
Is there some equivalent to jQuery's getScript in Prototype ?
Upvotes: 3
Views: 1361
Reputation: 11568
var head;
var script;
head = $$('head')[0];
if (head)
{
script = new Element('script', { type: 'text/javascript', src: 'dynamic.js' });
head.appendChild(script);
}
Upvotes: 5