Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Sanket Gosavi
hook for portlet outside root
April 7, 2012 11:42 PM
Answer

Sanket Gosavi

Rank: Junior Member

Posts: 35

Join Date: December 24, 2011

Recent Posts

can i create a hook to modify portlet which is outside root?........i.e. friend's activities..?
How?
Pankaj Kathiriya
RE: hook for portlet outside root
April 8, 2012 2:22 AM
Answer

Pankaj Kathiriya

Rank: Liferay Master

Posts: 589

Join Date: August 4, 2010

Recent Posts

Hi Sanket,


Portlet friend's activities is portlet defined in social-networking portlet and is not in Liferay's ROOT so you cant have hook to modify it.

You can directly change this portlet as you do with your custom portlet, just have social-networking portlet as a Plugin-portlet and change the part you want.

And deploy that portlet again.


HTH,
Thanks&Regards.
Pankaj Kathiriya
Sanket Gosavi
RE: hook for portlet outside root
April 8, 2012 2:35 AM
Answer

Sanket Gosavi

Rank: Junior Member

Posts: 35

Join Date: December 24, 2011

Recent Posts

thnks a lot..
Aneesha Rao
RE: hook for portlet outside root
June 28, 2012 11:23 PM
Answer

Aneesha Rao

Rank: New Member

Posts: 14

Join Date: February 24, 2012

Recent Posts

Hi Pankaj,

Could you put some light on how to use portlets outside ROOT as a custom (Plugin) portlet.
I get a build compile error.

Thanks and Regards,
Aneesha
Muzakir Khan
RE: hook for portlet outside root
July 13, 2012 12:18 AM
Answer

Muzakir Khan

Rank: Regular Member

Posts: 112

Join Date: March 14, 2012

Recent Posts

Aneesha Rao:


Could you put some light on how to use portlets outside ROOT as a custom (Plugin) portlet.
I get a build compile error.

Thanks and Regards,
Aneesha

Think so you are from Java Back ground.. In liferay the portlets are found outside the ROOT only.. whereas in java everything is present inside the ROOT folder

Regards
Muzakir Khan
Aneesha Rao
RE: hook for portlet outside root
July 13, 2012 1:54 AM
Answer

Aneesha Rao

Rank: New Member

Posts: 14

Join Date: February 24, 2012

Recent Posts

I meant on creation of hook.
as on how to make a social networking portlet as a custom portlet, since there is no option to create a hook for the same
Pankaj Kathiriya
RE: hook for portlet outside root
July 13, 2012 2:16 AM
Answer

Pankaj Kathiriya

Rank: Liferay Master

Posts: 589

Join Date: August 4, 2010

Recent Posts

Hi Aneesha,

If you have for example social networking portlet installed from Plugin Installations, then there wont be any build.xml, So copy build.xml of other portlet you have and change project-name attribute.
Amd you have to create new docroot folder and copy WEB-INF, META-INF, jsps etc all under it.

Then you would be able to deploy .

HTH,
Thanks.
Pankaj
Muzakir Khan
RE: hook for portlet outside root
July 13, 2012 4:16 AM
Answer

Muzakir Khan

Rank: Regular Member

Posts: 112

Join Date: March 14, 2012

Recent Posts

Aneesha Rao:
I meant on creation of hook.
as on how to make a social networking portlet as a custom portlet, since there is no option to create a hook for the same


Hi!
Firstly create a hook by any custom name, say "socialnetwork" hook, as shown in screenshot1
Now, goto create a new liferay portlet, under that goto the option "New Liferay Hook" option as shown in screenshot2
Next, click on "custom JSP" or "portal properties" or other option as shown in screenshot3. In my case I am selecting custom JSP option.
A window will be opened, there you type "social" and select "socialnetwork.jsp" as shown in screenshot4
After that, you will be redirected to JSP of inbuilt socialnetwork, and now you can make it customized..
Hope so it helps you.

Kind Regards
Muzakir Khan
Attachment

Attachment

Attachment

Attachment

Attachments: screenshot1.png (91.0k), screenshot2.png (199.9k), screenshot3.png (115.8k), screenshot4.png (71.1k)