SlideShare a Scribd company logo
WebSphere Portal Theme Menu Framework 
Michele Buccarello 
8/27/2014 
This document describe how to use the menu framework in WebSphere Portal Theme.
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 1 
Table of Contents 
Abstract ....................................................................................................................................................... 2 
Menu Framework ........................................................................................................................................ 2 
Client Side ................................................................................................................................................ 2 
Server Side ............................................................................................................................................... 3 
Provide the menu via custom module .......................................................................................................... 3 
Configure the module in your Portal Theme................................................................................................. 6 
Test the menu feed ...................................................................................................................................... 8
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 2 
Abstract 
In WebSphere Portal Theme there is an enterprise way to write extend or overwrite menu like the action menu 
In knowledge center (link below) there is a good description about it 
http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/dev- theme/themeopt_cust_menu.dita?lang=en 
Based on this example 
http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/dev- theme/themeopt_cust_resrcpermiss.dita?lang=en 
we want extend this menu without editing the pageAction.json (like in the IBM example) . 
Menu Framework 
WebSphere Portal Menu Framework is divided in client side and server side: 
- Client Side is used to render the menu in link with standard portal css 
- Serve Side is used to make the json feed in format ?uri=menu:customMenu 
Client Side 
All details about client side framework can be found here: 
http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/dev- theme/themeopt_cust_clientframe.dita
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 3 
In this article we use the sample rendering way: 
<span role="button" aria-haspopup="true" class="wpthemeMenuFocus" onclick="if (typeof wptheme != 'undefined') wptheme.contextMenu.init({ 'node': this, menuId: 'pageAction', jsonQuery: {'navID':ibmCfg.portalConfig.currentPageOID}, params: {'alignment':'right'}});" 
<span class="wpthemeUnderlineText" id="wpContextMenu">My Menu</span> 
</span> 
Highlighted in yellow you could see the menuid name created with the server side framework. 
Server Side 
All details about client side framework can be found here: 
http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/dev- theme/themeopt_cust_serverframe.dita 
In this article we don’t generate dynamically the feed but we provide JSON file in the format described in the knowledge center link. 
Provide the menu via custom module 
In this step we create an ear with a custom plugin.xml, this plugin describe how the menu is recognized and provided by the Portal Theme.
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 4 
1) Create a Dynamic Web Project 
2) Create in the webcontent two files: - decorations.xml - plugin.xml 
Inside the plugin.xml put the content below 
<?xml version="1.0" encoding="UTF-8"?> 
<plugin id="staticMenuModule" name="8.5 staticMenuModule" provider-name="IBM" version="1.0.0"> 
<extension point="com.ibm.portal.resourceaggregator.module" id="staticMenuModule" > 
<module id="staticMenuModule"> 
<contribution type="menu"> 
<sub-contribution type="json" ref-id="pageAction"> 
<uri value="res:{war:context- root}/menu/json/menuItem.json" /> 
</sub-contribution> 
</contribution> 
<contribution type="dyn-cs"> 
<sub-contribution type="markup" ref-id="menuActionMarkUp"> 
<uri value="res:{war:context-root}/menu/jsp/menuAction.jsp"/> 
</sub-contribution> 
</contribution> 
</module> 
</extension> 
</plugin>
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 5 
3) Create the folder menu under the WebContent folder and then create two folders named jsp and json, in the jsp folder create the file menuAction.jsp in the json folder create the file menuItem.json, at this point you should see something like this: 
In the menuItem.json put this content: 
[ 
{ 
"type":"DynamicMenuitem", 
"id":"ibm.portal.operations.assignPagePermissions", 
"titles": [ 
{ 
"value":"Assign Page Permissions Modified", 
"lang":"en" 
} 
] 
} 
] 
In the menuAction.jsp put this content: 
<span role="button" aria-haspopup="true" class="wpthemeMenuFocus" 
onclick="if (typeof wptheme != 'undefined') wptheme.contextMenu.init({ 'node': this, menuId: 'pageAction', jsonQuery: {'navID':ibmCfg.portalConfig.currentPageOID}, params: {'alignment':'right'}});"> 
<span class="wpthemeUnderlineText" id="wpContextMenu"> 
My Menu 
</span> 
</span>
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 6 
Configure the module in your Portal Theme 
At this point you have been created module named staticMenuModule with two contribution: 
- <sub-contribution type="json" ref-id="pageAction"> this subcotribution is a menu type and have as a reference the pageAction menu feed 
- <sub-contribution type="markup" ref-id="menuActionMarkUp"> this subcontribution is the dynamiccontentspot that contain the client side framework html piece 
To see the module active and functional 
1) Add the module in the current theme profiles, in my case this profile is the profile_deferred.json 
2) Add the dynamiccontentspot in the theme_xx.html, for testing purpose just customize the theme_en.html
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 7 
3) Invalidate the portal theme cache and check successful loading of the module throw the Theme Analizer Portlet. Click on the link UTILITIES  CONTROL CENTER Click in the link under the sections “Invalidate Cache” 
In the SystemOut.log you should see something like this
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 8 
4) Check in every portal pages if the dynamic content spot is visibile 
At this point the menu Actions and the custom menu “My Menu” have the same items and are extend with the custom link to the Resource Permission portlet 
Test the menu feed 
To ensure the right menu generation as described in the server side framework link it is important check the feed via the poc uri uri=menu:
WebSphere Portal Theme Menu Framework 
Websphere Portal Menu Framework 
Author:Michele Buccarello Page 9 
In my case I got the page oid and compose this url http://localhost:10039/wps/mycontenthandler?uri=menu:pageAction&navID=Z6_4AD223S0K0VR30ASD3J5LF2005 
In your browser now you are able to see the menuAction json feed with your custom json provided with the custom theme module

