Friday, September 10, 2010
Liferay 6: Editing the dockbar
The dockbar is a Struts portlet, so it isn't something that you can control in a theme. Instead, you can modify the JSP that the portlet view uses.
View Files
/webapps/ROOT/html/portlet/dockbar/init.jsp
/webapps/ROOT/html/portlet/dockbar/view.jsp
Whether or not to display the dockbar is controlled in the theme. So in theory you could create your own portlet or vm file to display a completely custom dockbar. The theme file portal_normal.vm, and in the default portal_normal.vm you will see this.
The dockbar portlet is referenced in the ROOT application (/webapps/ROOT/WEB-INF/) as portlet name/number 145. Snippets of these references are below.
liberay-portlet.xml
portlet-custom.xml
View Files
/webapps/ROOT/html/portlet/dockbar/init.jsp
/webapps/ROOT/html/portlet/dockbar/view.jsp
Whether or not to display the dockbar is controlled in the theme. So in theory you could create your own portlet or vm file to display a completely custom dockbar. The theme file portal_normal.vm, and in the default portal_normal.vm you will see this.
#if($is_signed_in)
#dockbar()
#end
The dockbar portlet is referenced in the ROOT application (/webapps/ROOT/WEB-INF/) as portlet name/number 145. Snippets of these references are below.
liberay-portlet.xml
<portlet>
<portlet-name>145</portlet-name>
<icon>/html/icons/default.png</icon>
<struts-path>dockbar</struts-path>
<use-default-template>false</use-default-template>
<show-portlet-access-denied>false</show-portlet-access-denied>
<show-portlet-inactive>false</show-portlet-inactive>
<private-request-attributes>false</private-request-attributes>
<private-session-attributes>false</private-session-attributes>
<render-weight>50</render-weight>
<add-default-resource>true</add-default-resource>
<system>true</system>
</portlet>
portlet-custom.xml
<portlet>
<portlet-name>145</portlet-name>
<display-name>Dockbar</display-name>
<portlet-class>com.liferay.portlet.StrutsPortlet</portlet-class>
<init-param>
<name>view-action</name>
<value>/dockbar/view</value>
</init-param>
<expiration-cache>0</expiration-cache>
<supports>
<mime-type>text/html</mime-type>
</supports>
<resource-bundle>com.liferay.portlet.StrutsResourceBundle</resource-bundle>
<security-role-ref>
<role-name>power-user</role-name>
</security-role-ref>
<security-role-ref>
<role-name>user</role-name>
</security-role-ref>
</portlet>
Labels: Liferay
Comments:
<< Home
Orb 25 is a leading provider of Digital Integrated Business Services and Transformation Solutions for clients from around the world, representing all industry types.
Experience
Our company delivers proven solutions for optimizing processes, delivering exceptional customer experiences, and ensuring unmatched business agility.
Quick Support
Our technology solutions have world-class, award-winning security measures
and compliance with all Security Standards and Regulations.
We represent a global Center of Excellence within the Orb25 group for delivering customized and cost-effective Back-Office services, Digital, and web marketing services, Event management, Call center services, Video production services, etc.
orb25
Post a Comment
Experience
Our company delivers proven solutions for optimizing processes, delivering exceptional customer experiences, and ensuring unmatched business agility.
Quick Support
Our technology solutions have world-class, award-winning security measures
and compliance with all Security Standards and Regulations.
We represent a global Center of Excellence within the Orb25 group for delivering customized and cost-effective Back-Office services, Digital, and web marketing services, Event management, Call center services, Video production services, etc.
orb25
<< Home