6.1 SP5: response.sendRedirect crashes
Hi all,
I am porting a JSP app from Iplanet 4.1 to SunONE 6.1 SP5 (Solaris 5.9).
When I try to do the above statement in a JSP, I get the following in the error log:
[14/Jun/2007:16:05:05] failure ( 3812): for host 172.16.10.184 trying to POST /jspcontent/ozbet.jsp;jsessionid=43DBC3EA6343C4B0E3BF6AD26B943D25, service-j2ee reports: StandardWrapperValve[jsp]: WEB2792: Servlet.service() for servlet jsp threw exception
java.lang.IllegalStateException
at org.apache.catalina.connector.HttpResponseFacade.sendRedirect(HttpResponseFacade.java:179)
at jsps.jspcontent._ozbet_jsp._jspService(_ozbet_jsp.java:109)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:908)
at com.iplanet.ias.web.jsp.JspServlet$JspServletWrapper.service(JspServlet.java:687)
at com.iplanet.ias.web.jsp.JspServlet.serviceJspFile(JspServlet.java:459)
at com.iplanet.ias.web.jsp.JspServlet.service(JspServlet.java:375)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:908)
at org.apache.catalina.core.StandardWrapperValve.invokeServletService(StandardWrapperValve.java:771)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:322)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:509)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:212)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:509)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:209)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:509)
at com.iplanet.ias.web.connector.nsapi.NSAPIProcessor.process(NSAPIProcessor.java:161)
at com.iplanet.ias.web.WebContainer.service(WebContainer.java:580)
I am not sure what I need to declare differently in 6.1. The web app jars are in WEB-INF/lib under the docroot.
The code in the JSP is pretty standard, but ran under Iplanet 4.1.
try {
String URL = "https://www.ozbet.com.au/tab/ozbet.htm?p_date=" //has parameters;
response.sendRedirect(URL);
catch (ApplicationException e) {
//do some stuff here
%>
<b>ERROR:</b> <%= msg %>"
<%
FYI the webapp is working fine wrt to jdbc, jsp etc. It is just the sendRedirect() that is crashing.
Do I need to declare anything related to NSAPI in obj.conf ?
Please help and thanks in advance.
Richard
Message was edited by:
r_defonseka
Message was edited by:
r_defonseka
That's not a crash. HttpServletResponse.sendRedirect is throwing an IllegalStateException because you called it after the response had been committed. This is a documented part of the Servlet spec. (See, for example, http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/servlet/http/HttpServletResponse.html#sendRedirect(java.lang.String) for the the J2EE 1.3 docs.)
The most likely problem is that you're calling sendRedirect after an include or after outputting too much data. If you're going to call sendRedirect, you need to do so near the top of your JSP file, before you output a lot of data. Once data has been sent to the client, there's no way for the server to say "oops, never mind, ignore that data and redirect over here instead".
Similar Messages
-
Response sendRedirect is not working in JSF
Hi,
I am getting an error on calling response.sendRedirect() method in my backing bean. This piece of code is for redirecting:
if (userCredentials.isExpired() || userCredentials.isInThreshold() ) { // Just checking for some boundary conditions
ViewHandler vh = ctx.getApplication().getViewHandler();
String viewUrl = vh.getActionURL(ctx, PATH_FOR_CHANGE_USER_PAGE);
ExternalContext ectx = ctx.getExternalContext();
HttpServletResponse response =
(HttpServletResponse)ectx.getResponse();
response.sendRedirect(viewUrl); /// This is where the error is thrown.
}Here is the stack trace:
SEVERE: Error Rendering View[/xhtml/home/AppHomePage.xhtml]
javax.faces.el.EvaluationException: /layout/header.xhtml @27,78 value="#{UserInformation.userName}": Error getting property 'userName' from bean of type com.mrc.web.infrastructure.login.UserInfo: java.lang.IllegalStateException: Response has already been committed, be sure not to write to the OutputStream or to trigger a commit due to any other action before calling this method.
at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.java:60)
at javax.faces.component.UIOutput.getValue(UIOutput.java:167)
at com.sun.faces.renderkit.html_basic.HtmlBasicInputRenderer.getValue(HtmlBasicInputRenderer.java:102)
at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.getCurrentValue(HtmlBasicRenderer.java:221)
at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeEnd(HtmlBasicRenderer.java:199)
at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:740)
at org.apache.myfaces.trinidad.render.CoreRenderer.encodeChild(CoreRenderer.java:304)
at org.apache.myfaces.trinidad.render.CoreRenderer.encodeAllChildren(CoreRenderer.java:321)
at org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.PanelPartialRootRenderer.renderContent(PanelPartialRootRenderer.java:64)
at org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.BodyRenderer.renderContent(BodyRenderer.java:142)
at org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.PanelPartialRootRenderer.encodeAll(PanelPartialRootRenderer.java:119)
at org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.BodyRenderer.encodeAll(BodyRenderer.java:78)
at org.apache.myfaces.trinidad.render.CoreRenderer.encodeEnd(CoreRenderer.java:224)
at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:693)
at com.sun.facelets.tag.jsf.ComponentSupport.encodeRecursive(ComponentSupport.java:252)
at com.sun.facelets.tag.jsf.ComponentSupport.encodeRecursive(ComponentSupport.java:249)
at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:594)
at org.apache.myfaces.trinidadinternal.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:182)
at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:107)
at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:245)
at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:137)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:214)
at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._invokeDoFilter(TrinidadFilterImpl.java:262)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:219)
at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:173)
at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:644)
at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:391)
at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:908)
at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:458)
at com.evermind.server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:226)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:127)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:116)
at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
at oracle.oc4j.network.ServerSocketAcceptHandler.procClientSocket(ServerSocketAcceptHandler.java:234)
at oracle.oc4j.network.ServerSocketAcceptHandler.access$700(ServerSocketAcceptHandler.java:29)
at oracle.oc4j.network.ServerSocketAcceptHandler$AcceptHandlerHorse.run(ServerSocketAcceptHandler.java:879)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
at java.lang.Thread.run(Thread.java:595)
*Caused by: java.lang.IllegalStateException: Response has already been committed, be sure not to write to the OutputStream or to trigger a commit due to any other action before calling this method.*
at com.evermind.server.http.EvermindHttpServletResponse.sendRedirect(EvermindHttpServletResponse.java:1545)
at javax.servlet.http.HttpServletResponseWrapper.sendRedirect(HttpServletResponseWrapper.java:170)
at com.sun.faces.context.ExternalContextImpl.redirect(ExternalContextImpl.java:357)
at org.apache.myfaces.trinidad.context.ExternalContextDecorator.redirect(ExternalContextDecorator.java:253)
at com.mrc.web.infrastructure.login.UserInfo.getPasswordThreshold(UserInfo.java:547)
at com.mrc.web.infrastructure.login.UserInfo.getUserName(UserInfo.java:231)
at sun.reflect.GeneratedMethodAccessor196.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at com.sun.faces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:99)
at com.sun.facelets.el.LegacyELContext$LegacyELResolver.getValue(LegacyELContext.java:141)
at com.sun.el.parser.AstValue.getValue(AstValue.java:96)
at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:183)
at com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.java:71)
at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.java:56)
... 39 moreI dont think i am calling the 'sendRedirect' method anywhere before this code(if i understood the error message).
Please help me with some pointers.
Thanks,
Srikanth
Edited by: sriki79 on Jul 26, 2010 5:06 PM
Edited by: sriki79 on Jul 26, 2010 5:06 PM
Edited by: sriki79 on Jul 26, 2010 5:07 PMYep, content has already been flushed to the browser and then the redirect cannot work anymore. Move the redirect logic to a filter I'd say.
-
Problem in response.sendredirect()
Hi
I am using response.sendredirect() to forword a request to an absolute URL out side my current environment.
but it's not working....it still tries to process the request in the same environment...
what can be the problem???yes i am passing the absolue URL to the Method.
"http://blrkec30386:9080/ececWeb/BANKAWAY?Action.Admin.Init=Y&AppSignonBankId=024"
. -
Response.sendRedirect doesn't work
Hi,
I implemented the post authentication class. I added some code to the onLoginFailed method and i am trying to redirect user for my own page and not the standard error page of opensso (IdP). When using response.sendRedirect("/my_page") i got an error message telling me that redirection has failed because record already committed.
I think the problem is due to the original redirection done by the IdP, isn't it? Is there a solution to redirect user for my own login failure page?
Thanks.How about this.
Do a combination of the two.
Use the post auth plugin to do your work with LDAP it has access and has all the needed information.
Add the attributes to the ?session?header? in the post auth plugin maybe?
Use the default failrue url you are sending them to to pull the info out of the session headers and do whatever is needed at that point?
I would try just populating one attribute first and redirecting using the default failure url to some simple page that prints out to validate if it would work.
J -
Response.sendRedirect() doesn't work immediately
Hello,
I'm moving my application to JDK 1.4 and IAS 10g.
It's alright, but I noticed one problem.
For long operation I created my way to display a "Working..." page.
I use response.sendRedirect() to an HTML page, with the "Working..." message, that reload itself every five seconds (due to the fact that the message will be replaced, as I explained later).
Once the operation has terminated it change a session variable that is loaded by the HTML page and it replace the "Working..." message with a "Done!" message.
The problem is that in IAS 10g it doesn't redirect to the HTML file immediately, it seems that "wait" the operation is almost finished: il redirect to the HTML file displaying "Working...", and after the first reload of the page (5 seconds) it display "Done!".
This is the part of the code:
String urlToLoad = "/myApp/tools/template/cache/tempxyz.html";
// SESSION VALUE: "Working..."
response.sendRedirect(urlToLoad);
response.flushBuffer();
// OPERATIONS
// CHANGE SESSION VALUE WITH "Done!"
// END OF METHODThe "response.sendRedirect(urlToLoad);" instruction is executed without any error.
I also tried to use the absolute path with "http://name_server", but it still doesn't work.
I hope I explained my situation.
I already read many post in this and others forums, but I didn't found any working solution.
Thanks in advance for any suggestions,
EPYou could try putting your operations into a new thread... but I don't see why that would be necessary...
String urlToLoad = "/myApp/tools/template/cache/tempxyz.html";
// SESSION VALUE: "Working..."
response.sendRedirect(urlToLoad);
response.flushBuffer();
Thread t = new Thread( new Runnable() {
public void run() {
// OPERATIONS
// CHANGE SESSION VALUE WITH "Done!"
t.start();
// END OF METHOD(Or put the operations in a method in another class that implements the Runnable interface, ... whatever) -
Response.sendRedirect doesn't work with IAS 10g
Hello,
I'm moving my application to JDK 1.4 and IAS 10g.
It's alright, but I noticed one problem.
For long operation I created my way to display my "Working in progress..." page.
I create an HTML file into a cache folder and I redirect to that file that reload itself every five seconds.
Once the operation is terminated it change a session variable that is loaded by the HTML page and it ends the "Working in progress..." message.
The problem is that in IAS 10g it doesn't redirect to the HTML file immediately, it seems that "wait" the operation is almost finished: il redirect to the HTML file, and after 5 seconds it loads the end message of the operation.
This is the part of the code:
[WRITE FILE IN c:\application\tools\template\cache as tempxyz.html]
String urlToLoad = "/myApp/tools/template/cache/tempxyz.html";
response.sendRedirect(urlToLoad);
[OPERATIONS]
[CHANGE SESSION VALUE]
-END-
The "response.sendRedirect(urlToLoad);" instruction pass without errors.
I hope I explained my situation.
Thanks in advance for any suggestions,
EPThanks Qiang,
Ive done exactly as youve said and it must be a rewriting problem as you suggested. Here is the header from accessing the servlet on the Linux host machine (IP 192.168.5.121 called 'BEAST')
--10:12:27-- http://192.168.5.121:7780/webapp/test
=> `test'
Connecting to 192.168.5.121:7780... connected.
HTTP request sent, awaiting response...
1 HTTP/1.1 302 Moved Temporarily
2 Date: Wed, 11 May 2005 09:12:27 GMT
3 Server: Oracle-Application-Server-10g/10.1.2.0.0 Oracle-HTTP-Server
4 Content-Length: 183
5 Cache-Control: private
6 Location: http://BEAST:7779/webapp/testJ.jsp
7 Keep-Alive: timeout=15, max=100
8 Connection: Keep-Alive
9 Content-Type: application/octet-stream
Location: http://BEAST:7779/webapp/testJ.jsp [following]
--10:12:27-- http://beast:7779/webapp/testJ.jsp
=> `testJ.jsp.3'
Resolving beast... done.
Connecting to beast[127.0.0.1]:7779... connected.
That worked fine. Here is the header on my windows machine on the network ( IP 192.168.5.120) :
HTTP/1.1 302 Moved Temporarily
Date: Wed, 11 May 2005 09:03:21 GMT
Server: Oracle-Application-Server-10g/10.1.2.0.0 Oracle-HTTP-Server
Content-Length: 183
Cache-Control: private
Location: http://BEAST:7779/webapp/testJ.jsp
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: application/octet-stream
I think the problem must be that the response is telling it to redirect to BEAST (which is the name of the server) but the windows box cant resolve the name. Must be why i get the page cannot be displayed.
The code in the servlet 'test' to redirect is just:
response.sendRedirect("testJ.jsp");
Any ideas would be much appreciated on how I can fix this other than setting up a local DNS server?!
Cheers,
Rob. -
Response.sendRedirect is not working for IE5.5
Hi All,
I am using response.sendRedirect method to go to different page from jsp file. It was working file before IE was upgraded to version 5.5. It is still working fine with Netscape.
With IE, it remains on the same page even after executing response.sendRedirect method. IT ACTUALLY GOES TO ANOTHER PAGE AFTER SELECTING REFRESH. Could this be a CACHE problem. However, I tried to append the URL with some random number every time it executes response.sendRedirect method just to make it a different URL and still getting the same result.
Any Help will be greatly appreciated.
Thanks.Every time I clear the History Cache, It works for the first time and after that it remains on the same page.
I tried to set the days to store the hist pages as 0.
please let me know if any other browser settings OR program changes required.
Thanks. -
Response.sendRedirect() problem
Hi all,
I in facing a problem during using response.sendRedirect() or there is some mistake, please help me...
I have written two jsp files:
i.e. first.jsp and second.jsp
FIRST.JSP is as follwing:
<%@ page import="java.io.*" %>
<%
response.sendRedirect("http://192.168.0.4:9999/mylogo/second.jsp");
%>
and SECOND.JSP is as follows:
<%@ page import="java.io.*" %>
<%
String coding=request.getParameter("name").trim();
%>
My name is <h1><%= coding %></h1>
but when i write the follwing in address bar:
http://localhost:9999/mylogo/first.jsp?name=jake
an error occurs:
NullPointerException messae is received. I am using Apache Tomcat/4.1.29.
Please help me, and tell if ther is any thing missing in this code....
Thankx in advance...When you use redirection, you are sending a header back to the browser which tells it to go somewhere else. This results in an entirely new request. Because of this, any request info from the first page will not be in the second. The advantage of redirects is you can tell the browser to go to any other server.
If you want to maintain the same request info, you can use forward. Forward only passes control in the server to another page. The browser will have no idea that this is happening, and it cannot go to another server. -
Response.sendRedirect(URL), problem if '&' is usd as part of paramete value
i have to redirect to a page having following URL
http://www.citease.com/afc/d&o_coverage.htm
now & is part of value rather than a separater of parameters.
whenever i redirect it as
strURL = "http://localhost:8080/cms/redirector.jsp?ckUrl=http://www.citease.com/afc/d&o_coverage.htm";
response.sendRedirect(strURL);
it will not work properly, will try to access only
http://www.citease.com/afc/d
Please help.
Best regards,
Waseem AslamEncode the URL, the & should be & amp;.
You may find the URLEncoder useful. -
Is it a bug in WLS6.0 of response.sendRedirect()?
I got a very strange problem that I found that the code like that:
response.sendRedirect("../error/error.jsp?url=../hello.jsp&err=hello");
runs well, but the code like that:
response.sendRedirect("../error/error.jsp?url=../../hello.jsp&err=hello");
doesn't work, WLS tells me page not found! Its mean WLS can't go back more than one lever directory!! It's not fun!! Can somebody help me?
Where can I download my test ear file.
Any way I am keep my source here.
My Servet Source
=============================================
package com.ritesh.tempwork;
import javax.servlet.*;
import javax.servlet.http.*;
import java.io.*;
import java.util.*;
public class MyServlet extends HttpServlet {
* Initialize global variables
public void init(ServletConfig config) throws ServletException {
super.init(config);
* Service the request
public void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
//getAction
request.setAttribute("result",new ActionResult());
this.getServletContext().getRequestDispatcher("/test.jsp").forward(request, response);
* Get Servlet information
* @return java.lang.String
public String getServletInfo() {
return "com.aclcargo.servlet.ActionMultiplexer Information";
* Insert the method's description here.
* Creation date: (7/13/2001 5:30:57 PM)
public void destroy()
====================================================
My Action Result class
=====================================================
package com.ritesh.tempwork;
i[i]Long postings are being truncated to ~1 kB at this time. -
In Servlet, response.sendredirect using iPlanet
I'm from INIDIA. I have some problem in using response.sendRedirect. I'm using iPlanet application server. I tested on Java Web Server and it's working fine there but please advice me, how it'll work on iPlanet.
ThanksShould work the same way. If you have an actual problem when you try it, let us know.
-
hi,
I am getting this error java.lang.IllegalStateException when i am trying to send response to a jsp page
here is my code
try{
Class.forName("com.mysql.jdbc.Driver");
Connection con = DriverManager.getConnection("jdbc:mysql://localhost:3306/test","root","root");
PreparedStatement statement = con.prepareStatement(sql);
int i = 0;
i = i+1;
statement.setString(1,designation);
i = i+1;
statement.setString(2,Address);
i = i+1;
statement.setString(3,name);
statement.executeUpdate();
statement.close();
con.close();
catch(Exception e){
e.printStackTrace();
response.sendRedirect("employee.jsp");Shoebhere is the error
java.lang.IllegalStateException
org.apache.catalina.connector.ResponseFacade.sendRedirect(ResponseFacade.java:433)
employee.doPost(employee.java:55)
javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
try{
Class.forName("com.mysql.jdbc.Driver");
Connection con = DriverManager.getConnection("jdbc:mysql://localhost:3306/test","root","root");
PreparedStatement statement = con.prepareStatement(sql);
int i = 0;
i = i+1;
statement.setString(1,designation);
i = i+1;
statement.setString(2,Address);
i = i+1;
statement.setString(3,name);
statement.executeUpdate();
statement.close();
con.close();
response.sendRedirect("employee.jsp");
catch(Exception e){
e.printStackTrace();
} -
About parameter length in response.sendRedirect()
I want to pass a long String in response.sendRedirect(), but it failed.
Is the length limited?
Can i change it? If not, how i pass the String?
Thanks!
coral9527The sendRedirect command always sends a GET request. GET requests do have a limited length to their parameters.
How you pass the String is dependent on where you are redirecting to...
If you are redirecting to a source in the same web app, then the first thing you should try is to not pass the string at all. Perhaps pass some key words, send the redirect and let the other side generate the full String. Or you could put the long String in the user's session, send a redirect with the attribute name as a parameter, then retrieve it from the session on the other side.
If you are redirecting to a source outside of your control, you may need to do an HTTPURLConnection using the POST method and copy the results to the user's browser... -
Issues in response.sendRedirect
I access a jsp using the url http://hostname/App/index.jsp. Running OracleAS in posrt 80.
When I redirect to different page using the code response.sendRedirect("/App/english/index.jsp");
The page redirected to http://hostname:7778/App/english/index.jsp.
I don't know from where the port 7778 is taken. Please provide steps to correct this issue.
Some more info: I have two OracleAS server it works fine in one server and it doesn't work on the other server.Greetings,
Try running netstat -ab from command line to see what service is listening on port 7778. If your page is already at App virtual dir when you redirect, why not have redirect simply go to the english virtual dir?
response.sendRedirect("/english/index.jsp");-Michael -
How to handle response.sendRedirect(url) in a portlet w/ webflow?
I am using a webflow to navigate within a portlet. There are three jsp pages or
nodes in the portlet. One of the jsp pages has the following logic:
if (A) { response.sendRedirect(url1)}
else if(B) { response.sendRedirect(url2)}
else{display rest of this jsp page}
I think I have the correct portlet urls. I used WebflowJSPHelper.createWebflowURL(...).
The problem is when it tries to redirect, the whole portlet disapears leaving
only the title bar. I check the weblogic log file and there is an exception about
RuleSetNotFoundException. Does anybody know how to handle this problem? Can
I use sendRedirect method in a portlet?
thanks,Go to dev2dev.bea.com source code library and copy the redirect sample code in
your application domain. This program expects you to make come changes in the
portal workflow.
ciao
"Edoardo Boechat" <[email protected]> wrote:
>
Dear James,
Maybe I'll be boring, but I'll give you my expirience with "sendRedirect".
When you use sendRedirect you send back to the browser a new URL that
him will
use to obtain the content that will be exposed, in other words, It's
a client
side operation.
The portlet machanism work on the server side of the application. So
why you are
using sendRedirect? If one of that conditions happen, are you interesting
in expose
a content of another web site?
If you want to expose the content of another web site, use the wizard
to generate
a example jsp page who do this correct in a portlet and adapt the code
to your
situation.
Otherwise, you are using a wrong concept. If it's a server side operation
you
need to use "forward" or "include" operation to do what you want.
I expect be helpfull,
Edoardo Boechat.
"James" <[email protected]> wrote:
I am using a webflow to navigate within a portlet. There are threejsp
pages or
nodes in the portlet. One of the jsp pages has the following logic:
if (A) { response.sendRedirect(url1)}
else if(B) { response.sendRedirect(url2)}
else{display rest of this jsp page}
I think I have the correct portlet urls. I used WebflowJSPHelper.createWebflowURL(...).
The problem is when it tries to redirect, the whole portlet disapears
leaving
only the title bar. I check the weblogic log file and there is an exception
about
RuleSetNotFoundException. Does anybody know how to handle this problem?
Can
I use sendRedirect method in a portlet?
thanks,
Maybe you are looking for
-
HP Officejet Pro K5400 will not turn on.
The HP OP K5400 printer was operating for about 3 months. Recently the printer will not turn on. The power cord assembly was checked via meter and green power light while unplugged from printer. The power cord assembly is good. When the power cord is
-
Will DVD studio Pro convert Real Media
I have some real media clips and I want to convert them and burn them to DVD. Will DVD studio Pro convert them. IF they will how long will it take for 50 mins of video. Thanks
-
Hi Gurus, I'm not able to post vendor payment. Error: The entry 9100 is missing in table T043G Although I've maintained vendor tolerance limit/range. Please help. Regards, Vikas Malhotra
-
Hi! I can't log in in the Content Viewer. Well, I can, but nothing happens when I do. There's no updates or anything. Anyone's having this issue or know how to address it? Thank you?
-
No sound during a call on iPhone 4S! Help!!!!
Hi, my iPhone 4s' sound isn't working during a call. I can't hear the person on the other end, nor can I hear them. I can't hear it ringing either, although when I have an incoming call I can hear that ringing then, but nothing else. It started off a