Author |
Message |
SharkHat
New Member


Joined: Mar 20, 2006
Posts: 4
|
Posted:
Wed Mar 22, 2006 10:09 pm |
|
I'd like to let the users of one of my sites be able to login using the block on the home page, and then return directly to the home page instead of the Your_Account module.
I'd still like the Your_Account module to be activated so they can go there if they need to.
Is this possible, and how would I go about doing it?
Thank you in advance  |
|
|
|
 |
Raven
Site Admin/Owner

Joined: Aug 27, 2002
Posts: 17088
|
Posted:
Thu Mar 23, 2006 3:00 am |
|
 |
Last edited by Raven on Thu Mar 23, 2006 2:32 pm; edited 3 times in total |
|
|
 |
SharkHat

|
Posted:
Thu Mar 23, 2006 4:43 am |
|
Thanks Raven.
I just tried that, but I don't think I got it right. I'm using the default User_List block included in the core Raven76 distro, and have disabled the Login block. Here are the lines that I found and experimented with:
Edited by Raven as the code I advised was during a
The second of those two was in part of an IF/ELSE block that I didn't want to paste over here. I replaced the "account.html\" with "index.php\" but I still couldn't get it to work. I apologize for my newbness  |
|
|
|
 |
Raven

|
Posted:
Thu Mar 23, 2006 9:13 am |
|
User_List? I think you mean User_Info. It would help, in the future, if you state what block/module you are working with
And yet another  |
Last edited by Raven on Thu Mar 23, 2006 2:33 pm; edited 1 time in total |
|
|
 |
SharkHat

|
Posted:
Thu Mar 23, 2006 1:04 pm |
|
I did mean User_Info, sorry it was getting late.
I still can't get it to work, when I made that change it stayed at the homepage but didn't appear to actually log me in. Hitting submit just cleared the fields and kept me as anonymous.
Thanks for your help, I think I'm just gonna leave it at default for now. |
|
|
|
 |
Raven

|
Posted:
Thu Mar 23, 2006 2:30 pm |
|
DUH! That's my fault. That's what I get for hurrying to answer something
It has to be done from Your_Account/index.php, not the block code. I'll try to remember to take a look later and post back if no one else does. ITMT, I am removing or editing my other responses as they are wrong. |
|
|
|
 |
spcdata
Regular


Joined: Jan 24, 2004
Posts: 81
Location: Sweden
|
Posted:
Thu Mar 23, 2006 2:50 pm |
|
I got it here
open modules/Your_Account/index.php
find in "function login"
Code:if (empty($redirect)) {
Header("Location: modules.php?name=Your_Account&op=userinfo&bypass=1&username=$username");
|
Change to:
Code:if (empty($redirect)) {
Header("Location: index.php");
|
|
_________________ /spcdata |
|
|
 |
SharkHat

|
Posted:
Thu Mar 23, 2006 3:14 pm |
|
That worked! Exactly what I was looking for.
Thank you both. |
Last edited by SharkHat on Thu Mar 23, 2006 5:40 pm; edited 1 time in total |
|
|
 |
spcdata

|
Posted:
Thu Mar 23, 2006 4:38 pm |
|
we are happy to help you SharkHat!
And Raven what is couple of blond moments...? i have been blond all my life  |
|
|
|
 |
|