Here I will show you how you can integrate the lates jQuery version into your Liferay Portal (version 5.2.3 but should also work with 6.x). I will do this with jQuery version 1.3.2 (I know, that’s not the latest atm) but it will work straight forward with any other version.
What you will need:
- the jQuery version you want to add to your liferay (here i will use ‘jquery1.3.2.js’)
- the plugins you want to use with your new jQuery version (here ‘ui.jquery1.7.js’ and ‘ui.stars.js’)
- your Liferay-EXT Environment
- One file from the Liferay Source Code (top_head.jsp)
Ok, let’s start:
– Copy the file “top_head.jsp” located in folder “liferay-portal-src-[version]\portal-web\docroot\html\common\themes\” into the EXT-folder ‘liferay[version]-portal-ext\ext-web\docroot\html\common\themes\’
– Open the copied file in your EXT
– Add the following lines:
– Now you can access jQuery 1.3.2 through the variable ‘jQuery132‘.
– Have fun with the new version! 🙂
This does not affect the original jQuery variable in your Liferay Portal!
And you can have as many jQuery versions in your Liferay portal as you want!
Just add them this way and give the variables different names.