Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Retrieve HttpServletRequest object

Featured Replies

  • Newbies

Hi

I'm developing an XSLT custom webpublishing solution that needs to use a single sign on product called Ubilogin. I have successfully added ubilogin to the tomcat server, but I need to get hold of the login name that can be retrieved from the HttpServletRequest, that is used/stored by the tomcat server, using the method getRemoteUser(). I have looked how one can add java code to an XSLT document using xalan-j, but I have yet to figure out how everything fits together in this complex puzzle. Has anyone added some java code to the tomcat server in order to be called from xalan-j in an XSLT document?

Have you looked up there? http://xml.apache.org/xalan-j/extensions.html#java-namespace

  • Author
  • Newbies

Yes I have. I managed to create a Java class which i put on the tomcat server (I'm home at the moment so I don't remember the exact path). It was something like

public class GetUserName extends HttpServlet {

...

private Request request;

public doPost(HttpServletRequest req, HttpServletResponse res) {

request = req;

}

public static getUserName(){

return request.getRemoteUserName();

}

}

...

The code threw a nullpointer exception which I have no idea why.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.