Don’t try to use jQuery in the same page as Prototype. If you must use jQuery for some reason, then be sure to include the noConflict() function as documented in the jQuery site.
The major issue here is Prototype’s use of the $() function, which jQuery hijacks and uses for a similar but not exactly identical purpose. noConflict() restores the original meaning of $().
It’s important to note that mixing these two libraries has a much larger down-side beyond mere incompatibility. Both Prototype and jQuery build complete APIs (Application Programming Interfaces) on top of the browser’s own native DOM interfaces. They do this so that differences between browsers don’t need to be considered when writing JavaScript code. Instead of writing a version of your script for IE, and then another different version of your script for all other standards-compliant browsers, and maintaining both versions as you change your application, you simply write one set of code to the API, and let the framework sort out the underlying differences. This is a much better way to code.
But the point of this explanation is to say that you are entirely duplicating this effort when you use both libraries. It is far more straightforward to use one library or the other, and write all of your code to one API, rather than plugging together two completely different libraries and their code in the same page. For one thing, your page will be quite a bit smaller file-size-wise if you do this.
Walter
On Oct 21, 2013, at 12:05 PM, Doren wrote:
Ah, I wondered about that.
Where do I place the noConflict() snippet?
Thank you!
Ok, but what I don’t understand is that I simply duplicated that page and now the Sticker Action stopped working? For right now I don’t have time to rewrite anything. Headed to a video production for several days. Where would I place the code snippet? Thanks!
The Sticker Action could never have worked if it had jQuery in it before. What other Actions are on this page, and what other scripts have you added to the page using the Page / HTML Markup dialog?
Walter
On Oct 21, 2013, at 12:25 PM, Doren wrote:
Ok, but what I don’t understand is that I simply duplicated that page and now the Sticker Action stopped working? For right now I don’t have time to rewrite anything. Headed to a video production for several days. Where would I place the code snippet? Thanks!