Hi Kent,
Thanks for your reply. I am using Session in my application. My Normal HTML
file is in D:/Logout.html and the java code is in DirectAction.java as shown
below:
public WOComponent logout() {
session().terminate();
WORedirect rePage = (WORedirect)pageWithName("WORedirect");
rePage.setUrl("file:///D:/Logout.html");
return rePage;
}
It is not working. I tried with "D:/Logout.html", but it is also not
working. I put Logout.html file under WebserverResources and it is called
rePage.setUrl("Logout.html"). This one also not working. Please correct me
for this example.
Thanks & Regards,
Sreenivasulu Arveti.
On Thu, Feb 4, 2010 at 6:58 PM, Kent Conlan <[email protected]>wrote:
> Hi Sreenivasulu,
>
> If you don't use Sessions you can just go to the page.
> If you do use Sessions (the default) then terminate the Session and return
> a WORedirect, or build your own using HTML 302 or META HTTP-EQUIV="refresh".
>
> Checkout WORedirect:
>
> http://developer.apple.com/legacy/mac/library/documentation/WebObjects/Reference/WO53_Reference/com/webobjects/appserver/WORedirect.html
>
>
> // DirectAction.java
> public WOActionResults logoutAction(){
> if (existingSession() != null) {
> existingSession().terminate();
> }
> WORedirect aRedirect = new WORedirect(context());
> aRedirect.setURL("http://www.google.com");
> return aRedirect;
> }
>
> - Kent
> PS. This was entered by hand so there may be a typo.
>
>
> On Feb 4, 2010, at 5:27 AM, Sreenivasulu A wrote:
>
> Hi All,
>>
>> Using WOHyperlink how to redirect to a normal HTML Page in WebObjects?
>> Will
>> it work for redirecting to Normal HTML Page? If it is possible, please
>> give
>> me one example to redirect to a normal HTML page.
>> I want to redirect to normal html page when I click on Logout button, and
>> from this normal html page I will redirect to "www.google.com".
>>
>> Thanks in Advance,
>> Sreenivasulu Arveti.
>>
>
>
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]