Monday, 4 November 2013

Some helpful

Hi All,

 Some times you want to achieve something,and you spent lot of time in finding its solution.

 There are some things that can be easily achievable if you have better knowledge of

  One such property is : ''

    # Set this to true if users are shown that they do not have access to a
    # portlet. The portlet init parameter "show-portlet-access-denied" will
    # override this setting.

When user don't have roles to access particular portlet,it shows error message. So If you want to completely hide portlet from user you can set this property to "false" in


Sunday, 3 November 2013

Links to Add Application, Toggle Edit Controls , Contol Panel from Liferay Custom Theme in 6.1

Hi All,

Sometime if you are creating your custom theme, you may not want whole Liferay dockbar and just require some of the links like Add Application, Toggle Edit Controls and Control Panel.

I have done same kind of development in one of my projects. That could be helpful to you.

This customization was done Liferay 6.1 EE GA2.

 #if ($permissionChecker.isOmniadmin() || $permissionChecker.isGroupAdmin($group_id))
         <li><a href="$htmlUtil.escape($theme_display.getURLControlPanel())">$languageUtil.get($locale,  "control-panel")</a></li>                                                           
  #if ($permissionChecker.isOmniadmin() || $permissionChecker.isGroupAdmin($group_id))
         <li><a onclick="Liferay.LayoutConfiguration.toggle('87');" href="javascript:void(0);">   $languageUtil.get($locale, "add-application")</a></li>

#if ($permissionChecker.isOmniadmin() || $permissionChecker.isGroupAdmin($group_id))
     <li class="toggle-controls"><a href="javascript:void(0);">$languageUtil.get($locale, "edit-controls")</a></li>


For toggle edit you would need below script to be added in your vm file.

#if ($is_signed_in)
<script type="text/javascript">
//For toggle edit controls load script once on page
AUI().use('node',function(A) {

Dhrutika Vyas