Installation

installation.

#

If you have not already installed Liferay IDE view Liferay IDE Installation Guide for a detailed walk-through of

Requirements before getting started
y y y

#

1. Liferay Portal 6.0 (RC2 or greater) downloaded and installed (or download in the IDE itself) 2. Liferay Plug-ins SDK 6.0 (RC2 or greater) downloaded and installed (or download in the IDE itself) 3. Eclipse Helios/Galileo Java EE for developers package - see the Liferay IDE Installation Guide for more information. Note: earlier versions of Liferay, e.g. 5.x, are not supported yet by the Liferay IDE

Liferay Plug-ins SDK Setup #
Before you can begin creating new Liferay plug-in projects, a Liferay Plug-ins SDK and Liferay Portal must be installed and configured in the IDE.

y y

1. Open Eclipse with Liferay IDE installed. 2. Open Preference page for Liferay> Installed SDKs ( Go to Window > Preferences >Liferay> Installed SDKs )

y

3. If you have not already downloaded the Liferay Plug-ins SDK for your portal version you can download it from thesourceforge.net Liferay downloads page. Liferay plugin sdk is located available in the "portal" folder. In the "portal" folder, select the Liferay version matching the Liferay version. Within this folder, look for liferay-pluginssdk-x.x.x.zip (usually the last file). 4. Add your SDK using the Add button which brings up the Add SDK Dialog:

y

Note: multiple SDKs can be added to the preferences but you will need to select at least one SDK to be the default which is represented by the SDK that has the checkbox selected.server. portlets created with the SDK plugin will not be deployed by Ant./bundles/app_server_name build.dir}/. liferay-portal-6.0. In eclipse open the Runtime environments preference page (Go to Window > Preferences > Server > Runtime . Note: if you have version 6.properties file.g.y y y 5. Otherwise. Browse to the location of your Plug-ins SDK installation. Select OK and you should see your SDK in the list of Installed SDKs. The default name is the name of the directory but you can change it if you wish.properties you of have to change bundles with the name of the Liferay portal installation directory e.0. you will need to change your build. In the lineapp. The SDK plugin assumes you have installed the SDK at the same level (same directory) as the portal directory. 6.dir=${project.4. 7. Liferay Portal Tomcat Runtime / Server Setup y environments) # 1..4 of Liferay Portal and the Plugin SDK.

. Inc.. y 3. If you have not already downloaded and installed a copy of the Liferay Portal Tomcat bundle then you can download the latest Liferay Portal Tomcat bundle by clicking the "Download and Install." button within the wizard. category and click Next. Click Add to add a new Liferay runtime and find Liferay v6 Tomcat under the Liferay.y 2. .

y 4.2 directory. If you used the download option you can skip this step. if not.0. click Browse and select the location of the liferay-portal-6. .

if there is no bundled JRE (Mac and Linux users) then you will need to select the JRE to use for launch. . However. Once you have selected the Liferay portal directory if it has a bundled JRE then that bundled JRE will be automatically selected as the JRE to use for launching the server.y 5.

Inc category and select the Liferay v6 Server and choose the Liferay v6 Runtime that you had previously created. Find the Liferay. y y 7. 8. If you didn't choose to create a server you will need to create one from the servers view before you can test the server. Click finish and you should see the Liferay portal runtime in the list of runtimes in the preference page.y 6. y 9. Click OK to save the runtime preferences. .

Testing the Liferay portal server y "Debug" # 1.0 Server" from the menu.liferay. Select "Apply" . y y y y 1. Otherwise. it is necessary to specify the console encoding to properly display console messages." from the Eclipse menu. see http://issues.. 4. 2. select "Other" and "UTF-8". 3.2 and greater. In the encoding section.com/browse/IDE-287 This steps are not necessary if Liferay is installed on an OS whose encoding is latin1 or UTF (most US and -8 European OS). Select the "Common" tab. Select "Run" ."Run Configuration. Select "Liferay v6.Setting the Console Encoding # This step is not necessary for Liferay IDE 1.."Close". right click and choose "Start" or . Go to the servers view and you should see the new server that was created.

The eclipse browser should open to the portal home at http://localhost:8080 .y 2. y 3. You should see messages appear in the Console view and once it starts. right-click the server and select the (Liferay Portal > Open Portal Home) action. the servers view will update to show that it is "Started" and then.

Create new Liferay Plug-in Project y # 1. Now that a SDK and portal server have been configured you can create a new Liferay plug-in project.. >Liferay>Liferay Plug-in Project . Go to File > New Project..

If it worked you should see a new plugin project in the package explorer. by clicking Finish. In the Liferay Plugin project wizard page. select the SDK and Liferay runtime and then select the plug-in type (portlet is default) and now you can create a new plug-in project. so you are ready to begin Plugin Development. .y 2. y 3.