vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   [RELEASE-addon] Homepage Login on Non-VB Page -- Addon (https://vborg.vbsupport.ru/showthread.php?t=30642)

badmeetsevil- 10-17-2001 10:00 PM

Here's a little mini-addon to a very popular hack by RobAC. You can view the original hack here.

When Rob released this hack, it would log you in, and bring you to the Forums home. This was very fustrating to some, who put the logon on their mainpage, and it'd bring them to the Forums Home, and not back to where they logged in.

I decided to do it myself, and found it pretty simple.

What this little addon will do, is when you login, it'll bring you back to the page you were previously on when you logged on. So, lets say you had Rob's login code on your mainpage, and you logged in, it'd bring you back to your mainpage saying "Welcome Back, Username". This will work with any page since it uses "$HTTP_REFERER". "$HTTP_REFERER" is just a little code that tracks the last page you've been on.

To install this, you'll need to change one line in your member.php.

Find
Code:

eval("standardredirect(\"".gettemplate("redirect_login")."\",\"index.php?s=$session[dbsessionhash]\");");
and replace it with
Code:

eval("standardredirect(\"".gettemplate("redirect_login")."\",\"$HTTP_REFERER\");");
Once you do this, this should bring you back to the page you were on while logging in.:)

Thanks Rob for the great hack!:D

Does this work for you?

drumsy 10-18-2001 03:36 AM

Thanks, I'll try it! :)

Btw, both these hacks would work on say, a block on PHPnuke?

RobAC 10-18-2001 02:08 PM

No problem. I'm glad it's helped out. I apologize for not updating it with more features, but I just haven't had the time. I've got a few major projects I'm trying to roll out on my own site and haven't been here in the support forums much.

Looks like a cool feature! :)

certify 10-18-2001 03:07 PM

Thanks!

I'm looking for this for quite sometime now. :)

badmeetsevil- 10-18-2001 06:25 PM

Hehe. No problem. Rob did all the work, I just edited a very little part of it.

certify 10-24-2001 11:57 AM

badmeetsevil-

Now that we have the login return to the referrer page can you do one for logout too? :)

It would be a complete package then won't you think instead of going to the forum cookies clear page which is irritating.

badmeetsevil- 10-24-2001 07:48 PM

Here you go certify.

The following code will return you to your previous page when you log out of your Forums.

Open the template "error_cookieclear" and change this
Code:

All cookies cleared! Click <a href="index.php?s=$session[sessionhash]">here</a> to return to the forums index.
to this

Code:

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta http-equiv="refresh" content="1;URL=$HTTP_REFERER">
All cookies cleared! You are being returned to your previous page.

This should work. Tell me if it doesn't. :)

certify 10-25-2001 01:05 PM

Thanks, I'll try it now! :)

badmeetsevil- 10-25-2001 06:58 PM

Is it working correctly? I only tested it a bit on my forums, but it seems to be working fine.

certify 10-26-2001 06:46 AM

It works!!! :D

badmeetsevil- 10-26-2001 12:52 PM

Great. Glad I could help out.

mashby 04-21-2002 08:57 PM

And you helped me too badmeetsevil! Thanks for a great thread.

ThoughtDiver 05-09-2002 09:49 PM

Everything works except the redirect after you log in... It wants to take me to the path:

http://www.site.com/forums/://www.site.com/forums/member.php?s=&s=e98eeae106620a081645e7295b9dd4f9

It's like it's repeating a portion of the URL and then at the end there are even two "s" params being passed. Can anyone give me a hint where to look?

Thanks,
Scott

glo 11-23-2002 10:59 AM

thanks Bad meets Evil!

I havent tested it yet, but once i complete my webwelcome hack i will let u know!

I have already clicked install!!!

glo 11-27-2002 10:31 AM

Hi guys, the hack now always seems to send me back to the "request password" screen?

Even when logging in from withn the vB index page?

Any ideas why this is doing it???

Ember 01-02-2003 06:54 PM

Nice edition, but the link to rob's hack doesnt work... It keeps saying i'm not allowed to be there (I am logged in)

Marulatree 03-23-2003 11:30 AM

Quote:

11-27-02 at 12:31 PM glo said this in Post #15
Hi guys, the hack now always seems to send me back to the "request password" screen?

Even when logging in from withn the vB index page?

Any ideas why this is doing it???

I'm getting this as well, can anyone help?

Marulatree 03-30-2003 06:03 PM

Quote:

03-23-03 at 01:30 PM Marulatree said this in Post #17


I'm getting this as well, can anyone help?


Me too - Guys can anyone help?

Marulatree 03-30-2003 06:50 PM

Sorry to bother everyone - I want to get this done tonight if possible...


Any help on this will get me to move forward with completing my site...please ;)

prashidi 04-07-2003 06:28 PM

I also get this error because for some reason the $referrer is members.php

Anybody know how to solve this problem?

Nebby 05-03-2003 02:06 AM

go to the url, replace '.com' with '.org'

all hacks used to be there, but they just moved everything here, urls and all.

Splitfyre 06-13-2003 12:47 AM

I am getting the following error:

Fatal error: Call to a member function on a non-object in /home/virtual/site3/fst/var/www/html/webwelcome.php on line 24

Can't get it to come up.

dano 06-18-2003 08:14 PM

I had no problems with this. Worked like a charm on a hack 2.3.0 Thanks for the work guys, this is the perfect addittion to the hack!

zajako 06-18-2003 08:51 PM

good work ;)

Katman 06-28-2003 05:45 PM

I can't get to the orginal hack on vB.com! Yes I'm logged in, yes, I have member support and a license number with password. It still won't let me see the thread.

Does anyone have the orginal hack or another place I can get it from?

Sorry, should read above before I post! My bad.


All times are GMT. The time now is 07:12 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01274 seconds
  • Memory Usage 1,760KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_code_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (25)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete