How to find broken url from custom 404 page?

I have created a custom 404 jsp page and updated the web deployment descriptor with the code:
     <error-page>
        <error-code>404</error-code>
        <location>/jsp/custom-404.jsp</location>
     </error-page>Whenever I enter an invalid url or click on broken link (target does not exist), a 404 HTTP response arises and the custom-404.jsp is rendered. So far so good.
Within the custom-404.jsp, I would like to know the original url (invalid link or broken link) so that I can send the administrator an email with the url details.But, I could not find any API to find this url?
Can someone help here please?
Thanks

My bet is that it is available as referrer inside the error page in case of a redirect, or as Request URI in case of a forward.
String referrer = httpServletRequest.getHeader("referer"); // Yes, with the legendary misspelling in it.
// or
String requestURI = httpServletRequest.getRequestURI();

Similar Messages

  • How to find the URL address of portal page ?

    Hello All,
    How to access a page from Portal Content Directory without logging into Portals ?
    Can we know the URL address for a Portal page so tht it can be called from another page via href object.
    Pls, provide me with an alternate solution that works better.
    Thank you for your time and valuable inputs. Looking forward to your responses.
    Regards,
    Anil Kumar.

    Hi,
    It is quite simple to find out the URL of a page, Check this for more:
    /thread/426798 [original link is broken]
    http://help.sap.com/saphelp_nw70/helpdata/en/43/014421d21d6fade10000000a11466f/frameset.htm
    Greetings,
    Praveen Gudapati

  • How to find delete message from iphone

    how to find delete message from iphone?

    I am afraid that I don't think there is a way to do this.

  • How to find server model from 11g OEM mgmt$ views

    How to find server model from 11g OEM mgmt$ views
    server model like Dell 710, DL380 G7 etc..,

    It is included in this query (run as user SYSMAN):
    SELECT t.target_name AS host_name,
    ecm_util.HOST_HOME_LIST (t.target_name, t.target_type) AS home_info,
    hw.vendor_name AS Vendor,
    hw.system_config AS System_Config,
    hw.machine_architecture Architecture,
    os.name AS os_name,
    os.base_version os_base_version,
    os.update_level os_update_level,
    os.address_length_in_bits os_address_length_in_bits
    FROM mgmt_targets t, mgmt_ecm_snapshot s, mgmt_hc_os_summary os, MGMT_HC_HARDWARE_MASTER hw
    WHERE t.target_type = 'host'
    AND t.target_name = s.target_name
    AND s.snapshot_type = 'host_configuration'
    AND s.target_type = 'host'
    AND s.is_current = 'Y'
    AND s.snapshot_guid = os.snapshot_guid
    AND hw.snapshot_guid = s.snapshot_guid
    ORDER by t.target_type
    The asked info is available in the view MGMT_HC_HARDWARE_MASTER, column: SYSTEM_CONFIG
    Eric

  • How do I keep URLs from printing after Events?

    Version 3.0.8 (1287) - How do I keep URLs from printing after Events?

    Open the Pages preferences > uncheck Automatic detect email and web addresses

  • How to find the URL of precalculated query

    Hello,
    I would enter into a precalculated query direclty the URL; is it possible?  How to find the URL ?
    Thanks.

    Hello Arvin,
    I have created a Web Template, and through the Reporting Agent, I run the query.
    Regards,
    Laura

  • How I find my iphone from my imac off.   hvordan jeg finder min iphone fra min imac af?

    hej jeg står og mangler hjælp til hvordan jeg finder min iphone fra min imac af?
    hello I'm standing and need help with how I find my iphone from my imac off?

    Import photos and videos from your iPhone, iPad, or iPod touch to your Mac or Windows PC - Apple Support

  • How to find the developer's customer support

    how to find the developer's customer support

    Go to their website. If you don't know its address then search for it on Google.

  • How to find max(time) from table using group by

    how to find max(time) from table using group by
    select var max(time)
              from table
              into (var1, time1)
               where .....
                 group by var.
    it is fetching record which is top in table.
    if u can help?
    regards.

    No this will fetch the maximum time from teh table.
    select var max(time)
    from table xxxx
    into (var1, time1)
    where .....
    group by var.
    Refer this code
    TABLES SBOOK.
    DATA:  COUNT TYPE I, SUM TYPE P DECIMALS 2, AVG TYPE F.
    DATA:  CONNID LIKE SBOOK-CONNID.
    SELECT CONNID COUNT( * ) SUM( LUGGWEIGHT ) AVG( LUGGWEIGHT )
           INTO (CONNID, COUNT, SUM, AVG)
           FROM SBOOK
           WHERE
             CARRID   = 'LH '      AND
             FLDATE   = '19950228'
           GROUP BY CONNID.
      WRITE: / CONNID, COUNT, SUM, AVG.
    ENDSELECT.

  • How to find lost files from Iphone without back up

    How to find lost files from iPhone without back up?

    If you don't have a back up, there's no where to restore them from.

  • Custom 404 pages in Lion web server?

    Tried searching this forum on this, and either I get tons of 404 stuff about iWeb (search bar doesn't let you specify a forum) or try to add lion server to the terms and get nothing. So, here goes...
    I just migrated a web site over to my Lion Server system from a paid Linux host.  On that host, my custom 404.shtml file showed properly when I deliberately entered a bad URL for the site. On the Lion Server I just get the default white page.
    Is there a way enable the custom 404 page on the Lion Server Web and, if so, how?
    Many thanks in advance!

    Okay, maybe Lion Server's setup can't handle .shtml page definitions by default.  No problem, I just changed the page to 404.html and redirected to it in the .htaccess file. Not as elegant as before but it works.

  • How do I stop firefox from redirecting every page I click on in Google search? No matter what I search for in Google when I click on it Firefox redirects me to some other search, sales, or contest page.

    How do I stop firefox from redirecting every page I click on in Google search? No matter what I search for in Google when I click on it Firefox redirects me to some other search, sales, or contest page. I have a security program running, no maleware, adware, or virus on my pc. Thanks for the help in advance.

    Sounds like a dose of search redirect malware or a redirect virus.
    Install, update, and run these programs in this order. They are listed in order of efficacy.<br />'''''(Not all programs detect the same Malware, so you may need to run them all to solve your problem.)''''' <br />These programs are all free for personal use, but some have limited functionality in the "free mode" - but those are features you really don't need to find and remove the problem that you have.<br />
    ''Note: If your Malware infection is bad enough and you are mis-directed to URL's other than what is posted, you may have to use a different PC to download these programs and use a USB stick to transfer them to the afflicted PC.''
    Malwarebytes' Anti-Malware - [http://www.malwarebytes.org/mbam.php] <br />
    SuperAntispyware - [http://www.superantispyware.com/] <br />
    AdAware - [http://www.lavasoftusa.com/software/adaware/] <br />
    Spybot Search & Destroy - [http://www.safer-networking.org/en/index.html] <br />
    Windows Defender: Home Page - [http://www.microsoft.com/windows/products/winfamily/defender/default.mspx]<br />
    Also, if you have a search engine re-direct problem, see this:<br />
    http://deletemalware.blogspot.com/2010/02/remove-google-redirect-virus.html
    If these don't find it or can't clear it, post in one of these forums for specialized malware removal help: <br />
    [http://www.spywarewarrior.com/index.php] <br />
    [http://forum.aumha.org/] <br />
    [http://www.spywareinfoforum.com/] <br />
    [http://bleepingcomputer.com]

  • Custom 404 page

    Hi,
    I have created a custom 404 page called 404.cfm. I am usingCF8 on IIS6. In IIS 6 I specified this custom 404 page as a File. When a user types a wrong address in IE, I can see my custom 404 page. But when I type the wrong address in Firefox, nothing happens. In Firefox I do not see my custom error page.
    If I had setup page incorrectly, then I shouldn’t have been able to see the custom 404 page in IE. Why Firefox is not displaying my custom page? Note that my custom page is a cfm not .htm or .html.
    Any idea as what is happening here.
    Thanks
    Joe Green

    When your page fires, it sends back a 404 header to the browser, and then the browser interprets that accordingly.  Firefox has a few built-in error pages that it can use instead of the 404 from the server.
    If you go to about:config in your browser, click the button and search for 'browser.xul.error_pages.enabled' - set that to false (not tried it here, just a
    guess).  Does that make it go away and show your custom page?
    UPDATE:  Scratch that - didn't work.  I'm sure there is a setting that makes firefox override the 404 error page system, I jsut can't seem to find it - try a google.

  • Setting a custom 404 page for a mysite verizon web site

    I have a personal web site at mysite.verizon.net/naesdraw/index.htm.
    I have been trying for awhile now to get a custom 404 page set up on it, naesdraw/404.htm
    I looked for information on this but nothing I've tried has worked, .htaccess, nothing. The .htaccess(before I removed it from the root) said :
    ErrorDocument 404 http://mysite.verizon.net/naesdraw/404.htm
    From things I've read, I'm begining to think that it is an issue on the server side of the operation - not me.
    Any suggestions on how to solve this? I'm entering the site to be judged soon, and I'd like to have it ready, since this is the last year I can enter it.

    it is server side.
    if only it were as easy as placing a 404.htm in the root dir lol.
    ... and by the way, i like turtles

  • Opening a seeded OAF page from custom JSP page.

    Hi All,
    We have requirement to open a seeded OAF page from custom JSP page.
    When we try to open URL of an OAF page after passing URL input parameters, we are always getting following error:
    'You have insufficient privileges for the current operation. Please contact your System Administrator.'
    On directly accessing the seeded OAF page, its encoding all the input parameters passed in URL. Also some more encoded parameters are getting added to the URL dynamically.
    Is there any standard way exists to invoke seeded OAF pages without passing encrypted parameters to it? Also where can we get more details about
    encrypting OAF URL parameters.
    Any pointers would be appreciated.
    Thanks in advance!
    Saurabh

    Have you duplicated entire Customer Service module's menu in your responsibility?
    or Also ping me the menu name..
    --Prasanna                                                                                                                                                                                                                                                               

Maybe you are looking for

  • ANN: Tutorial on incorporating Bridge web gallery into existing site

    Photo galleries produced by the Adobe Output Module in Bridge CS4 look much better than the ancient Create Web Photo Album command in Dreamweaver. The problem is that the HTML file created by Bridge displays the Flash-based gallery full screen, makin

  • Sales Office is not being copied from Sales Contract

    Dear SD Gurus, In DP90(Resource-Related Billing Request), order type LV (Debit Memo Request for Contract) is generated. In the complection procedure, I have set sales office as a mandatory field. I'm expecting the sales office to be copied from sales

  • Dv7-3165dx blu ray issues for past month cant get it to work?

    I have been trying to troubleshoot this problem 4 about a month now. When I put a bluray dvd the screen reads "no disk in drive". This message is the same response i get with diffrent players, hp mediasmart, cyberlink power dvd 10, arcsoft, and also

  • Firefox shuts down automatically then reopens

    <i>Locking duplicate thread.<br>Please continue here: [[/questions/1031308]]</i> I will be online, then the little circle will appear as if the computer is trying to connect, when in fact, Im connecting and IN a site. Then, Firefox will close all scr

  • [SOLVED]suspend fails NVRM: GPU at 0000:01:00.0 has fallen off the bus

    Hi All, After a update of my laptop, it does not fully wakes after going into suspend. It does not react to numlock anymore.  I have to push the power button for 10 seconds to shut it down. /var/log/everything.log, normal operations: Jul 21 03:42:38