Posts

Showing posts with the label blog

Embedding portlet in a webcontent

We can embed portlet in a web content by using the following tag   <runtime-portlet name ="33"></runtime-portlet>  // here we are embedding the blogs portlet 1.Create the web content by selecting the basic web content .      Enter the title and when entering the content click on the source of the CKEditor and place the above tag in the editor.     Click on the Save button.       Place the web content display portlet in the  portal . select the appropriate web content . Then you see the Blogs portlet added in the web content.

Generating Stubs(webservices) in Liferay

Generating stubs in liferay , 1. we can generate the stubs in eclipse as         File ---> New ---> Others --->type webservices and select webservices client ---> Paste the WSDL in the service defination and move the slide till to TestClient and click on the "finish" to generate. WSDL can of type below http://localhost:8080/api/axis/Portlet_Blogs_BlogsEntryService?wsdl When i am trying to do in liferay eclipse it is not allowing to generate the stubs. So i am used Plain tomcat to generate the stubs. 2. We can also generate the stubs by ant    Drag and Drop the build.xml in ant    Locate the build-client . Double click on it . It Generate the <portlet-name>-portlet-client.jar file in the docroot/WEB-INF/client folder.      This lib contains the stubs. By Using that stubs we can write the our own implementations.

Relation between Tag cloud and Blogs in liferay

If we place tagcloud and blogs portlet in one page .When we click on the tagcloud automatically blogs portlet is rendering the tagged entries. So, how does it works? Open the portlet-custom.xml search with the "148" here 148 refers to portlet name.  At end of the portlet tag you will find the " <supported-public-render-parameter>tag</supported-public-render-parameter> ". Also search with "33" none other than blogs portlet. You will find the following line "<supported-public-render-parameter>tag</supported-public-render-parameter> ". Then how does it works in blogs?  Open the view.jsp(html/portlet/blogs folder). you will find the below line              String assetTagName = ParamUtil.getString(request, "tag");  where it is retrieving the tagname when we click on the tag. Following lines will do lot of things for retrieving the entries.     AssetEntryQuery assetEntryQuery = ne...