Tomcat to Return a 301 instead of a 404

I have an old website that we used to host for freeware java apps, applets and beans. A few years ago we dropped the site, but there are still many, many links to the pages.
We've elected to offer the freeware again, but in a much scaled down version of the website. Therefore there are dozens of pages that no longer exist on the new site...
Rather than recreate this elaborate directory structure, I've setup an error page that redirects users to the new main page (links to all the software packages are there). However, I was hoping to be able to return a 301, and not a 404, to spiders, etc. Is this possible?

Ok I got this just now,
I just need to ask for
trace(re.result["STRUCTURE_ITEM"]);
Cheers

Similar Messages

  • Fmt:message returns question marks instead of unicode

    well, pretty simple problem.
    When i'm using <fmt:message key="someunicode"/>, the tag returns question marks instead of hebrew unicode string.
    The page displays unicode that isn't coming from the tags.
    The resorues files is ok too.
    Anyone knows something about it?

    Have you set the bundle for the fmt tag before you use the <fmt:message> tag?
    <fmt:setBundle var="mybundle" basename="resources.application"/>
    Then :
    <fmt:message key="my.key.message" bundle="${mybundle}"/>You can also the the bundle in the <fmt:message> tag.

  • Return a struct instead of query from cfc to as3

    Hi all,
    Recently I am updating an old project which make use of flash remoting (com.niarbtfel.remoting classes).
    I 've got my new coldefusion method in cfc which need to return a structure instead of a query result. It seems that is not supported
    as I get an error within the OnResult method in as3 code.
    The error is
    TypeError: Error #1010: A term is undefined and has no properties.
    it seems that the piece of code i am using is not accepting structures.
    function onSucceed(re:ResultEvent, args:Array)
         var resultStructur:Object = new Object();
         resultStructure = re.result.serverInfo.initialData;
    Any ideas, directions would be appreciated.
    cheers,
    Giorgos

    Ok I got this just now,
    I just need to ask for
    trace(re.result["STRUCTURE_ITEM"]);
    Cheers

  • Exchange Online Management cmdlets return Display Name instead of Identity

    Hello,
    We've got an issue when managing our Exchange Online environment using remote PowerShell.
    We use Exchange management cmdlets to manage Exchange Online mailboxes. When we run, for example, the
    Get-MailboxPermission or Get-RecipientPermission
    cmdlets, it returns Display Names of the users with mailbox rights. Previously, when we initially tested remote PowerShell with Exchange Online, the cmdlets returned the
    Identity property, which is unique and worked well for us. However, currently the cmdlets return the
    Display Name, which is not unique and causes us issues. For example, in our environment there can exist two or more users with the same Display Name (see highlighted on the screenshot):
    In cases when only one of the users is granted a permission, we cannot distinguish programmatically, which of the 2 users this is. Also, we cannot run cmdlets, such as
    Get-SecurityPrincipal, to get more info about the principals who are granted the permission.
    Is it possible to get the old behavior of the cmdlets back so that they return the unique
    Identity instead of the non-unique Display Name? Or how do we workaround this?

    Hello,
    Can anyone update on this? The issue causes us HUGE problems :(

  • Returning sql statement instead of values from database

    hi am reading value from database but my problem is am get sql statement values instead of values in database
    my code is
    java:337)

    There is no doubt: you get what you want:
        return s_getValue;
    bye
    TPD

  • Envy 4500 returns test page instead of scanned picture. No problem with text documents

    Scanning pictures returns printer test page instead of jpeg as expected.

    Hello @TEC23 , and welcome to the HP Forums, I hope you enjoy your experience!
    I see you are experiencing scan issues.  I would like to help!
    I would recommend checking to ensure there is no past alignments sheets on the scan glass from the setup, and perform a power reset.  Disconnect the power cord from the printer and the power outlet, then wait 60 seconds. After 60 seconds, plug the printer back in. Ensure you plug the printer directly to a wall outlet. Make sure to bypass any sort of surge protector or power bar.
    Good luck and please let me know the results of your troubleshooting steps. Thank you for posting on the HP Forums!
    Please click “Accept as Solution " if you feel my post solved your issue, it will help others find the solution.
    Click the “Kudos, Thumbs Up" on the right to say “Thanks" for helping!
    Jamieson
    I work on behalf of HP
    "Remember, I'm pulling for you, we're all in this together!" - Red Green.

  • Adding keywords to a topic causes search to return file names instead of topic titles

    When I search for a term in my WebHelp Pro project, the topics returned are shown by file name if the topic has anything in its Properties > General > Keywords field and are shown by topic title if there are no keywords defined for the topic.
    I've confirmed this behavior by adding and removing keywords from topics and watching them alternate between being shown in searches by file name or by topic title.
    Obviously, I want topics to be displayed by topic titles in search results no matter if they have keywords assigned or not.
    Any idea what would be causing this? Is this a known bug?
    Here's some additional information. For this problem to occur, these four conditions must be true:
    The topic must have manually added keyword(s) in the Properties > General > Keywords field.
    The topic title and the file name must be different.
    One must be searching for one of the keyword(s) added in step 1.
    Occurs in WebHelp Pro when published to a remote server.
    Talks with Adobe today are inconclusive but it appears that this was an unknown bug. Maybe I'll get a free t-shirt or something.

    Hi Rocky,
    Log on to the Robohelp Configuration Manager
    Uncheck the option "reindex documents at server".
    Republish and check. If issue exists try restarting the Apache/Tomcat Server.
    That should work for you.
    Regards,
    Robbie

  • JboWarning - returns validion exception instead of warning

    Hi defined validation method in my EO.
        public boolean validateSalary(Number salary) {
            if(salary.intValue() < 4000){
                JboWarning jboWarn = new JboWarning("Bad salary");
                jboWarn.setSeverity(JboWarning.SEVERITY_WARNING);
                getDBTransaction().addWarning(jboWarn);
            return true;
        } This method returns exeception instead of warning message for user - it behaves like a JboException

    Hi there,
    You could try the following:
        public boolean validateSalary(Number salary) {
            if(salary.intValue() < 4000){
                JboException jboException = new JboException("Bad salaray");
                jboException.setSeverity(JboWarning.SEVERITY_WARNING);
                getDBTransaction().addWarning(jboException);
            return true;
        }This should display a warning popup to the user. However if you want to associate that message with an EditatbleValueHolder on the page
    then you should construct an AttrValException, set its severity to SEVERITY_WARNING, add it to the detail list of an RowValExceptioton
    and then throw the RowValException or register it using the registerRowException() method of the RowImpl class. Foe example:
      public boolean validateManagerId(Integer managerid)
        if (managerid.intValue() < 4000) {
          // There might be an easier way to retrieve a particular AttributeDef
          AttributeDef[] attrDefs = this.getDefinitionObject().getAttributeDefs();
          AttributeDef attrDef = null;
          for (AttributeDef atDef : attrDefs) {
            if ("ManagerId".equals(atDef.getName())) {
              attrDef = atDef;
              break;
          // Construct an AttrValException and set its severity
          String errCode = "com.test.model.Departments.Manager_CUSTOM_ERROR";
          AttrValException attrEx = new AttrValException(MetaObjectBase.TYP_ENTITY_OBJECT, getResourceBundleDef(),
                                               errCode, getEntityDef().getFullName(),
                                               "ManagerId", getAttribute("ManagerId"), null, false);
          attrEx.setSeverity(JboWarning.SEVERITY_WARNING);
          // The list of detailed exceptions may hold an arbitrary number of exceptions
          ArrayList detailsList = new ArrayList();
          detailsList.add(attrEx);
          // Construct a RowValException object
          RowValException rowEx = new RowValException(getResourceBundleDef().createResourceBundle(ADFContext.getCurrent().getLocale()).getClass(),
                                                      null, getEntityDef().getFullName(), this.getKey(), detailsList, true);
    //      this.registerRowException(rowEx);
          throw rowEx;
        return true;
      }

  • Oops. Return-delimited keywords instead of comma-delimited. Help!

    I've been having trouble with "duplicated" keywords, and I think I've found the problem: I'm delimiting my keywords by typing a carriage return but I think I should've used a comma. Is there any way to batch-convert the carriage returns to commas?
    Thanks.

    no... it doesn't work.
    Replacement character is only for some conversion formats.
    HAS_FIELD_SEPARATOR :
    Doc of FM :
    Description
    Specifies if the fields in the file are separated by a tab. This is necessary if the structure passed contains several components. CR/LF occurs instead of a tab after the last field of a row.
    Value range
    'X': Fields are separated by tabs.
    SPACE: Fields are not separated by tabs. In this cas
    =====
    REPLACEMENT :
    Description
    Specifies the replacement character to be used if a character cannot be converted during a character set conversion.
    Value range
    An individual character.
    ==========
    Any clues now anybody? thanks again..

  • Acrobat Pro 9 - Form Return as pdf instead of xml?

    I have designed
    a fillable form as an overlay on an
    existing pdf.
    Everything is fine except when my client cl
    icks on the Return By Email bu
    tton it is returned to me as an xml
    file but I want it returned as a pdf.
    How can I fix this?

    Hi Bill,
    I finally had the chance to try it and it works perfectly.
    Thank you!
    Now I will pay for the license since the product DOES do what I wanted.
    Nobody at Adobe could answer this and I really appreciate your time.
    Thanks again!
    Bob

  • How to get person picker field to return as email instead of a string when emailing in a workflow?

    Hi, I have 3 person fields in Infopath 2013 form.  In the Form Option, Property Promotion, each of these people picker field, i selected the DisplayName,
    give it a column name and selected the Merge under Function.  
    In the workflow I created for this form.  Depending on selection from a radio button and a dropdown controls, I would email to one or 2 of the people selected
    from the people picker controls mentioned above.  
    In the Email To field, I select "Workflow Lookup for a User", select the field that I promoted (mentioned above), but the "Return field as"
    field is grey out, disabled. It doesn't allow the option to return as an email. I suspect it's because the 3 properties were promoted as concatenated string?  
    Now when my workflow is run, the workflow is immediately canceled.  I suspect it's the problem with the email field.  How can I promote a Person Picker
    field so it will return a email address when I use it in the email to user function in workflow?
    Thank you.

    The control I use is a Person/Group Picker.  I tried in Property Promotion selecting either DisplayName, AccountID or even the PCPerson but none of them would give me the "Return Field As" field enabled to select to return as email.   It stays
    as grey out, disabled, and return as string.  
    I suspect this is also why I'm not getting the email when workflow starts.  Where can I check if an email is sent?  I have it sent to myself, by selecting myself in the Person/Group picker but I haven't received any emails.
    Thank you.

  • SAP Webservice returning HTML response instead of SOAP

    <br>Hi,
    I want to call a webservice created from an SAP function in SAP 6.40.
    When I test this webservice with the TCPGateway tool, if no application exception occured, I receive the correct response : the <b>SOAP</b> response message:
    <soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/">
       <soap-env:Body>
          <n0:ZWsCreateWagonResponse xmlns:n0="urn:sap-com:document:sap:soap:functions:mc-style">
          </n0:ZWsCreateWagonResponse>
       </soap-env:Body>
    </soap-env:Envelope>
    <br>But if an application exception occured in the web service, I receive the response message in <b>HTML</b> :
    500 Internal Server Error
    Error when processing your request
    What has happened?
    The URL .../sap/bc/srt/rfc/sap/z_ws_create_wagon was not called due to an error.
    The following error text was processed in the system LSD : Exception condition "ALREADY_EXISTS" raised.
    The termination type was: RABAX_STATE
    The ABAP call stack was:
    Function: Z_WS_CREATE_WAGON of program SAPLZ_WS_HU
    Form: EXECUTE of program CL_SRG_RFC_PROXY_CONTEXT ---- CP
    Form: IF_SOAP_APPLICATION_RT EXEC_PROCESSING of program CL_SOAP_APPLICATION_RFC ---- CP
    Form: EXEC_PROCESSING of program CL_SOAP_RUNTIME_SERVER ---- CP
    Form: EXECUTE_PROCESSING of program CL_SOAP_RUNTIME_ROOT ---- CP
    Form: EXECUTE_PROCESSING of program CL_SOAP_RUNTIME_SERVER ---- CP
    Form: EXEC_PROCESSING of program CL_SOAP_TRANSPORT_EXTENSN_ROOTCP
    Form: EXEC_PROCESSING of program CL_SOAP_HTTP_EXTENSION ---- CP
    Form: HANDLE_REQUEST of program CL_SOAP_TRANSPORT_EXTENSN_ROOTCP
    Form: HANDLE_REQUEST of program CL_SOAP_HTTP_EXTENSION ---- CP
    <br>When I call the web service in XI with a SOAP Receiver Adapter, I get the following exception (in case of application exception but also when no application exception occured) :
    com.sap.aii.af.ra.ms.api.DeliveryException:
    <br>invalid content type for SOAP: TEXT/HTML
    So, my questions:
    - how to receive a SOAP response instead of an HTML response in case of application exception in the web service ?
    - why do I get an Invalid content type exception when the response is well a SOAP response ?
    <br><br>Thanks in advance,
    Laurence

    Thanks for your response, Sandro.
    The webservice which I use has been modified. Now if it throws an exception, I receive well a SOAP message :
    <soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/">
       <soap-env:Body>
          <soap-env:Fault>
             <faultcode>soap-env:Client</faultcode>
             <faultstring xml:lang="en">ALREADY_EXISTS</faultstring>
             <detail>
                <n0:Z_WS_CREATE_WAGON.Exception xmlns:n0="urn:sap-com:document:sap:rfc:functions">
                   <Name>ALREADY_EXISTS</Name>
                   <Text>Virus scan profile /SIHTTP/HTTP_UPLOAD is not active</Text>
                   <Message>
                      <ID>VSCAN</ID>
                      <Number>033</Number>
                   </Message>
                </n0:Z_WS_CREATE_WAGON.Exception>
             </detail>
          </soap-env:Fault>
       </soap-env:Body>
    </soap-env:Envelope>
    About the exception managing :<br>
    - In my integration process, I include the send step in a block, with property <i>Exceptions</i> =
    ALREADY_EXISTS
    - In the send step, in property <i>Exceptions</i>, I add <i>System Error</i>
    ALREADY_EXISTS
    - I insert an <i>Exception Branch</i> in the new block, <i>Exception Handler</i>
    ALREADY_EXISTS
    Is that correct?
    Do I need to use Fault messages?
    And how do I get the error message ?
    <br>In transaction ST22, I have no dump.
    <br>If it is a problem of exception managing, why do I get also the error (<i>com.sap.aii.af.ra.ms.api.DeliveryException: invalid content type for SOAP: TEXT/HTML</i>) when all is right in the web service call ?
    Regards,
    Laurence

  • Captivate 7 returns slide number instead of percentage

    I  am using an LMS which support SCORM 1.2 version courses. It was working fine with all courses created with  Captivate 6. it is not working now with Captivate 7 courses. While debugging the issue, i can see that in the previous scenario after playing a coure, it returns an integer value(i think its percentage) to my LMS as the current lesson location. But in current scenario i am getting some slide  number such as 'SLIDE_4' or 'SLIDE_6' like that. I need to track the status of play. So i need to find out percentage. I am fresher in this area. So anyone can help me to find out total percentage? Any method to find out total number of slides in a scorm course? Please reply. thanks in advance.

    Thanks for your reply.
    As per your recommendation I tried uploading SCORM courses( 1 created with Captivate 6 and the other created with Captivate 7)  to SCORM cloud. The one created with captivate 6 is working fine and is giving me the correct value in the field Percentage Of Completion. But in case of Captivate 7 it is not showing anything in the Percentage Of Completion field.
    Please help
    Regards
    Abhijith

  • How can IWD_VALUE_HELP return multiple values, instead of one

    Hello expert,
    I have requirement to use F4 help to return multiple values to the using WD component. Basically in my main WD component, I have a View where I have a list box, this list box has a F4 assigned to it, clicking on the F4 brings up hte F4 help, in the F4 help, user can select multiple values which should be returned to my main component / view to be displayed in the list box.
    I'd implement IWD_VALUE_HELP to create my own F4 help component. However I have difficulty to return multiple values. As I understand there is only way to return data from F4 help to the calling Main WD component / view:
    Item_LISTENER->F4_CONTEXT_ELEMENT->set_attribute( name = 'MYATTRName' value = myvalue).
    Do you guys know how to archive what is required here?
    Thanks
    Jayson

    Hello Jayson,
    the element reference that is passed into the IWD_VALUE_HELP implementing component is the element of the calling application's context.
    Therefore you can use methods like
    IF_WD_CONTEXT_ELEMENT->GET_NODE
    (to get the parent node of the element) and 
    IF_WD_CONTEXT_ELEMENT->GET_CHILD_NODE
    to get access to other parts of the context.
    say for example your value help should populate a pop-in table with multiple entries.
    your application allows you to choose a type of ice-cream cone and then to choose the flavour of ice-cream (multi selection)has a structure like:
    Context_root
    --> List_of_ice_creams (0..n)
    >Ice_cream_flavours(1..n)
    In the element of list_of_ice_creams you have an attribute "flavour" which links to your value help.
    Choosing this value-help should allow you to select multiple flavours, return these and populate them into the sub-node Ice_cream_flavours.
    Within your custom value help you can get a reference to the node Ice_cream_flavours by calling the method
    lo_flavour_node = IItem_LISTENER->F4_CONTEXT_ELEMENT->GET_CHILD_NODE("ICE_CREAM_FLAVOURS"). You could then populate this in you value help component.
    As I mentioned - this isn't great as it means the value help cannot really be used elsewhere as it has a dependency on the structure of the calling context. But that may not be an issue for you.
    Hope that helps,
    Chris

  • MATERIAL TO MATERIAL TRANSFER MVT TYPE 301 INSTEAD OF 309

    AS WE TRANSFER MATERIAL TO MATERIAL FROM
    MVT TYPE 309
    BUT WE CAN TRANSFER THIS FROM 301 ALSO,
    SO WHAT WOULD BE THE DIFF BETWEEN 301 AND 309
    AND IF WE TRANSFER FROM 301 THEN WHAT WOULD BE THE CONSEQUENCES.

    Hi Nitin,
    Main difference is by 301 you transfer material from one storage location to other of different plants. Material stock will transfer from one sloc to other
    eg transfer of material A from ST01 of 1000 plant to Material A ST01 of 2000 plant. Material A will physically moved.
    But 309 is made for transfering material from one code to other may be same plant or diiferent (mostly used in chemical industry.)
    eg transfer of material A frm ST01 of 1000 to material B ST01 of 1000 plant. Material may moved if plant is different.
    Reward if useful,
    regs
    Appie

Maybe you are looking for

  • Camera raw cs5.5 in windows vista 32 bit

    I have to install Photoshop again. Version is CS5.5 on a windows vista 32 bit system. It did what it needed to do. Photoshop runs, Bridge runs. That is all I need. However it installed only camera raw 6.0 something. For my files I need at least camer

  • CartApp not Working

    Hi, I took the CartApp straight from the tutorials and tried to deploy it to confirm the environment. I also deployed the Converter app that is part of the J2EE tutorial. The converter app works, but the CartApp gives the following error:"exception:j

  • In my family we have 3IPhones 4S, one IPhone5, one IPad3, one IPadMini and two IPad 4. Is it possible to use the same energieadapter for all of those ?

    In my family we have 3IPhones 4S, one IPhone5, one IPad3, one IPadMini and two IPad 4. Is it possible to use the same energieadapter for all of those ?

  • Data lost in Production

    Hi Everyone, We got a very big problem in production system. We had transported one ztable (contains customer number, material as primary key) to production earlier. this ztable contains data which was updated by users. We had changed date also prima

  • HELP PLEASE!  Major Problem with FCP Project

    OK I am starting to panic. I was editing a wedding video for a client on this 150GB proMAX external hard drive. Everything as fine until this morning. Now when I go to open the project I always get a fatal error. What happens is the project begins to