My VT uPortal Quick Start

Virginia Tech is pleased to offer a uPortal 2.4.2 Quick Start with most of our My VT modifications applied. For a preview/summary of our changes, take a look at our online tour.

Documentation is a Work in Progress
Please put comments at the end of this document if things are unclear/incomplete/incorrect and I will update the documentation. I'm just trying to get this out the door, so the document will evolve over time.

What's in the Quick Start

We did not apply all of our modifications to uPortal since some were specific to our institution. We tried to include all of the UI modifications and some sample fragments/channels to show you how they can be used. Here's a list:

  • My VT look and feel in "khaki" and "grey"
  • My VT customization interface which is a simplified Integraded Modes
  • Updated Content Subscriber channel
    • Search and browse in one screen
    • Keywords support for channel
    • Word stemming and case-insensitivity for searches (uPortal 2.5 has case-insensitivity)
  • Sample CNET News.com channel XML profile
  • Sample fragments with example subtabs
  • navigate.jsp to allow navigation among tabs/pages
  • My VT frame for pulling in external content
  • Debugging XML output to logging enabled by default

Getting the Quick Start Running

  1. Download uportal-2-4-2-myvt-quick-start.zip
  2. Unzip the file
  3. Go to the uportal-2-4-2-myvt-quick-start directory
  4. At the command line, run: ant hsql &
  5. Then run: ant tomcatstart &
  6. Access the portal at http://localhost:8080/uPortal/

You can log on as:

  • demo/demo - template user
  • admin/admin - administrative user with Administration tab (demo of subtabs)
  • student/student
  • faculty/faculty
  • staff/staff

reportal.sh

In the quick start directory there is a shell script named reportal.sh. We used a script similar to this while developing My VT to allow us to quickly reset uPortal to an "out of the box" state. This allowed us to ensure that changes we made to the XSLT, code, and DB worked cleanly.

Sometimes, getting uPortal up and running requires modifying the default database data to get customizations to work. At Virginia Tech, rather than modifying the database data, we modified the data.xml file (which is used to initially populate the database) so that My VT was properly configured right from the start.

This script will do the following:

  • Stop tomcat
  • Deploy any code/XSLT changes you've made
  • Reset the uPortal database using data.xml
  • Publish a sample channel profile provided
  • Publish the sample fragments
  • Start tomcat

Initial My VT Setup

When you first start the quick start, the portal will not have features such as the shared column or the customizable Home tab. These instructions will walk you through setting up these features on the demo user. The demo user is used for all newly created users in the system.

Shared Column

  1. Log on with demo/demo
  2. Click the Change Content button
  3. Create a new tab
  4. Rename the tab to: column::shared-column
  5. Click the Finished Changing Content button

Customizable Home Tab

  1. Log on with demo/demo
  2. Click the Change Content button
  3. Create a new tab
  4. Rename the tab to: tab::Chicken
  5. Click the Add Default Page link
  6. Click the Add Main Column link
  7. Click the Add Side Column button
  8. Rename the tab to: tab::Home
  9. Click the Finished Changing Content button

Using Tab/Page/Column

Tab/Page/Column is a custom structure transform for uPortal that allowed us to have multiple levels of tabs using pushed fragments. Check out the sample fragments.xml to see an actual fragment definition XML. Here are the general guidelines for using Tab/Page/Column:

  • Tabs are folders with a name: tab::<Tab Name>
  • Pages are folders with a name: page::<Page Name>
  • Columns are folders with a name: column::<Column Name>
  • Channels are regular <channel> elements
  • The root layout can contain Tabs and Columns
  • Tabs can contain Tabs and Pages
  • Pages can contain Pages and Columns
  • Columns can contain Channels
