Integrating Lotus Connections with WebSphere Portal - Part 2
Friday, July 16, 2010 at 3:38PM
Adam Brown in Social Software, Software Development, Technical, WebSphere Portal, WebSphere Portal, lotus connections

 Ok so couple of days ago was Home, Profiles, Communities, Search, and Dogear. Today Activities, Files, & Wikis.

Wikis:

Wiki's is slightly different in that it doesn't import the JSTL Core Tag Lib which is used in the script hence we need to add it. So add the script to the following file:

\installedApps\Wikis.ear\qkr.share.wiki.was\jsp\home.jsp

and then also add:

<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> to the first line of home.jsp

Files:

Files is the same as Wiki's in that we need to add the tag library as well.

\installedApps\Files.ear\qkr.share.files.war\WEB-INF\pages\home.jsp.

 

Activities:

Now activities is also slightly different. You still need to add the above script to the jsp however there are two body tags to add it to. There is also a change required to banner.jsp.

So first add the usual scripts from yesterday directly after each of the <body> tags in the mainpage.jsp

\installedApps\Activities.ear\oawebui.war\WEB-INF\jsps\webui\mainpage.jsp

Now at first this didn't work and it took me a while to realise that the "lotusbanner" was not being updated to display="none". The reason for this is that unlike the other features the DIV for the lotusbanner only contains a Class reference and not an ID reference. Hence as the script sets id="lotusbanner" to display="none" it doesn't work. So we need to update the banner.jsp (same directory as mainpage.jsp) to have:

<div id="lotusBanner" class="lotusBanner">

It then works a treat just like the other features.

 URL to link Web Page Portlet to: https://<activities-server>/<activities-context-root>/service/html/mainpage?FromPortal=true

 

So all that is left is Blogs. Blogs is proving to be slightly more difficult due to the Theme templating. So that might make up Part 3 to come.



Update on Monday, July 19, 2010 at 3:43PM by Registered CommenterAdam Brown

Update: We have discovered that while all of this has worked a treat in Firefox IE seemed to have a problem for File and Wikis. The issue was effectively a timing issue that resulted in the script to change the lotusbanner class to display=none to not run correctly and hence the top level Nav still shows.

So to fix it we needed to change the following:

1) header.html file on the IHS server needed the script relating that calls the testCookieFromPortal script to be changed to:

<script type="text/javascript">

  if(testCookieForFromPortal()) {

    if (typeof hideLotusBanner=='function') hideLotusBanner();

  else

    var div=document.getElementById("lotusbanner");

    If (div) div.style.display="none";

  }

}

 

2) We then add the following function to the Portal Customisation Script for Files & Wikis that you inserted previously as per above.

function hideLotusBanner() {

  var div=document.getElementById('lotusbanner');

  if (div) div.style.display='none';

  else {

    var t=setTimeOut('hideLotusBanner()',100);

  }

{

 

3) Lastly at in Wikis we need to add the following to the last script at the bottom on home.jsp:

if (typeof hideLotusBanner=='function') hideLotusBanner();

 

 

And that should fix the issues with IE.

Article originally appeared on Adam Brown - Collaboration Blueprint (http://www.collaborationblueprint.com.au/).
See website for complete article licensing information.