diff --git a/src/edu/rpi/sss/util/servlets/HttpServletUtils.java b/src/edu/rpi/sss/util/servlets/HttpServletUtils.java
index <HASH>..<HASH> 100644
--- a/src/edu/rpi/sss/util/servlets/HttpServletUtils.java
+++ b/src/edu/rpi/sss/util/servlets/HttpServletUtils.java
@@ -150,10 +150,16 @@ public class HttpServletUtils {
     }
 
     try {
-      return request.getRequestURL().toString();
+      StringBuffer sb = request.getRequestURL();
+      if (sb != null) {
+        return sb.toString();
+      }
+
+      // Presumably portlet - see what happens with uri
+      return request.getRequestURI();
     } catch (Throwable t) {
       Logger.getLogger(HttpServletUtils.class).warn(
-          "Unable to get url from " + request);
+          "Unable to get url from " + request, t);
       return "BogusURL.this.is.probably.a.portal";
     }
   }
To build bedework after this update will require ant-contrib.jar to be added to apache-ant-<I>/lib
This will be done in the preview quickstart

Upgraded portlet support. Managed to display the user calendar in liferay4.
Made much more of the portlet support common. Moved many config settings into the properties file. 
Some changes still needed 

Moved portlet stylesheets into common portlet directory