I've experimented for several options with different paths in the "Redirect path on Confirmation" box, and this doesn't seem to work. I also notice that when the initial registration email is sent out the redirection url still points to the user edit page.

Comments

hunmonk’s picture

Status: Active » Postponed (maintainer needs more info)

do you have the immediate login feature enabled?

rcross’s picture

No - but I don't want there to be an immediate login option.

What i'm hoping/expecting is that once someone registers, they will get an email with their password, then when they login for the first time I want to direct them to a particular page (upon their confirmation of their email address). This page only needs to be shown upon the first login, and not on every login.

Any other details you need?

hunmonk’s picture

do you have the Public registrations settings as 'Visitors can create accounts and no administrator approval is required', and are you using !login_url as the token in your welcom message?

i'm still not convinced this is a bug.

rcross’s picture

Yes - "visitors can create accounts and no administrator approval is required" is used

I have also marked the "Require e-mail verification when a visitor creates an account"

I have both !login_uri, !login_url and !edit_uri tokens present in the welcome email.

As stated, what I would expect would be fairly straightforward - all operations would occur as normal given these settings except that instead of being directed to http://example.com/user/#/edit on the first login, it would be directed to http://example.com/path/to/page

It would also be acceptable if the user was directed to the user page first and after changing the password, they were directed to the alternate page, but this scenario does also not seem to exist.

My suspicion is that the confirmation redirection only works when the immediate login option is used, which seems an unnecessary requirement

hunmonk’s picture

please show me an example of a !login_url from an actual user email.

i'd also like to see exactly what you're using for the confirmation setting.

socialnicheguru’s picture

Title: Redirect on Confirmation Doesn't work » Redirect on Confirmation Doesn't work- option 2
Priority: Normal » Critical

Redirect does not work for me either although my user experience is slightly different

Scenario 1: Email verification

I also want to note that I did this with no immediate login in logintoboggin and set email verification in user settings to yes. I waited a second for my email and clicked on it. I was redirected to the user/uid/edit page to change my password. I was not re-directed to the page I specified in logintoboggin then (granted I did not change the email but I was not quite sure how to make it goto the page I wanted new users to get redirected to) and login toboggin did not send me to the right redirection page when I logged in again.

Scenario 2: Immediate login

Expected behavior:
***************
someone comes to the site and logs in. Registration page has username, two emails, and captcha.
They go through that and are automatically given a role of "basic user". this will allow them to setup profiles only
Upon entering the site they are re-directed to the page I specify at logintoggin called profile/wizard.

When they goto their email and click on the link (even if they are currently logged in), the email is confirmed, and they move from "basic user" to "authenticated user" role.

What is happening:
*************
a person can login. they enter the site. They are not redirected to profile/wizard. They are sent to user/uid/edit. The roles don't seem right because I cannot access or save information that basic users should be able to. When i click on the link in the email and I am already logged in, it tells me that I don't need to use it. I thought that it would upgrade me from basic to authenticated user since it now has confirmation of my email

I am having the same problem.

I have logintobggin, account types, user settings, advanced front page installed. I had login destination installed but de-installed it because I thought that it was redundant.

LoginTobbogin
***********
Allow users to login using their e-mail address: enabled
Users will be able to enter EITHER their username OR their e-mail address to log in.

Use two e-mail fields on registration form: enabled

User will have to type the same e-mail address into both fields. This helps to confirm that they've typed the correct address.

Set password & Immediate login: enabled

role: basic role

it says that "If "Set password & Immediate login" is selected, users will be able to login before their e-mail address has been authenticated. Therefore, you must choose a role for new non-authenticated users. Users will be removed from this role and assigned to the "authenticated user" role once they follow the link in their welcome e-mail. Add new roles."

But this is not happening.

When a new user logs in, the permission given is

Account Types:
************
Free account has basic role as the initial setting and authenticated user as a possiblity. Free Account is the default in the system.

User settings:
**********
Public registrations:
Visitors can create accounts and no administrator approval is required.

Require e-mail verification when a visitor creates an account- this is NOT checked.

I thought that if I wanted immediate signin per login toboggin then I would not have this checked.

Email sent is the one time entry standard email.

Is there an issue between login toboggin and the modules above or advanced front page module which re-directs users to

Chris

hunmonk’s picture

@activelyOUT: the first thing to try is disabling all contrib modules except logintoboggan, and see if the LT functionality still has problems. i've not seen any issues like this with LT and a stock drupal install.

socialnicheguru’s picture

hummonk,

you wrote this a while ago, http://drupal.org/node/121972#comment-516674.
#2
hunmonk - July 11, 2007 - 18:07
Status: active » won't fix

this is not a feature of the module. the redirect works only when the validation link itself is used, not when the user randomly logs in after account approval.

Is this still valid? Can i check in with you around my thinking to make sure that I conceptually have it right.

1. set immediate login and "basic user" is the role assigned
2. set redirect on login of new users is profile/wizard
3. set redirect on confirmation of new users to profile/wizard
4. user comes to site, registers, and is taken to the redirect page specified on logintoboggin (step 2)
5. click link in confirmation email and they are validated. system will automatically assign them a role of "authenticated" (step 3)

is the above correct? Do Step 4 and 5 only happen once? So if someone is

For redirection for immediate login, does what come below only occur once, not each subsequent time that a user logs in?

"Normally, after a user registers a new account, they will be taken to the front page, or to their user page if you specify Immediate login above. Leave this setting blank if you wish to keep the default behavior. If you wish the user to go to a page of your choosing, then enter the path for it here. For instance, you may redirect them to a static page such as node/35, or to the page. You may also use %uid as a variable, and the user's user ID will be substituted in the path."

This happens once when hey click the link in the confirmation email? Is there a special link I have to insert?

"Redirect path on Confirmation:
Normally, after a user confirms their new account, they will be taken to their user page. Leave this setting blank if you wish to keep the default behavior. If you wish the user to go to a page of your choosing, then enter the path for it here. For instance, you may redirect them to a static page such as node/35, or to the page. You may also use %uid as a variable, and the user's user ID will be substituted in the path."

And yes, I am going through the process of de-installing modules.
I have logintoboggin, advanced front page, user settings installed.

Chris

socialnicheguru’s picture

i uninstalled

Advanced Front page
Account types

when I logged in, I was taken to the appropriate page.

However, i could not access any of my taxonomy terms or cck (I think that was a permission problem).
I went through my profile/wizard setup process. I was able to enter data but none of it displayed.

the last page is a lonely node display of usernode.

I got this: "You have not created a Usernode yet. Go ahead and create one!" Hmmm... I looked in the tables and usernode was created. However in user role, there are no roles assigned.

Then I went to my email, and clicked on the confirmation link, and everything was magicially accessible. I think the user is not authenticated, however in the user_roles tabe the uid does not show up. In the admin screen for users, there is no role assigned.

A few things:

the error message for usernode is misleading and is not user friendly. It should say something like "please check your email or click here to have an email sent to your email address to re-validate your account"

Somehow the roles are not working out correctly which leads to problems. I don't understand why user_roles table is not being updated although the user appears to be doing what an authenticated user should do.

It seems that making the role anything but authenticated when Set password and immediate login is checked produces unintended behaviors ie. user_role is not updated.

Now in the user profile if I am admin, I see the following:

"The user receives the combined permissions of the authenticated user role, and all roles selected here." Authenticated user does not show up as a choice.

Any thoughts?

Chris

hunmonk’s picture

your earlier post is correct about the one-time functionality of LT regarding immediate login/confirmation. login_destination is the module you want if you want to control the login page for each login.

i really can't help you debug issues between contributed modules. you have to uninstall _all_ other contributed modules in order to determine if this is in fact a bug with LT or not. my guess is if you started with a totally clean install of drupal core, and added LT, it would work as expected.

i have no problem patching LT so that it's more compatible with other contribs, as long as the patch results in a better overall implementation, and not a hack. however, you're on your own to determine any cross module problems outside of drupal core!

socialnicheguru’s picture