Sample Layout BEFORE Structure Transform
<?xml version="1.0" encoding="UTF-8"?>
<layout>
    <folder ID="userLayoutRootNode" type="regular" hidden="false"
        unremovable="true" immutable="false" name="Root folder" priority="0">
        <folder ID="3" type="regular" hidden="false" unremovable="true"
            immutable="true" name="tab::Administration" priority="20003">
            <folder ID="14-2" type="regular" hidden="false"
                unremovable="true" immutable="true"
                name="tab::Channel Manager" priority="2147483646">
                <folder ID="14-3" type="regular" hidden="false"
                    unremovable="true" immutable="true"
                    name="page::default" priority="0">
                    <folder ID="14-4" type="regular" hidden="false"
                        unremovable="true" immutable="true"
                        name="column::main-column" priority="0">
                        <channel .../>
                    </folder>
                </folder>
            </folder>
            <folder ID="14-14" type="regular" hidden="false"
                unremovable="true" immutable="true" name="page::default" priority="2147483643">
                <folder ID="14-15" type="regular" hidden="false"
                    unremovable="true" immutable="true"
                    name="column::main-column" priority="0">
                    <channel .../>
                </folder>
            </folder>
        </folder>
        <folder ID="4" type="regular" hidden="false" unremovable="true"
            immutable="true" name="column::footer" priority="19998">
            <channel .../>
        </folder>
    </folder>
</layout>
Sample Layout AFTER Structure Transform
<?xml version="1.0" encoding="UTF-8"?>
<layout userName="" newNodeID="6" ID="userLayoutRootNode" mode="edit"
    page="default" tab="5" authenticated="true">
    <tab name="Administration" ID="3" locked="yes" type="system">
        <tab name="Channel Manager" ID="14-2" locked="yes" type="system">
            <page name="default" ID="14-3" locked="yes" type="system">
                <column name="main-column" ID="14-4" locked="yes" type="system">
                    <channel .../>
                </column>
            </page>
        </tab>
        <page name="default" ID="14-14" locked="yes" type="system">
            <column name="main-column" ID="14-15" locked="yes" type="system"/>
        </page>
    </tab>
    <column name="footer" ID="4" locked="yes" type="system">
        <channel .../>
    </column>
</layout>

Navigating Tabs and Pages

Use the navigate.jsp file to create links inside of channels to tabs, pages, and channels. The JSP takes 4 parameters:

  • tab - the ID or name of the tab to navigate to. Note: Navigating by name only works for tabs defined via tab::Name.
  • page - the name of the page to navigate to. Note: You must specify a tab as well.
  • channel - the fname of the channel to load full screen
  • root=root - Returns to the "normal" view of the portal from a full screen channel

To go to the default page of the Home tab:
/uPortal/navigate.jsp?tab=Home&page=default

To show the CNET News.com channel in full screen:
/uPortal/navigate.jsp?channel=cnet-news-com

To return to normal view from full screen channel view:
/uPortal/navigate.jsp?root=root

Additional Colors

Someone noticed that the My VT quick start came packaged with only grey and khaki colors yet it referenced many others in the CSS file. The attached additional colors zip file provides the other colors used by My VT at Virginia Tech.  Just unpack the files to the same location of your grey and khaki folders (typically <myvt-quick-start_dist>/uPortal_rel-2-4-2/webpages/media/edu/vt/portal/layout/TabPageColumn/InlineCustomization/images/).  Please note that this zip archive also contains the original grey and khaki files so it will probably try to overwrite.

Using the Frame

The frame.jsp loads external content in an iframe that looks similar to the full screen channel mode. Used parameters are:

  • myvt-title - title to display
  • myvt-color - color of bar (supports grey and khaki themes)
  • myvt-icon - the URL to the icon to display
  • myvt-back-name - Name of the page to go back to
  • myvt-back-url - URL of the page to go back to
  • myvt-help - URL for the help link
  • myvt-frame - URL for the contents of the frame
  • myvt-logoff - URL for the log off link

Common Tasks

Publishing a Channel
At the command line, run: ant pubchan -Dchannel=<Channel Filename>

color: Color value is invalid

Example:

color: Color value is invalid

ant pubchan -Dchannel=cnet-news-com.xml

Publishing Fragments
At the command line, run: ant pubfragments -DfragmentFile=<Path to Fragments File from uPortal root>

color: Color value is invalid

Example:

color: Color value is invalid

ant pubfragments -DfragmentFile=/properties/al/fragment.xml

Adding a User
At the command line, run: ant md5passwd -Dusername=<Username>

color: Color value is invalid

Example:

color: Color value is invalid

ant md5passwd -Dusername=bcjones

Known Bugs

  • Images for folders and channels in the Content Subscriber channel do not work. The image files are licensed by VT and cannot be distributed, I have not yet updated the XSLT to point to generic versions.
  • The uPortal 2.4.2 XHTML output sometimes puts a random > into the output. This is not a problem with the My VT mods, but a problem with out of the box uPortal.
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Jun 28, 2005

    Jason Shao says:

    Collier, Great work. The XHTML issue with random '>' characters being embedded i...

    Collier,

    Great work. The XHTML issue with random '>' characters being embedded in your output should be fixed by the new XHTML serializer in both 2.5 and 2.4 patches.

  2. Jun 29, 2005

    Robert Sherratt says:

    Collier your talk in Baltimore was definitely one of the highlights of JASIG. We...

    Collier

    your talk in Baltimore was definitely one of the highlights of JA-SIG. We are in the process of upgrading version from 2.1.4 and are very interested in the portlet improvements in 2.5 but also want to use your improvements.

    Despite the changes in the 'complex layout manager', do you know if it will be possible to take your 2.4.2 mods and port them to later versions of 2.x including 2.5?

    It might also be useful to consider including these changes in the architecture for 3.0 if possible

    1. Jun 29, 2005

      B. Collier Jones says:

      Robert, I'm glad you enjoyed my talk. I have not even looked at 2.5 yet to see h...

      Robert, I'm glad you enjoyed my talk. I have not even looked at 2.5 yet to see how our stuff works, but I imagine that it works just fine. However, I'm pretty sure that it does not work with DLM enabled.

  3. Jul 28, 2005

    John Bruso says:

    Collier, BUG: Have you noticed a bug with the login channel of the myVT Quick St...

    Collier,

    BUG:
    Have you noticed a bug with the login channel of the myVT Quick Start? If you login with the wrong username or passoword and then attempt to login correctly, the login form won't process, at least in IE... it just sits there and won't try to contact the server.

    • john
  4. Oct 31, 2005

    John Kenneth Godwin says:

    Have you (or anyone else) attempted to use XUL pages in your portal? I'm not hav...

    Have you (or anyone else) attempted to use XUL pages in your portal? I'm not having any success. It would be nice to be able to utilize an XML based gui "widget" tool in portlets.

    Sincerely,
    John Godwin
    jgodwin001@comcast.net

  5. Mar 01, 2006

    Chuck Crandall says:

    Anyone, I am attempting to implement the VT theme in uPortal 2.5.1.&nbsp; Is the...

    Anyone,

    I am attempting to implement the VT theme in uPortal 2.5.1.  Is there a step-by-step guide on how to do this?  If no guide is available, is there a list of changes made to the DB?  Any help here would be great.

    Thanks,
    Chuck Crandall
    Web Developer, Unicon
    ccrandall@unicon.net

    1. Mar 01, 2006

      Shoji Kajita says:

      Hi, This is a very brief description about it: Modify property/db/data.xml an...

      Hi,

      This is a very brief description about it:

      • Modify property/db/data.xml and execute `ant db' like:
        $ ant db
      • Execute `ant pubchan' like:
        $ ant pubchan -Dchannel=cnet-news-com.xml
      • Execute `ant pubfragments' by using the VT fragments.xml shipped with the distribution like:
        $ ant pubfragments -DfragmentFile=/properties/al/fragments.xml
      • copy the following files:
        /webpages/stylesheets/org/jasig/portal/channels/CGenericXSLT/RSS/rss-2.0.ssl
        /webpages/stylesheets/org/jasig/portal/channels/CGenericXSLT/RSS/rss-2.0.xsl
      • There is a bug in fragment.xml
        Wrong: <folder name="column::footer" immutable="Y" unremovable="Y" hidden="N">
        Correct: <folder name="column::footer-column" immutable="Y" unremovable="Y" hidden="N">

      We are using 2.5.1-based VT theme successfully

      Shoji

      1. Mar 07, 2006

        Chuck Crandall says:

        Shoji, Thanks for the helpful steps. I have a question, though.&nbsp; The first ...

        Shoji,

        Thanks for the helpful steps. I have a question, though.  The first item is 'modify data.xml'... what do I need to modify?

        Thanks,
        Chuck

        1. Mar 07, 2006

          Chuck Crandall says:

          Nevermind, our DB guy figured it out.&nbsp; Chuck

          Nevermind, our DB guy figured it out. 

          Chuck

  6. Mar 28, 2006

    Murali Menon says:

    Collier: 1) Chuck Crandall has made the myVT quick start theme work with uPortal...

    Collier:

    1) Chuck Crandall has made the myVT quick start theme work with uPortal 2.5.2. However, in testing the portal with Mozilla Browser 1.7.3, we notice strange and erratic behavior of the page and tab displays off and on. Either the page spans wider than the screen or one tab occupies the entire screen.  Is this a known issue?
    2) We also notice that tabs which do not have icons next to the tab label cannot be moved to the left before the tabs which have icons next to their labels, Do you know what causes this behavior?  

    Thanks,
    Murali Menon
    Unicon Inc., 

    1. Mar 29, 2006

      B. Collier Jones says:

      1) This is a bug in Mozilla. Refreshing the page will "fix" it. Firefox 1.5 seem...

      1) This is a bug in Mozilla. Refreshing the page will "fix" it. Firefox 1.5 seems to have fixed this. Basically, Firefox tries to render the layout table before it has all of the data. uPortal doesn't send the data fast enough. By the time Firefox gets the 3rd column, it has to be rendered off screen.

      2) Yeah, this was by our design. Tabs with icons were considered "system" tabs therefore more important than "user" tabs. User tabs cannot be moved before system tabs. The system over user priority is used throughout the structure/theme.

      I hope this helps.

  7. Mar 29, 2006

    Ken Lai says:

    Could data.xml of MyVT 2.4.2 Quickstart be applied to uPortal 2.5.2 with no hack...

    Could data.xml of MyVT 2.4.2 Quickstart be applied to uPortal 2.5.2 with no hacking?  I know there were some minor database schema changes between 2.4.x and 2.5.x concerning aggregated layout.

    Thanks,
    -Ken

    1. Mar 29, 2006

      B. Collier Jones says:

      I can't comment on this. I don't know enough about 2.5.

      I can't comment on this. I don't know enough about 2.5.

    2. Mar 29, 2006

      Jason Shao says:

      I think one ALM column was renamed from restrictiontype <> restrictionname (one ...

      I think one ALM column was renamed from restriction_type <-> restriction_name (one or the other) which would likely need to modified, and there are some changes to the published channel entries as well as the additions to support DLM. It would likely be straitforward to convert the data.xml file to incorporate the differences in 2.5.x, though it would likely be simpler to look at the diffs in CVS and reapply them to the modified data.xml as appropriate. Probably a few days worth of work.

      1. Mar 29, 2006

        Ken Lai says:

        To what I find the schema changes from 2.4.x to 2.5.x, UPRESTRICTIONS and UPCKEY...

        To what I find the schema changes from 2.4.x to 2.5.x, UP_RESTRICTIONS and UPC_KEYWORD tables are removed.  The field UP_RESTRICTION_TYPE is replaced with UP_RESTRICTION_NAME in all other tables.

        I can't find any usage of field UP_RESTRICTION_TYPE or UP_RESTRICTION_NAME in MyVT data.xml except the UP_RESTRICTIONS mapping table. I think we can just drop the UP_RESTRICTIONS table of MyVT data.xml and that can be used to initialize 2.5.2 database.  But I don't know that is good enough and no more data hacking is required.  Will test later.