vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Design and Graphics Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=168)
-   -   How do I move my "login" function off the navbar to its own page? (https://vborg.vbsupport.ru/showthread.php?t=196643)

len backus 11-18-2008 09:58 PM

How do I move my "login" function off the navbar to its own page?
 
My goal is to clean up the look of my site.

I tried this as follows. I copied the form code and placed it into a separate page that I linked to from the navbar. It looked good but when I input my name and pass and hit enter it gave me a 404 error.

Quote:

<!-- login form -->
<form action="login.php?do=login" method="post" onsubmit="md5hash(vb_login_password, vb_login_md5password, vb_login_md5password_utf, $show[nopasswordempty])">
<script type="text/javascript" src="clientscript/vbulletin_md5.js?v=$vboptions[simpleversion]"></script>
<table cellpadding="0" cellspacing="$stylevar[formspacer]" border="0">
<tr>
<td class="smallfont"><label for="navbar_username">$vbphrase[username]</label></td>
<td><input type="text" class="bginput" style="font-size: 11px" name="vb_login_username" id="navbar_username" size="10" accesskey="u" tabindex="101" value="$vbphrase[username]" onfocus="if (this.value == '$vbphrase[username]') this.value = '';" /></td>
<td class="smallfont" colspan="2" nowrap="nowrap"><label for="cb_cookieuser_navbar"><input type="checkbox" name="cookieuser" value="1" tabindex="103" id="cb_cookieuser_navbar" accesskey="c" />$vbphrase[remember_me]</label></td>
</tr>
<tr>
<td class="smallfont"><label for="navbar_password">$vbphrase[password]</label></td>
<td><input type="password" class="bginput" style="font-size: 11px" name="vb_login_password" id="navbar_password" size="10" tabindex="102" /></td>
<td><input type="submit" class="button" value="$vbphrase[log_in]" tabindex="104" title="$vbphrase[enter_username_to_login_or_register]" accesskey="s" /></td>
</tr>
</table>
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="do" value="login" />
<input type="hidden" name="vb_login_md5password" />
<input type="hidden" name="vb_login_md5password_utf" />
</form>
<!-- / login form -->

SEOvB 11-18-2008 10:24 PM

You need to make sure your path to login.php is correct.

Code:

<form action="/YOURFORUMS/login.php?do=login" method="post" onsubmit="md5hash(vb_login_password, vb_login_md5password, vb_login_md5password_utf, $show[nopasswordempty])">

len backus 11-18-2008 10:51 PM

Got it, thanks much.

SEOvB 11-18-2008 11:04 PM

Quote:

Originally Posted by len backus (Post 1668345)
Thanks, is YOURFORUMS the entire http path or something else? And why would I have to change what was working in the Navbar?

you can either use a relative path ex: /forum/login.php or the entire path either way wont matter, http://yoursite.com/forum/login.php

You have to change it because you are getting a 404 error. Which means that your 404 page (or whatever page your displaying this on) is outside of the forum root folder.

len backus 11-19-2008 12:16 AM

FRDS, it worked perfectly. But...I have this on a separate page. When I log in, it doesn't redirect me to the forum home page where I initially clicked on the "log in" link.

I wonder how I can get the redirect to work so I and my members don't have to click on Forum Home again??

SEOvB 11-19-2008 02:28 AM

Quote:

Originally Posted by len backus (Post 1668382)
FRDS, it worked perfectly. But...I have this on a separate page. When I log in, it doesn't redirect me to the forum home page where I initially clicked on the "log in" link.

I wonder how I can get the redirect to work so I and my members don't have to click on Forum Home again??

I think the only way to do that would be to take make a plugin at the login redirect location to redirect users to your forum home. But then I think it'd break the login process else where, how it takes you the thread you were viewing when you logged in.


All times are GMT. The time now is 01:22 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.02472 seconds
  • Memory Usage 1,730KB
  • 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
  • (1)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)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