Filter problem with jsp:forward

Greetings,
I was trying to implement compression filter in oc4j. Basically wrap a HttpResponseServletResponseWrapper using a GZipOutputStream for supported browsers. However whenever for eg: I have a.jsp which does jsp:forward page =b.jsp I can see in TCP monitor IllegalStateException response already committed. But I dont see any stack trace in server logs. The buffer size is 2048 and I am pretty sure it did not get filled up before the forward. I would appreciate if anybody has seen such behavior using wrapped response in OC4j(the same code works fine in tomcat and websphere). Also one thing I observed is that for every jsp:include the filter is being called (to handle this I create the wrapper if its not already there and maintain entry count into filter and decrement when I exit filter and finish gzip response when entry count become 0,which works fine). I believe that this is not a part of 2.3 spec.Even in 2.4 spec if the filter config in web.xml is not set to any value by default the filter is supposed to be in request scope. I really appreciate any pointers in resolving this

I am pasting the stack trace for broken pipe exception. Please let me know if anybody knows the resolution. Please let me know if there is any other way to enable compression of jsp in oc4j in 9 version. The same code works in Jboss/tomacat websphere ! Also from the stack trace we can see that filter is being called for each forward and its not as per 2.3 servlet specification. Even in 2.4 by default the filter is supposed to work at request level.
Also I have another question oc4j seems to be using hard coded value: if length is more than 100k or so it uses Transfer-Encoding chunked. Is there any clean way of disabling this behaviour for .js files? the reason is for some reason Internet explore does not cache the javascript files properly (sporadically ) when chunked response is used for javascript files.
4/26/06 4:58 PM: com.evermind.server.http.HttpIOException: Broken pipe
4/26/06 4:58 PM: at com.evermind.server.http.EvermindServletOutputStream.flush(EvermindServletOutputStream.java:286)
4/26/06 4:58 PM: at java.io.FilterOutputStream.flush(FilterOutputStream.java:121)
4/26/06 4:58 PM: at filters.gzip.GzipServletResponseStream.flush(GzipServletResponseStream.java:151)
4/26/06 4:58 PM: at filters.gzip.GZipServletResponseWrapper.flushBuffer(GZipServletResponseWrapper.java:127)
4/26/06 4:58 PM: at com.evermind.server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:244)
4/26/06 4:58 PM: at com.evermind.server.http.GetParametersRequestDispatcher.forward(GetParametersRequestDispatcher.java:189)
4/26/06 4:58 PM: at com.evermind.server.http.EvermindPageContext.forward(EvermindPageContext.java:199)
4/26/06 4:58 PM: at SecondPage.jspService(_SecondPage.java:83)
4/26/06 4:58 PM: at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:56)
4/26/06 4:58 PM: at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:317)
4/26/06 4:58 PM: at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:465)
4/26/06 4:58 PM: at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:379)
4/26/06 4:58 PM: at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
4/26/06 4:58 PM: at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)
4/26/06 4:58 PM: at filters.CookieFilter.processRequest(CookieFilter.java:522)
4/26/06 4:58 PM: at filters.CookieFilter.validateRequest(CookieFilter.java:127)
4/26/06 4:58 PM: at filters.CookieFilter.doFilter(CookieFilter.java:51)
4/26/06 4:58 PM: at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:16)
4/26/06 4:58 PM: at filters.gzip.GZipFilter.doFilter(GZipFilter.java:176)
4/26/06 4:58 PM: at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:556)
4/26/06 4:58 PM: at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:306)
4/26/06 4:58 PM: at com.evermind.server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:240)
4/26/06 4:58 PM: at com.evermind.server.http.GetParametersRequestDispatcher.forward(GetParametersRequestDispatcher.java:189)
4/26/06 4:58 PM: at com.evermind.server.http.EvermindPageContext.forward(EvermindPageContext.java:199)
4/26/06 4:58 PM: at FirstPage.jspService(_FirstPage.java:131)
4/26/06 4:58 PM: at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:56)
4/26/06 4:58 PM: at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:317)
4/26/06 4:58 PM: at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:465)
4/26/06 4:58 PM: at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:379)
4/26/06 4:58 PM: at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
4/26/06 4:58 PM: at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)
4/26/06 4:58 PM: at filters.CookieFilter.processRequest(CookieFilter.java:522)
4/26/06 4:58 PM: at filters.CookieFilter.validateRequest(CookieFilter.java:127)
4/26/06 4:58 PM: at filters.CookieFilter.doFilter(CookieFilter.java:51)
4/26/06 4:58 PM: at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:16)
4/26/06 4:58 PM: at filters.gzip.GZipFilter.doFilter(GZipFilter.java:176)
4/26/06 4:58 PM: at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:556)
4/26/06 4:58 PM: at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:306)
4/26/06 4:58 PM: at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:767)
4/26/06 4:58 PM: at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:259)
4/26/06 4:58 PM: at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:106)
4/26/06 4:58 PM: at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:803)
4/26/06 4:58 PM: at java.lang.Thread.run(Thread.java:479)

