I think I handle sessions in the default way (not with cookies.. maybe
in the future if I need to save something in the client-side..).
This is what I'm doing:
The user select a category (direct action, no session), the user
want to see a product (direct action, no session), the user add a
product to a cart (direct action but I create the session).
Now.. the user wants to log in... (direct action, have a session BUT
during the direct action "doLogin" it seems it doesn't have a session
and another is created)..
Direct actions are handled by the class DirectAction, but all the
direct actions related to login are handled by a Login class.
This is the login form:
<webobject name = "loginForm">
<table>
<tr><td>Username:</td><td><webobject name =
"userField"/></td></tr>
<tr><td>Password:</td><td><webobject name = "passwordField"/></td></
tr>
<tr><td></td><td><webobject name =
"loginButton"/></td></tr>
</table>
</webobject>
loginForm: WOForm {
name = "loginForm";
actionClass = "Login";
directActionName = "doLogin";
?redirect = redirectTo;
}
userField: WOTextField {
name = "username";
value = username;
}
passwordField: WOPasswordField {
name = "password";
value = password;
}
loginButton: WOSubmitButton {
actionClass = "Login";
directActionName = "doLogin";
?redirect = redirectTo;
}
Now.. I noticed that the url show the action name and not the page
name, after the login...
http://192.168.1.87:5100/cgi-bin/WebObjects/PNStore.woa/wa/Login/doLogin
but I'm in the showAccount page...
Francesco
On 10/ago/09, at 20:03, Mark Gowdy wrote:
2) Let's say an anonymous user has a session... then he logs in.
And... I don't want the session change!!
This is the code (it's a direct action, called from a submit button
in a form)
In the case where the user has a session, can you show us:
1) The component html (in eclipse) for this login form.
2) And can you show us the rendered html source from the browser and
the URL that got you to that login page.
Are sessions being handled in the default way, or are you using
cookies (or another way)?
Regards,
Mark
_______________________________________________
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]