Wednesday, October 20, 2010

Performing a Redirect in Oracle WebCenter Interaction

Recently we implemented a jquery flyout page navigation (look for a blog post about that soon) within our Oracle WebCenter Interaction install.
One issue that it wasn't coded to handle was related and sub communities.

Currently users navigate to these related communities by going to the home page of the parent community and clicking the link there.  We have an issue where we don't want these related communities to clutter the "My Communities" dropdown, yet feel they need to be represented in some way in the flyout page navigation because with the new navigation folks are more sensitive to the titles of things and expect appropriate representation.

To illustrate the point, here is the layout with the problem being showing Conference A and B on the Conferences and Meetings Community:
  1. My Communities
    1. Conferences and Meetings Community
      1. Home page
        1. Conference A Community
          1. Home page
          2. Agenda page
          3. Registration page
        2. Conference B Community
          1. Home page
          2. Agenda page
          3. Registration page
I looked into DNS and web server redirecting and neither seemed able to handle this issue (if you think or know otherwise I'd be all ears!!!), so my ugly solution is to simply create stub pages on the Conferences and Meetings community with portlets on each that have simple javascript redirects.
It isn't pretty, but it gets the job done.

Here is the snippet that does the redirect within the stub page portlet:

<script type="text/javascript">
window.location = "http://website/portal/server.pt/community/conference_A/111"
</script>

Yes, yes, I know this isn't anything you couldn't figure out in 1/2 a second by going to google, or probably you already know off the top of your head. It was a slow day for me!
<!--409551bd517c4e7ba493f12ff3a6530d-->

No comments:

Post a Comment