More Related Content

PDF
IBM Connections 4.5 User Data Propagation.
PDF
Enable seo friendly url in websphere portal
PDF
IBM Connections 4.5 bidirectional synchronization
PDF
Custom theme creation for Websphere Portal 8
PDF
Search engine optimization (seo)
PDF
Custom theme creation websphere portal 8.5
PDF
IBM Connections mail with exchange backend
ODP
Make Your Microsoft Stack Social With IBM Connections
IBM Connections 4.5 User Data Propagation.
Enable seo friendly url in websphere portal
IBM Connections 4.5 bidirectional synchronization
Custom theme creation for Websphere Portal 8
Search engine optimization (seo)
Custom theme creation websphere portal 8.5
IBM Connections mail with exchange backend
Make Your Microsoft Stack Social With IBM Connections

What's hot (20)

PDF
So you want to build a Facebook app
PDF
Unit 2.10 - Frames
PDF
Ibm tivoli access manager for e business junctions and links redp4621
DOC
DotNet Nuke Document To Create Child Portal
PPTX
APEX navigation concepts
PDF
Facebook Open Stream API - Facebook Developer Garage Dhaka
DOC
( 16 ) Office 2007 Create An Extranet Site With Forms Authentication
PDF
Firefox extension Development
DOCX
Power shell
PPT
Open mic ibm connections and ibm verse on premise integration 1
PDF
How To Write Your First Firefox Extension
PDF
WordPress SugarCRM Customer Portal Pro Plugin
PDF
Kkl Simplified Dec 22, 08
ODP
Auslug 2011 customising ibm connections
PDF
Magento 2 Seminar - Daniel Genis - Magento 2 benchmarks
PDF
Integrate jQuery PHP MySQL project to JOOMLA web site
PDF
Rapid Development With CakePHP
PDF
Blog Pro 2.0 User Guide
PDF
Whmcs addon module docs
PPTX
Firefox Extension Development
So you want to build a Facebook app
Unit 2.10 - Frames
Ibm tivoli access manager for e business junctions and links redp4621
DotNet Nuke Document To Create Child Portal
APEX navigation concepts
Facebook Open Stream API - Facebook Developer Garage Dhaka
( 16 ) Office 2007 Create An Extranet Site With Forms Authentication
Firefox extension Development
Power shell
Open mic ibm connections and ibm verse on premise integration 1
How To Write Your First Firefox Extension
WordPress SugarCRM Customer Portal Pro Plugin
Kkl Simplified Dec 22, 08
Auslug 2011 customising ibm connections
Magento 2 Seminar - Daniel Genis - Magento 2 benchmarks
Integrate jQuery PHP MySQL project to JOOMLA web site
Rapid Development With CakePHP
Blog Pro 2.0 User Guide
Whmcs addon module docs
Firefox Extension Development
Ad

Similar to Websphere portal theme menu framework (20)

