Tuesday, November 6, 2012

Hiding Portal Pages from Navigation (WP 6.1)

Hiding portal pages (and other items) from Portal Navigation is a common requirement, but there is no obvious way to do this.  There are some suggestions that using the Manage Pages portlet works, though I have not had any success with it.  My personal approach requires xmlaccess, but has never let me down!  Here's how I do it:

First, use xmlaccess to export the page, label, or other item(s) that you need to hide from navigation.  For a brief tutorial about xmlaccess exporting, the following article may be helpful: http://www-01.ibm.com/support/docview.wss?uid=swg21260098

Following is a snippet from a Portal 6.1.0.3 xmlaccess export that I took - it has been mangled slightly to fit on the page.  The parameter in question is highlighted in red.  If your export does not contain this parameter, just copy / paste from this article and it should work fine.

        <content-node action="update" active="true" allportletsallowed="false" create-type="explicit" domain="rel".... >
            <supported-markup markup="html" update="set"/>
            <localedata locale="en">
                <title>Enterprise Search for classic collections</title>
            </localedata>
            <parameter name="colorPalette" type="string" update="set"><![CDATA[bcbstp2Theme/bcbstp2Theme]]></parameter>
            <parameter name="com.ibm.portal.Hidden" type="string" update="set"><![CDATA[true]]></parameter>
            <parameter name="com.ibm.portal.IgnoreAccessControlInCaches" type="string" update="set"><![CDATA[false]]></parameter>
            <parameter name="com.ibm.portal.bookmarkable" type="string" update="set"><![CDATA[No]]></parameter>
            <parameter name="com.ibm.portal.friendly.name" type="string" update="set"><![CDATA[OmniFindSearch]]></parameter>
            <parameter name="com.ibm.portal.remote-cache-expiry" type="string" update="set"><![CDATA[0]]></parameter>
            <parameter name="com.ibm.portal.remote-cache-scope" type="string" update="set"><![CDATA[NON-SHARED]]></parameter>

If the parameter already exists, just change the value within the CDATA block to "true" (to hide the page) or "false" (to show the page), depending on what you need.

Once you're done, save the xmlaccess file (make sure you keep a back up of your original export!) and reimport to your server.  The changes should be visible to Portal Navigation on the next reload.

Happy Portalling!

1 comment: