Dave's Brain

Browse - Programming Tips - How I can a Java Servlet get the referrer?

Date: 2013mar27
Language: Java

Q.  How I can a Java Servlet get the referrer?

A.

final String referer = request.getHeader("referer"); // It is spelled wrong by tradition: should be referrer

Add a comment

Sign in to add a comment
Copyright © 2008-2017, dave - Code samples on Dave's Brain is licensed under the Creative Commons Attribution 2.5 License. However other material, including English text has all rights reserved.