PPTX
Lecture 2 Styling and Layout in React Native.pptx
PPTX
Controls Use in Windows Presentation Foundation (WPF)
PDF
#31.스프링프레임워크 & 마이바티스 (Spring Framework, MyBatis)_스프링프레임워크 강좌, 재직자환급교육,실업자국비지원...
PPTX
Asp PPT (.NET )
PDF
Why NextCMS: Layout Editor
PPTX
May the core be with you - JandBeyond 2014
PPTX
Building Potent WordPress Websites
PPT
Ionic tabs template explained
PDF
WordCamp Manchester 2016 - Making WordPress Menus Smarter
PDF
Start IoT with jQueryMobile - 기초3
PDF
Different types of sticker apps
PDF
WebClient Customization.pdf
PDF
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
PDF
M2ModuleDevelopmenteBook
PDF
Trustparency web doc spring 2.5 & hibernate
PPTX
ChocolateChip-UI
ODT
Eclipse Tricks
PDF
Servlets
Lecture 2 Styling and Layout in React Native.pptx
Controls Use in Windows Presentation Foundation (WPF)
#31.스프링프레임워크 & 마이바티스 (Spring Framework, MyBatis)_스프링프레임워크 강좌, 재직자환급교육,실업자국비지원...
Asp PPT (.NET )
Why NextCMS: Layout Editor
May the core be with you - JandBeyond 2014
Building Potent WordPress Websites
Ionic tabs template explained
WordCamp Manchester 2016 - Making WordPress Menus Smarter
Start IoT with jQueryMobile - 기초3
Different types of sticker apps
WebClient Customization.pdf
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
M2ModuleDevelopmenteBook
Trustparency web doc spring 2.5 & hibernate
ChocolateChip-UI
Eclipse Tricks
Servlets
Ad

Recently uploaded (20)

PDF
medical staffing services at VALiNTRY
PDF
System and Network Administraation Chapter 3
PDF
Design an Analysis of Algorithms I-SECS-1021-03
PPTX
history of c programming in notes for students .pptx
PPTX
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
PPTX
ai tools demonstartion for schools and inter college
PPTX
VVF-Customer-Presentation2025-Ver1.9.pptx
PDF
Wondershare Filmora 15 Crack With Activation Key [2025
PDF
AI in Product Development-omnex systems
PDF
How to Migrate SBCGlobal Email to Yahoo Easily
PDF
Softaken Excel to vCard Converter Software.pdf
PPTX
L1 - Introduction to python Backend.pptx
PPTX
Introduction to Artificial Intelligence
PDF
Navsoft: AI-Powered Business Solutions & Custom Software Development
PDF
Nekopoi APK 2025 free lastest update
PDF
Upgrade and Innovation Strategies for SAP ERP Customers
PDF
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PPTX
Transform Your Business with a Software ERP System
PDF
Which alternative to Crystal Reports is best for small or large businesses.pdf
medical staffing services at VALiNTRY
System and Network Administraation Chapter 3
Design an Analysis of Algorithms I-SECS-1021-03
history of c programming in notes for students .pptx
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
ai tools demonstartion for schools and inter college
VVF-Customer-Presentation2025-Ver1.9.pptx
Wondershare Filmora 15 Crack With Activation Key [2025
AI in Product Development-omnex systems
How to Migrate SBCGlobal Email to Yahoo Easily
Softaken Excel to vCard Converter Software.pdf
L1 - Introduction to python Backend.pptx
Introduction to Artificial Intelligence
Navsoft: AI-Powered Business Solutions & Custom Software Development
Nekopoi APK 2025 free lastest update
Upgrade and Innovation Strategies for SAP ERP Customers
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
Transform Your Business with a Software ERP System
Which alternative to Crystal Reports is best for small or large businesses.pdf

Websphere portal theme menu framework

  • 1. WebSphere Portal Theme Menu Framework Michele Buccarello 8/27/2014 This document describe how to use the menu framework in WebSphere Portal Theme.
  • 2. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 1 Table of Contents Abstract ....................................................................................................................................................... 2 Menu Framework ........................................................................................................................................ 2 Client Side ................................................................................................................................................ 2 Server Side ............................................................................................................................................... 3 Provide the menu via custom module .......................................................................................................... 3 Configure the module in your Portal Theme................................................................................................. 6 Test the menu feed ...................................................................................................................................... 8
  • 3. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 2 Abstract In WebSphere Portal Theme there is an enterprise way to write extend or overwrite menu like the action menu In knowledge center (link below) there is a good description about it http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/dev- theme/themeopt_cust_menu.dita?lang=en Based on this example http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/dev- theme/themeopt_cust_resrcpermiss.dita?lang=en we want extend this menu without editing the pageAction.json (like in the IBM example) . Menu Framework WebSphere Portal Menu Framework is divided in client side and server side: - Client Side is used to render the menu in link with standard portal css - Serve Side is used to make the json feed in format ?uri=menu:customMenu Client Side All details about client side framework can be found here: http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/dev- theme/themeopt_cust_clientframe.dita
  • 4. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 3 In this article we use the sample rendering way: <span role="button" aria-haspopup="true" class="wpthemeMenuFocus" onclick="if (typeof wptheme != 'undefined') wptheme.contextMenu.init({ 'node': this, menuId: 'pageAction', jsonQuery: {'navID':ibmCfg.portalConfig.currentPageOID}, params: {'alignment':'right'}});" <span class="wpthemeUnderlineText" id="wpContextMenu">My Menu</span> </span> Highlighted in yellow you could see the menuid name created with the server side framework. Server Side All details about client side framework can be found here: http://www-01.ibm.com/support/knowledgecenter/SSHRKX_8.5.0/mp/dev- theme/themeopt_cust_serverframe.dita In this article we don’t generate dynamically the feed but we provide JSON file in the format described in the knowledge center link. Provide the menu via custom module In this step we create an ear with a custom plugin.xml, this plugin describe how the menu is recognized and provided by the Portal Theme.
  • 5. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 4 1) Create a Dynamic Web Project 2) Create in the webcontent two files: - decorations.xml - plugin.xml Inside the plugin.xml put the content below <?xml version="1.0" encoding="UTF-8"?> <plugin id="staticMenuModule" name="8.5 staticMenuModule" provider-name="IBM" version="1.0.0"> <extension point="com.ibm.portal.resourceaggregator.module" id="staticMenuModule" > <module id="staticMenuModule"> <contribution type="menu"> <sub-contribution type="json" ref-id="pageAction"> <uri value="res:{war:context- root}/menu/json/menuItem.json" /> </sub-contribution> </contribution> <contribution type="dyn-cs"> <sub-contribution type="markup" ref-id="menuActionMarkUp"> <uri value="res:{war:context-root}/menu/jsp/menuAction.jsp"/> </sub-contribution> </contribution> </module> </extension> </plugin>
  • 6. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 5 3) Create the folder menu under the WebContent folder and then create two folders named jsp and json, in the jsp folder create the file menuAction.jsp in the json folder create the file menuItem.json, at this point you should see something like this: In the menuItem.json put this content: [ { "type":"DynamicMenuitem", "id":"ibm.portal.operations.assignPagePermissions", "titles": [ { "value":"Assign Page Permissions Modified", "lang":"en" } ] } ] In the menuAction.jsp put this content: <span role="button" aria-haspopup="true" class="wpthemeMenuFocus" onclick="if (typeof wptheme != 'undefined') wptheme.contextMenu.init({ 'node': this, menuId: 'pageAction', jsonQuery: {'navID':ibmCfg.portalConfig.currentPageOID}, params: {'alignment':'right'}});"> <span class="wpthemeUnderlineText" id="wpContextMenu"> My Menu </span> </span>
  • 7. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 6 Configure the module in your Portal Theme At this point you have been created module named staticMenuModule with two contribution: - <sub-contribution type="json" ref-id="pageAction"> this subcotribution is a menu type and have as a reference the pageAction menu feed - <sub-contribution type="markup" ref-id="menuActionMarkUp"> this subcontribution is the dynamiccontentspot that contain the client side framework html piece To see the module active and functional 1) Add the module in the current theme profiles, in my case this profile is the profile_deferred.json 2) Add the dynamiccontentspot in the theme_xx.html, for testing purpose just customize the theme_en.html
  • 8. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 7 3) Invalidate the portal theme cache and check successful loading of the module throw the Theme Analizer Portlet. Click on the link UTILITIES  CONTROL CENTER Click in the link under the sections “Invalidate Cache” In the SystemOut.log you should see something like this
  • 9. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 8 4) Check in every portal pages if the dynamic content spot is visibile At this point the menu Actions and the custom menu “My Menu” have the same items and are extend with the custom link to the Resource Permission portlet Test the menu feed To ensure the right menu generation as described in the server side framework link it is important check the feed via the poc uri uri=menu:
  • 10. WebSphere Portal Theme Menu Framework Websphere Portal Menu Framework Author:Michele Buccarello Page 9 In my case I got the page oid and compose this url http://localhost:10039/wps/mycontenthandler?uri=menu:pageAction&navID=Z6_4AD223S0K0VR30ASD3J5LF2005 In your browser now you are able to see the menuAction json feed with your custom json provided with the custom theme module