Similar Messages

  • Help with JSP Forward !!!

    I have 3 pages ...1) index.jsp 2) Forward.jsp 3) welcome.jsp
    I have 2 fields in the index.jsp once upon filling & hit submit it has to to go Forward.jsp page...in the Forward.jsp..i have coded only one tag with
    <jsp:forward page="welcome.jsp" />
    I have one question...once the page comes to Forward page...will it display the contents of the Welcome .jsp in the same page itself...or it will go to Welcome.jsp page..
    As i saw it will display the contents of Welcome.jsp page in itself...
    Please let me know...
    Regards
    Gnanesh

    I understand your question only because I have a set up totally identical to yours. The thread Matt suggested does explain the situation (i.e. the server passed control to another page but the client doesn't know that), but doesn't necessarily give a good solution a problem that you may have, and that I do have:
    If the user sees the welcome page, and for some reason decides to "reload", the forward page is re-executed, even though it has done its job. This could be a problem for session management if you specifically don't want that job being done twice in a session. Now you could hack around that, but I'd really rather see a neat solution. Is there one?

  • HELP!! asa 5505 8.4(5) problem with port forwarding-smtp

    Hi I am having a big problem with port forwarding on my asa. I am trying to forward smtp through the asa  to my mail server.
    my mail server ip is 10.0.0.2 and my outside interface is 80.80.80.80 , the ASA is setup with pppoe (I get internet access no problem and that seems fine)
    When I run a trace i get "(ACL-Drop) - flow is deied by configured rule"
    below is my config file , any help would be appreciated
    Result of the command: "show running-config"
    : Saved
    ASA Version 8.4(5)
    hostname ciscoasa
    domain-name domain.local
    enable password mXa5sNUu4rCZ.t5y encrypted
    passwd 2KFQnbNIdI.2KYOU encrypted
    names
    interface Ethernet0/0
    switchport access vlan 2
    interface Ethernet0/1
    interface Ethernet0/2
    interface Ethernet0/3
    interface Ethernet0/4
    interface Ethernet0/5
    interface Ethernet0/6
    interface Ethernet0/7
    interface Vlan1
    nameif inside
    security-level 100
    ip address 10.0.0.1 255.255.255.0
    interface Vlan2
    nameif outside
    security-level 0
    pppoe client vpdn group ISPDsl
    ip address 80.80.80.80 255.255.255.255 pppoe setroute
    ftp mode passive
    dns server-group DefaultDNS
    domain-name domain.local
    same-security-traffic permit intra-interface
    object network obj_any
    subnet 0.0.0.0 0.0.0.0
    object network Server_SMTP
    host 10.0.0.2
    access-list outside_access_in extended permit tcp any object server_SMTP eq smtp
    pager lines 24
    logging asdm informational
    mtu inside 1500
    mtu outside 1500
    icmp unreachable rate-limit 1 burst-size 1
    no asdm history enable
    arp timeout 14400
    no arp permit-nonconnected
    object network obj_any
    nat (inside,outside) dynamic interface
    object network server_SMTP
    nat (inside,outside) static interface service tcp smtp smtp
    nat (inside,outside) after-auto source dynamic any interface
    access-group outside_access_in in interface outside
    timeout xlate 3:00:00
    timeout pat-xlate 0:00:30
    timeout conn 1:00:00 half-closed 0:10:00 udp 0:02:00 icmp 0:00:02
    timeout sunrpc 0:10:00 h323 0:05:00 h225 1:00:00 mgcp 0:05:00 mgcp-pat 0:05:00
    timeout sip 0:30:00 sip_media 0:02:00 sip-invite 0:03:00 sip-disconnect 0:02:00
    timeout sip-provisional-media 0:02:00 uauth 0:05:00 absolute
    timeout tcp-proxy-reassembly 0:01:00
    timeout floating-conn 0:00:00
    dynamic-access-policy-record DfltAccessPolicy
    user-identity default-domain LOCAL
    http server enable
    http 10.0.0.0 255.255.255.0 inside
    no snmp-server location
    no snmp-server contact
    snmp-server enable traps snmp authentication linkup linkdown coldstart warmstart
    telnet timeout 5
    ssh timeout 5
    ssh key-exchange group dh-group1-sha1
    console timeout 0
    vpdn group ISP request dialout pppoe
    vpdn group ISP localname [email protected]
    vpdn group ISP ppp authentication chap
    vpdn username [email protected] password *****
    dhcpd auto_config outside
    threat-detection basic-threat
    threat-detection statistics access-list
    no threat-detection statistics tcp-intercept
    webvpn
    class-map inspection_default
    match default-inspection-traffic
    policy-map type inspect dns preset_dns_map
    parameters
      message-length maximum client auto
      message-length maximum 512
    policy-map global_policy
    class inspection_default
      inspect dns preset_dns_map
      inspect ftp
      inspect h323 h225
      inspect h323 ras
      inspect rsh
      inspect rtsp
      inspect sqlnet
      inspect skinny 
      inspect sunrpc
      inspect xdmcp
      inspect sip 
      inspect netbios
      inspect tftp
      inspect ip-options
    service-policy global_policy global
    prompt hostname context
    no call-home reporting anonymous
    Cryptochecksum:c5570d7ddffd46c528a76e515e65f366
    : end

    Hi Jennifer
    I have removed that nat line as suggested but still no joy.
    here is my current config
    Result of the command: "show running-config"
    : Saved
    ASA Version 8.4(5)
    hostname ciscoasa
    domain-name domain.local
    enable password mXa5sNUu4rCZ.t5y encrypted
    passwd 2KFQnbNIdI.2KYOU encrypted
    names
    interface Ethernet0/0
    switchport access vlan 2
    interface Ethernet0/1
    interface Ethernet0/2
    interface Ethernet0/3
    interface Ethernet0/4
    interface Ethernet0/5
    interface Ethernet0/6
    interface Ethernet0/7
    interface Vlan1
    nameif inside
    security-level 100
    ip address 10.0.0.1 255.255.255.0
    interface Vlan2
    nameif outside
    security-level 0
    pppoe client vpdn group ISP
    ip address 80.80.80.80 255.255.255.255 pppoe setroute
    ftp mode passive
    dns server-group DefaultDNS
    domain-name domain.local
    same-security-traffic permit intra-interface
    object network obj_any
    subnet 0.0.0.0 0.0.0.0
    object network Server_Mail
    host 10.0.0.2
    access-list outside_access_in extended permit tcp any object Server_Mail eq smtp
    pager lines 24
    logging asdm informational
    mtu inside 1500
    mtu outside 1500
    icmp unreachable rate-limit 1 burst-size 1
    no asdm history enable
    arp timeout 14400
    no arp permit-nonconnected
    object network obj_any
    nat (inside,outside) dynamic interface
    object network Server_Mail
    nat (inside,outside) static interface service tcp smtp smtp
    access-group outside_access_in in interface outside
    timeout xlate 3:00:00
    timeout pat-xlate 0:00:30
    timeout conn 1:00:00 half-closed 0:10:00 udp 0:02:00 icmp 0:00:02
    timeout sunrpc 0:10:00 h323 0:05:00 h225 1:00:00 mgcp 0:05:00 mgcp-pat 0:05:00
    timeout sip 0:30:00 sip_media 0:02:00 sip-invite 0:03:00 sip-disconnect 0:02:00
    timeout sip-provisional-media 0:02:00 uauth 0:05:00 absolute
    timeout tcp-proxy-reassembly 0:01:00
    timeout floating-conn 0:00:00
    dynamic-access-policy-record DfltAccessPolicy
    user-identity default-domain LOCAL
    http server enable
    http 10.0.0.0 255.255.255.0 inside
    no snmp-server location
    no snmp-server contact
    snmp-server enable traps snmp authentication linkup linkdown coldstart warmstart
    telnet timeout 5
    ssh timeout 5
    ssh key-exchange group dh-group1-sha1
    console timeout 0
    vpdn group ISP request dialout pppoe
    vpdn group ISP localname [email protected]
    vpdn group ISP ppp authentication chap
    vpdn username [email protected] password *****
    dhcpd auto_config outside
    threat-detection basic-threat
    threat-detection statistics access-list
    no threat-detection statistics tcp-intercept
    webvpn
    class-map inspection_default
    match default-inspection-traffic
    policy-map type inspect dns preset_dns_map
    parameters
      message-length maximum client auto
      message-length maximum 512
    policy-map global_policy
    class inspection_default
      inspect dns preset_dns_map
      inspect ftp
      inspect h323 h225
      inspect h323 ras
      inspect rsh
      inspect rtsp
      inspect esmtp
      inspect sqlnet
      inspect skinny 
      inspect sunrpc
      inspect xdmcp
      inspect sip 
      inspect netbios
      inspect tftp
      inspect ip-options
    service-policy global_policy global
    prompt hostname context
    no call-home reporting anonymous
    Cryptochecksum:f3bd954d1f9499595aab4f9da8c15795
    : end
    also here is the packet trace
    and my acl
    Thanks

  • Problem with call forwarding. Calls can not be forwarded for incoming external calls

    Hi Everybody, how are you?
    I have a problem with call forwarding. Everything was fine but now is not working.
    In the reception of an office, the receptionist activate the call forward option to an internal extension. If somebody, internal in the office, call to the reception, the call is forwarding to the extension configured. But if I call from the outside (in example, from my cellphone) the call is not forwarded to the extension configured and continue ringing in the reception phone. Why this behavior? Any idea?
    If you know something please tell me.
    Thanks. Best regards.
    Andres Collazos.

    I encounter a similar problem with 9.1.1.
    My problem is link to this bug ID : CSCtq10477.
    Mathieu

  • Problem with Port Forwarding in WRT320N

    Good day.
    I have a web-server and Internet-radio translator to local network of my provider. And I found a problem with Port Forwarding. I'm trying to setup 80 & 8000 ports to forward. And it's working but only for Internet, without provider's local network. My web-server isn't accessible in local network and radio-translator too. 
    So is it possible to forward ports absolutely - for any type of connections? 
    P.S. DMZ is working like Port Forwarding.

    If you ask questions you have to mention that you have an PPTP connection to the internet and another network directly on the internet port. Otherwise noone will really understand your question as it is a very unusual setup.
    Your setup is not one really supported by the router. You are lucky that it works but don't expect too much. Port forwarding only the internet connection. If you use PPTP the network on the internet port is basically hidden. Using that local network on the internet port is not supported.
    The DMZ host is the IP address to which all ports are forwarded to which are not forwarded otherwise. The same restriction applies here.
    I would recommend to ask your ISP which router they recommend for their internet connection. I think most/all Linksys routers and many other brand's consumer routers won't really support a setup like yours...

  • Problem using jsp:forward in java script

    hi,
    when I use jsp forward tag inside java script i'm getting a problem that
    when the jsp is invoked it is getting forwarded to the page specified in the forward tag, without checking the if conditions. Following code may give you a better idea.
    <html>
    <script>
    function test()
    if(document.f.htemp.value=="true")
    alert("jus");
    else
    var s=document.f.htemp.value;
    alert(s);
    <jsp:forward page="success.jsp" />
    </script>
    <body>
    <form name="f" method=post>
    <input type=text name=htemp value="true">
    <input type=button onclick="test()">
    </form>
    </body>
    </html>
    please help me,thanks inadvance
    regards
    chandu

    What pgeuens means is that you can't mix javascript and jsp/java code in this way.
    ALL of the jsp/java code gets executed at the server end.
    This produces an HTML page (with embedded javascript) which gets sent to the client.
    The client then runs javascript code in response to events (onLoad, onClick, onChange etc etc)
    So in this case, the jsp:forward will always be executed, because as far as the server is concerned, the javascript is just template text.
    If you WANT to do a conditional forwarding on the server side you do it in java ie (horribly using scriptlet)
    <%
    if (testCondition){
    %>
      <jsp:forward>
    %<
    %>Or if you want to test what the client has entered client side, all you can do is submit the form, or navigate to a URL
    <script>
    function test()
    if(document.f.htemp.value=="true")
    alert("jus");
    else
    var s=document.f.htemp.value;
    alert(s);
    document.f1.action="success.jsp";
    document.f.submit();
    </script>You cannot run JSP code based on your javascript code.
    Java. Javascript. Not the same thing.
    Hope this helps,
    evnafets

  • SQL problem with JSP

    In sql statements with JSP. Heres the deal:
    Access database:
    Tablename: EVENT
    FieldName: event_id
    DataType: Number
    I want to compare the event_id to an integer variable called "var" in a WHERE clause in an SQL statement through a JSP.
    String query = "SELECT * FROM EVENT WHERE EVENT.event_id = 'var' ";
    It says "Data type mismatch in criteria expression."
    Any Suggestions? I thought this should be straight forward! am i missing something?

    if i am reading correctly "var" is an int variable correct? If this is the case then the following will work;
    String query = "SELECT * FROM EVENT WHERE EVENT.event_id = " + Interger.toString(var) ;
    Hope that helps ( and i hope i read your problem correctly)

  • Weird behaviour with jsp:forward and jsp:param

    I'm running Orion 1.5.3
    Wanted to ask if anyone has insight into the following.
    I'm trying to do a forward with a parameter. The parameter is something like a message string.
    The following does not work.
    <%
    String result = "unsucessful"; // retrieved from external source... hardcoded for example's sake
    %>
    <jsp:forward page="<%=nextPage%>">
    <jsp:param name="message" value="The result was <%=result%>"/>
    </jsp:forward>
    I've managed to deduce that the error is in the param value. Apparently, we cannot mix variables with static values inside the value parameter.
    I've managed to get it working by doing this...
    <%
    String result = "unsucessful"; // retrieved from external source... hardcoded for example's sake
    String message = "The result was " + result;
    %>
    <jsp:forward page="<%=nextPage%>">
    <jsp:param name="message" value="<%=message%>"/>
    </jsp:forward>
    My question is, is this a bug or is it supposed to be this way ? Can we mix the value parameters ?

    Hi Bernard,
    Take a note of the following syntax -
    <jsp:forward page={"relativeURL" | "<%= expression %>"} >
    <jsp:param name="parameterName"
    value="{parameterValue | <%= expression %>}" />+
    </jsp:forward>
    It is evident that either the value attribute can have an expression or simple text.
    I have tried your example and I am also encountering the same kind of problem, but I have found a way out.
    You can try the following in your code -
    <%
    String result = "unsucessful"; // retrieved from external source... hardcoded for example's sake
    %>
    <jsp:forward page="<%=nextPage%>">
    <jsp:param name="message" value=' <%= "The result was" + result%>'/>
    </jsp:forward>
    Instead of using
    value= "The result was <%=result%>" you can use
    value= '<%= "The result was" + result%>'.
    Hope this helps

  • Filter problem with operating system in french

    Hello,
    There is a problem with the "Operating System - Windows" filter in the french version of ZCC.
    If you create a bundle and go into "Requirements" and add a filter with Operating system and you set it to "Version 6.1 - Windows 7 / Windows Server 2008 R2" you get this error
    "Vos modifications ne peuvent pas tre appliques pour les raisons suivantes :
    ErreurLa version doit tre sous la forme "x" "x.x.x.x". "
    "You changes cannot be applied for the following reason : formatting must be x to x.x.x.x"
    The format should be "6.1 - Windows 7 /Windows Server 2008 R2 Versions".
    The filter does work as intended with the english versions of ZCC. I have no problem with that but some of our admin does.
    PS : I am currently unable to open an SR because our licence has not been renewed yet. So i am reporting this here.
    Thank you!

    Originally Posted by GuillaumeBDEB
    Hi poplante, this bug is haunting Novell since version 11.0! Believe me on that. I'm the one who reported it. Here's the workaround.
    1.Go to Server machine.
    On Windows:
    Go to
    %ZENWORKS_HOME%\resources\properties\com\novell\ze nworks\core\web\internal\resources\CoreInternal_fr .proeprties
    On Linux:
    Go to
    /opt/novell/zenworks/resources/properties\com/novell/zenworks/core/web/internal/resources/CoreInternal_fr.proeprties
    2.change the property value of windows.versions.6.1 from "Versions 6.1 Windows 7 / Windows Server 2008 R2" to "6.1 Versions Windows 7 / Windows Server 2008R2"
    3.Then Restart the server. The issue will be gone.
    By the way you will see this bug reappear with every new update of ZENworks including new service packs and monthly updates. So keep this workaround at hand just in case.
    Hope it helps!
    GuillaumeBDEB
    In 11.3 the value seems to be:
    windows.versions.6.1=Versions 6.1 - Windows 7 / Windows Server 2008 R2
    But should probably be set to:
    windows.versions.6.1=6.1 - Versions Windows 7 / Windows Server 2008 R2
    And the correct Linux path would be: /opt/novell/zenworks/resources/properties/com/novell/zenworks/core/web/internal/resources/CoreInternal_fr.properties.
    This bug would probably take them a minute or two to fix, sad to hear that it's been there since 11.
    Thomas

  • Cookie Problem  With JSP and Tomcat

    I have a tiny web application developed for my project thing.
    I am facing a problem while maintaining sessions with Cookie. I use Tomcat 3.2.1 Web Server and JSP 1.2 Specifications for my web application.
    I have created a page which creates a cookie and stores it in the client's PC, so when the same client visits the site, he can be remembered. Now while surfing the site in the same session, the site remembers the client. But once the client closes the browser and tries connecting to the site, he cannot be remembered. So I took a look into Temporary Internet Files of the client PC and found no cookie there. So where the cookie gets created and why does it disappears with the session. I have set a time limit of 1 year in the cookie.
    Now is that a Problem with Tomcat or with the configuration settings of IE in the client PC?? Or something else???
    Reply me Soon...

    Thanks for your reply.
    following is the code for how do i create a cookie...
    <%
         String custno = custBean.createPreferred();
         Cookie c = new Cookie("pc", custno);
         c.setVersion(1);
         c.setPath("/");
         c.setComment("PreferredCustomer");
         c.setDomain("think_machine");
    //think_machine is the name of the Web Server(Tomcat)
         c.setMaxAge(365*24*60*60);
         response.addCookie(c);
    %>
    And the code to read a cookie is..
         String custID = null;
         Cookie[] cookies = request.getCookies();
         for(int i = 0; i < cookies.length; i++)
              if(cookies.getName().equals("pc"))
                   custID = cookies[i].getValue();
                   break;
    One more thing I would like to let you know, that i access this from the same PC on which the Web Server is installed. Means the Server and the client are both one and the same PC.

  • Having Problem with JSP In Netscape!HELP!!!

    HI to all! I�m having problem with the jsp that i have :( If i use the Internet explorer it works but at Netscape... it doesn�t work :( The value of "PTE" is null... I need help !!!Please! I think the HTML IS NOT HELPING ...
    the code is :
    <html>
    <head>
    <!--tp001_transferencias_oic_POR.jsp-->
    <title>BBVA - Transfer&ecirc;ncias - Transfer&ecirc;ncias OIC</title>
    <LINK rel=STYLESHEET type='text/css' href="estilos/tablas.css">
    <!--script language="javascript" src "js/dynlayer.js"></script-->
    <script language="Javascript" src="js/banner.js"></script>
    <script language="Javascript" src="js/tp_oic.js"></script>
    <script language="Javascript" src="js/utilidades.js"></script>
    <script language="javascript" src="js/limpar.js"></script>
    <script language="javascript" src="js/tiempo.js"></script>
    </HEAD>
    <body marginheight="0" marginwidth="0" leftmargin="0" topmargin="0" class="pag-contenido" onLoad="controlSesion();">
    <%@ include file ="includecbtf.jsp" %>
    <% String s = (String)datos.get("dt");
    java.util.StringTokenizer str = new java.util.StringTokenizer(s, "-");
    String anoServer = str.nextToken() ;
    String mesServer = str.nextToken() ;
    String diaServer = str.nextToken() ;
    %>
    <!--1�form-->
    <form method="post" name="captura" action="<%=urls.get("action")%>">
    <center> <!--1�center-->
    <br>
    <!--1�table-->
    <table border="0" cellpadding="0" cellspacing="0" width="500"> <!--table das transf e nome-->
    <tr>
    <td colspan="3"><img src="images/linea.gif" border="0"></td>
    </tr>
    <tr>
    <td width="250"><img src="images/traspasos.gif" border="0"></td>
    <td width="82"><img src="images/titular.gif" border="0"></td>
    <td width="169" class="fondotitular"><font class="texttitular"><%=datos.get("usuario")%></font></td>
    </tr>
    <tr>
    <td colspan="3"><img src="images/linea.gif" border="0"></td>
    </tr>
    </table> <!--Fim do 1� table-->
    <br><br>
    </center> <!--Fim do 1� Center-->
    <center> <!--2� Center-->
    <!--Conteudo do table 2-->
    <table cellpadding="3" cellspacing="1" border="0" align="center" width="500"> <!--table referente a mensagem-->
    <tr>
    <td class="cabeceratitulo" colspan="2"><p class="titulotabla">Nota : As Transfer&ecirc;ncias para outras Institui&ccedil;&otilde;es de Cr&eacute;dito decorrem de acordo com os hor&aacute;rios da Compensa&ccedil;&atilde;o Interbanc&aacute;ria, n&atilde;o se responsabilizando o BBVA pela sua realiza&ccedil;&atilde;o fora das regras em uso.</p></td>
    </tr>
    <tr></tr><tr></tr><tr></tr><tr></tr><tr></tr><tr></tr><tr></tr><tr></tr><tr></tr>
    </table> <!--fim do table2-->
    </center> <!--Fim do 2� Center-->
    <center> <!-- Inicio 3� Center-->
    <!--Conteudo da table Combo-->
    <!--Table3-->
    <table cellpadding="3" cellspacing="1" border="0" align="center" width="500">
    <tr>
    <td class="cabeceratitulo" colspan="2"><p class="titulotabla">Transfer&ecirc;ncia Conta a Conta para outras Institui&ccedil;&ocirc;es de Cr&eacute;dito</p></td>
    </tr>
    <tr>
    <td class="formgrisosc" width="100">
    <p class="dato">Conta Ordenante:  </p></td>
    <td class="formgrisosc" width="300">
         <%
    java.util.Vector v = (java.util.Vector)(datos.get("ListaCuentas"));
    java.util.Hashtable elem;
    java.util.Enumeration e = v.elements();
    %>
    <!--1� Select-->
    <select name="conta" size="1" class="formgrisosc">
    <%
    while (e.hasMoreElements()){
    elem = (com.ibm.dse.base.Hashtable)(e.nextElement());
    String cuenta = ((String)elem.get("s_banco")).trim() + "-"+((String)elem.get("s_oficina")).trim()+((String)elem.get("s_dcontrol")).trim()+((String)elem.get("s_num_cuenta")).trim();
    out.println("<option value=\"" + ((String)elem.get("s_tipo")) + "$" + ((String)elem.get("s_clave_asunto")) + "\">" + cuenta + "</option>");
    %>
    </select> <!--Fim do 1� Select-->
    </td>
    </tr>
    <tr>
    <td class="formgriscla" width="100"><p class="dato">Data de Processamento:</p></td>
    <td class="formgriscla">
    <input type="text" name="dia" size="2"class="formgriscla" value="<%=diaServer %>" maxlength="2" class="formgriscla"> / 
    <input type="text" name="mes" size="2"class="formgriscla" value="<%=mesServer %>" maxlength="2" class="formgriscla"> / 
    <input type="text" name="ano" size="4"class="formgriscla" value="<%=anoServer %>" maxlength="4" class="formgriscla"></td>
    <input type="hidden" name="dact" size="2"class="formgriscla" value="<%=diaServer %>" maxlength="2" class="formgriscla">
    <input type="hidden" name="mact" size="2"class="formgriscla" value="<%=mesServer %>" maxlength="2" class="formgriscla">
    <input type="hidden" name="aact" size="4"class="formgriscla" value="<%=anoServer %>" maxlength="4" class="formgriscla"></td>
    </tr>
    <tr>
    <td class="formgrisosc" width="100"><p class="dato">Moeda: </p></td>
    <td class="formgrisosc"><p class="dato">
    <!--Select 2�Ver este bem-->
    <select name="Moeda" size="1" class="formgrisosc">
    <option value="PTE" selected>Escudos</option>      
    <option value="EUR">Euros</option>
    </select> </p>
    </td>
    </tr>
    <tr>
    <td class="formgriscla" width="100"><p class="dato">Import&acirc;ncia:</p></td>
    <td class="formgriscla"><input type="text" name="importancia" size="20" maxlength="15" class="formgriscla"></td>
    </tr>
    <tr>
    <td class="formgrisosc" width="100"><p class="dato">Ref&ecirc;rencia:</p></td>
    <td class="formgrisosc"><input type="text" name="ref" size="15" maxlength="10" class="formgrisosc"></td>
    </tr>
    <tr>
    <td class="formgriscla" width="100"><p class="dato">NIB Benefici&aacute;rio:</p></td>
    <td class="formgriscla"><input type="text" name="nibBeneficiario" size="30" maxlength="21" class="formgriscla"></td>
    </tr>
    <tr>
    <td class="formgrisosc" width="100"><p class="dato">Descri&ccedil;&atilde;o p/ Conta D&eacute;bito:</p></td>
    <td class="formgrisosc"><input type="text" name="debito" size="45" maxlength="45" class="formgrisosc"></td>
    </tr>
    <tr>
    <td class="formgriscla" width="100"><p class="dato">Descri&ccedil;&atilde;o p/ Conta Cr&eacute;dito:</p></td>
    <td class="formgriscla"><input type="text" name="credito" size="45" maxlength="45" class="formgriscla"></td>
    </tr>
    <tr>
    <td class="cabecera" colspan="2"><img src="images/1x1.gif" width=1 height=3 border="0"></td>
    </tr>
    </table> <!--Fim do table 3-->
    </center> <!--Fim do 3�center-->
    <center> <!--Inicio do 4� Center-->
    <!--Inicio da table 4�-->
    <table border="0" cellspacing="2" cellpadding="0">
    <tr>
    <td valign="top"><img src="images/limpar.gif" border="0" alt="Apagar"></td>
    <td valign="top"><img src="images/continuar.gif" border="0" alt="Continuar"></td>
    </tr>
    </table> <!--Fim do 4� Table-->
    </form> <!--Fim do FORM-->
    </center> <!--Fim do 4� Center-->
    </body> <!--Fim do BODY-->
    </html> <!--Fim do Html-->
    Thanks pepole!

    thanks people! when i try to validate the action "PTE" he gaves me (if i put a ALERT...) null.
    the js code is : (Moeda is coin )
    //testa amount
    // var ent = (f.amount.value);
    var tamanho = f.amount.value.length;
    var valor = f.amount.value;
    decimals = 2; // Apenas pode ter duas casas decimais?
    if (((tamanho == 0) || (valor == 0)) && ok)
    alert ("A import�ncia tem de ser maior que zero.");
    f.amount.focus();
    f.amount.select();
    ok = false;
    else
         alert(f.Moeda.value);
    if((f.Moeda.value=="PTE") && ok)
    for (j = 0; j < tamanho; j++)
    xx = valor.charAt(j);     
         if ((!(xx.match(numeroER)) && ok))
    alert ("O Campo Import�ncia deve ser num�rico inteiro.");     
         f.amount.focus();
         f.amount.select();
         ok = false;
              //if para limitar valor dos Escudos      
         if (ok)
         if (eval(valor) > 1000000)
         alert ("The field amount must be maxium 1 000 000 Pte.");     
         f.amount.focus();
         f.amount.select();
         ok = false;
    else
         if (ok)
              //function checkDecimals(f.amount, f.importancia.value) {
              if (isNaN(valor)) {
                   alert("O Campo Import�ncia deve ser num�rico e como separador decimal, o ponto.");
                   f.amount.select();
                   f.amount.focus();
                   ok = false;
              else {
                   timeshundred = parseFloat(valor * Math.pow(10, decimals));
                   integervalue = parseInt(parseFloat(valor) * Math.pow(10, decimals));
                   if (timeshundred != integervalue)
                   alert ("Apenas pode ter " + decimals + " casas decimais. Por favor tente outra vez.");
                   f.amount.select();
                   f.amount.focus();
                   ok = false;
              if (ok)
              {  //if to limit the value of the  Euros
         if(eval(valor) > 4988)
    alert ("The field amount must be maxium 4988 Eur.");     
         f.amount.focus();
         f.amount.select();
         ok = false;
    }//end of amount

  • Problem in jsp:forward

    hi,
    i have a jsp page from where i have to call my servlet.but it is mapped in xml by other name.so what should i do?can i call that servlet using named mapped into the xml.
    can i do this?
    <jsp:forward page="/servlet/web.xml mapping"></jsp:forward>
    it's urgent.
    so please help me.
    kamlesh solanki

    hey man,
    how u doin?
    your problem is quite funny. here in servlet configuration in the xml file there is what we call servlet mapping<servlet-mapping>.
    here is how we map a servlet to a kind of url:
    <servlet-mapping>
    <servlet-name>
    havet
    <servlet-name>
    <url-pattern>
    /havva.jspa
    </url-pattern>
    </servlet-mapping>
    nbow when calling this servlet using this url pattern it now behaves as if its in the main application directory just like where jsps are so u will forward to it like a jsp.
    thats the shizzy.
    ok call it like this now
    <jsp:forward page="havva.jspa" />
    or
    <jsp:forward page="havva.jspa"></jsp:forward>
    since u may be used to this style of calling the tag.
    stay cool and let me know if u had any problems.

  • JSTL problem with JSP

    Hi,
    I am developing enterprise application using jboss portlets, ejb, jsp, jstl, other stuff on jboss AS.
    I am facing some interesting problem in a jsp page which uses jstl. I have configured all jsp configurations with my web application.
    Presently i am putting an endpage, current page integer values in a session.
    In JSP page whenever i want to iterate a loop and some checks on endPage, curPage it gives me NumberFormatException and finally it results to compile the jsp page.
    The error comes when i am using these variables from session with JSTL tags. The snippet where the problem seems to be is as :
    <c:forEach var="selection" begin="1" end="${endPage}">
         <c:if test="${selection == curPage}">
    May anyone help me on this or whether the there may be some problems with the JSTL configurations ?
    In my view JSTL configurations is ok but the problems seems to be in the statements above or there may be some other way to define it.
    Any inputs ?
    -Sachin
    Software Engineer,
    EpiComm Technologies.

    The Snippet of Error Stack Trace on server console is here:
    11:38:32,234 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception
    java.lang.NumberFormatException: For input string: "${endPage}"
         at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
         at java.lang.Integer.parseInt(Integer.java:468)
         at java.lang.Integer.valueOf(Integer.java:574)
         at org.apache.jasper.compiler.JspUtil.coerceToInt(JspUtil.java:752)
         at org.apache.jasper.compiler.Generator$GenerateVisitor.convertString(Generator.java:2914)
         at org.apache.jasper.compiler.Generator$GenerateVisitor.evaluateAttribute(Generator.java:2717)
         at org.apache.jasper.compiler.Generator$GenerateVisitor.generateSetters(Generator.java:2823)
         at org.apache.jasper.compiler.Generator$GenerateVisitor.generateCustomStart(Generator.java:2156)
         at org.apache.jasper.compiler.Generator$GenerateVisitor.visit(Generator.java:1665)
         at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1441)
         at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
         at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2213)
         at org.apache.jasper.compiler.Generator$GenerateVisitor.visit(Generator.java:1685)
         at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1441)
         at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
         at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2213)
         at org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2219)
         at org.apache.jasper.compiler.Node$Root.accept(Node.java:456)
         at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2163)
         at org.apache.jasper.compiler.Generator.generate(Generator.java:3270)
         at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:189)
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
         at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
         at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
         at org.jboss.portal.portlet.impl.PortletRequestDispatcherImpl.execute(PortletRequestDispatcherImpl.java:64)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

  • Problems with JSP-ApplicationModule pooling in runtime

    Hello!
    I have an urgent Problem with the ApplicationModule Pooling in Runtime. The Application uses JSP with BC4J and is deployed on Tomcat 3.1 and MS IIS 4.0 (The Client want to use this MS-Product). We use JDev 3.1.1.2 for development.
    Now my Problem:
    A user start the IE4 and log on to the application and it works fine. They log off and log in again a second time and then the user gets a NullPointerException at the point when the Application wants to checkout a new instance from the ApplicationModule Pool. The next time he logs on it works fine again and the next time not and so on. Every second time the user logs on he gets a NullPointerException.
    But there are three AdminUsers and with these users are no Problems.
    Can anyone help me or has someone the same problems?
    Greetings
    Thorsten

    There are a number of pooling problems fixed in JDeveloper 3.2. You can also step into the pooling code by using remote debugging to figure out why you are encountering this problem.

  • Problem with Port Forwarding (when PPTP is up) in WRT-160N

    Hi, everybody!
    I'm looking for some help with Port Forwarding in my new router from Linksys. I've bought the router afew daysago, and was badly surprised when I found out that there is DD-WRT firmware is installed in it (the router was 100% NEW when I've purchased it). I have downloaded the latest original Linksys firmware file and successfully flashed it.
    But I still have problem (same I had on DD-WRT firmware too) with port forwarding for my DC++ and Vuze (app for torrents): I've written port forward for ports 49151 (for Vuze) and 4000 (for DC++) to be forwarded to my desktop computer (IP 192.168.1.201) -- I've seen a post at this forum, that there could be a problem, if you forward to an IP, which is inside DHCP local zone, so I've forwarded it to .201 IP (my local DHCPzone is 192.168.1.100 - .149). But forwardind doesn't work ((
    What's wrong?
    My configuration:
    Router IP: 192.168.1.1
    PPTP (I've got it from my ISP)
    IP address: 192.168.226.127
    Default Gateway: 192.168.226.2
    DNS 1: 192.168.1.1
    DNS 2 & 3: 0.0.0.0
    PPTP Server IP Address: 192.168.226.2
    Username: ****
    Password: ****
    Single Port Forwarding:
    Application name     External port     Internal port     Protocol     To IP address     Enabled
    Vuze                       49151               49151             Both           192.168.1.201    Checked
    DC                          4000                 4000              Both           192.168.1.201    Checked
    Solved!
    Go to Solution.

    As you have mentioned in your post that your ISP has provided you a PPTP connection with an IP address: 192.x.x.x. The IP address which is provided to you by your ISP is in a Private Range, and if you try to forward any ports on your router it will not work, as your ISP modem will block that port. So you need to get a Public IP address from your ISP.
    As you are getting Private IP from your ISP, so this connection is called as NAT behind NAT, and your Modem is acting like a Router. 
    So now you have 2 options, get the Public IP address from your ISP or change the connection type. 

Maybe you are looking for