I have been working on this for most of the day. :(

it seems that login toboggin and Account Types and advanced front page don't work well together :(. I can't figure out why quite yet.

I removed everything and just had loggintoboggin. The use case is as follows:

1. register - enter email, password, and user name
2. i am taken to the beginning of my profile wizard using pageroute. I can access the pageroute pages for my profile wizard but not cck taxonomy terms ( Would you know why?)
3. i cannot access anything that an authenticated user can. This is expected behavior.
4. If I am still logged in, I goto my email, and hit the link which I assume validates my account. It does.

But here is the strange behavior:
1. I can't select any cck elements on my profile pages wizard
2. The last page of the pageroute is usernnode. I get an error that the usernode is not created. This goes away when i hit the validation link.

I take it loggin toboggin restricts this. Is there a way to change the behavior so a different message is given other than "usernode is not created. Create a new one."

Also how can I have another validation link sent to me? Do I have to click on lost password? Will that do it?

Chris

hunmonk’s picture

Category: bug » support
Priority: Critical » Normal
Status: Postponed (maintainer needs more info) » Fixed

Also how can I have another validation link sent to me?

either the user themselves or a user admin can visit the user edit page and click the revalidation link.

Is there a way to change the behavior so a different message is given other than "usernode is not created. Create a new one."

this has nothing to do with LT -- it's a usernode message.

at this time it seems there's no bug here in LT at all. if you do in fact find one, then feel free to reopen the issue. your other issues need to be answered elsewhere -- perhaps in the drupal.org forums, #drupal-support, or paid support.

socialnicheguru’s picture

Status: Fixed » Active

hammock, thanks for the info.

But I think that their is something misleading with the description for "Set Password/Immediate".

It is not a usernode issue. It has to do specifically with how logintoboggin restricts permissions.

if I set logintoboggin to a "basic role" which is a subset of authenticated role (which is what is recommended) then the issue comes up. When a user is authenticated usernode is just fine.

So my question is how does logintoboggin restrict the role assigned and then how does it automatically make someone "authenticated" upon validation. Does it add "authenticated" to this person's role? Does it remove the old role and replace with a new one? How does it "restrict access" if authenticated is the base/default role in the Drupal system.

Thanks,
Chris

hunmonk’s picture

Project: LoginToboggan » Usernode
Version: 5.x-1.2 » 5.x-1.3
Category: support » bug

i suggest you explore the code if you want a detailed answer to your question. it's all right there... ;)

the short answer is that it removes the auth role programmatically from the user while the user still has the pre-auth role.

my feeling is that usernode is somehow tied to the auth role in a way that's causing problems. IMO, that's an issue with usernode, not with LT. LT doesn't do anything hackish to acheive it's effect.

moving to the appropriate queue.

socialnicheguru’s picture

Please note that when using loggintoboggin "set immediate" setting and a "pre-authorized" role is defined, usernodes WILL NOT be created until the user is validated via the validation link in the email.

There is an issue with the way either loggintoboggin restricts validation or usernode restricts creation to the authenticated role. I am not experienced enough to determine the actual cause.

It is important for people to know. I have spent lots of time trying to figure out whether this is a cck, pageroute, logintoboggin, usernode, or God's wrath upon me... luckily it is not the latter.

just thought others should know.

Chris

fago’s picture

can someone summarize what usernode should cause here? The whole issue is a bit confusing and long..

socialnicheguru’s picture

From what I have seen/experienced:

I have used pageroute to setup a profile setup process.
i used logintoboggin set to immediate and with a role called pre-authenticated.

I can step through the pageroute process
I cannot access any CCK fields
The node profiles are created. (I have to go to the admin->content to check)
but no usernode is created.

If I set the logintoboggin role to authenticated user, everything works including the creation of usernode for that user.

Is there a connection between usernode and the person needing to be authenticated for a usernode to create itself.

I hope that helps.

Chris

fago’s picture

pre-authenticated? sry, I'm not into the logintoboggin module. As soon as there is a normal drupal user, it's considered as authenticated and it should also get a user node.

socialnicheguru’s picture

ahh so a usernode is only created when a user is authenticated ie has the role authenticated. See #14 above.

that is why the feature for logintoboggin will not work if usernode is used.

Here is the flow.

I set "Set to password/Immediate" in logintoboggin
I set a role other than authenticated. Let's call it "pre-auth". I define this in roles and give it limited functionality.
Logintoboggin removes or strips away "authenticated" as a role leaving "pre-auth" role
I get an email confirming that the email sent to me is correct
I click on the link in the email
It validates my account
In addition to "pre-auth" I now also have "authenticated" as a role

If the pre-auth role is "authenticated", then it will work.
If the pre-auth role is not "authenticated", which is how it should work, then no usernode is created.

Is there a way for usernode to be created so that a user can fully answer any cck fields and get a usernode even if they have a pre-auth role other than authenticated?. Is there anyway to modify that? Or maybe I not use usernode and use a panel instead

While this is my particular implementation, usernode is useful for social networking sites. This type of immediate access is offered by most. I would love to be able to do it in Drupal too :)

Chris

socialnicheguru’s picture

Title: Redirect on Confirmation Doesn't work- option 2 » Redirect on Confirmation Doesn't work- option 2 (work around)

My work around was to have the pre-auth role be authenticated.

I created another role called "validated", which is now the role someone has once they have been validated. All content is only accessible through the validated role.

I also used Account Type and setup the basic account to have authenticated and validated roles automatically.

so when someone logs in for the first time, Account Type ensures they have both.

Logintoboggin strips away validated.

Usernodes can be created.

User has to click on the validated link in their email for logintoboggin to add validated back.

voila- done!

There is an issue with logintoboggin and th invite module. If I invite someone and add their email, they should not have to vlidate their account again. But logingtoboggin still forces them to. I will capture this in another issue.

fago’s picture

Status: Active » Fixed

great you solved it - as there is no usernode issue I close that one.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.