Custom Login Page
I personally hate seeing that ugly login box at the top of the screen in the navbar template. I came up with this quick and easy fix, have a separate page for it.
If you'd like a custom login page, and simply have to link to it in your navbar, then follow the quick steps below. Step 1) Create a new .php file called clogin.php (it must be named this, do not change the name), and upload it to your forum root directory. Step 2) Put the below code in your new clogin.php file: Code:
<?php Step 4) Insert the following code into your "clogin" (without the quotation marks): Code:
$stylevar[htmldoctype] You must change all of the "SITENAME" text in your new template to your actual site name. Please post here if you need assistance, please. :) Credits to Gary King! (https://vborg.vbsupport.ru/showthread.php?t=62164) |
installed but not works
|
It works but Trasion left out a step. I think what his intent was to add a Login link to the navbar linked to your page: yoursite.com/forums/clogin.php
Nice work Trasion! --------------- Added [DATE]1254951467[/DATE] at [TIME]1254951467[/TIME] --------------- It looks like this works when added to the navbar: $template_hook[navbar_buttons_right] <td class="vbmenu_control"> <a href="clogin.php?">Log In</a></td> --------------- Added [DATE]1254952892[/DATE] at [TIME]1254952892[/TIME] --------------- Then you need to delete the old login form from the navbar template. |
Yes, you must add that too. Sorry.
After you go to that page, it should work! |
1 Attachment(s)
It should and it does. After testing I have added it to my board. This allows for a larger site logo without pushing things around for users with small screens.:up:
|
You might want to add a condition to remove the Log In button if the user is logged in and replace it with Log Out.
|
Meh. My users know which one to click. ;)
|
Code:
<td class="vbmenu_control"> |
I do that
but if i want to stay in the some page "clogin.php" without to go after login (or if I'm conected) to index.php just a pape for login and say HELLO :) |
Thanks a lot! I've spent an hour hunting for a mod so I can put a login link on my blog, but this works perfectly.
|
Will this work with VB4?
|
Really nice article dude lol. I modified it to fix my needs :D Also working on a vB4 one, don't mind if i post it?
|
This code does not work in release 4. The fetch_template functions no longer work. They must be replaced with object model. See this article for details.
https://vborg.vbsupport.ru/showthread.php?t=228078 eval('$navbar = "' . fetch_template('navbar') . '";'); eval('print_output("' . fetch_template('clogin') . '");'); |
I believe this just broke with the recent security update.
I'm trying to figure out why right now. |
is there any guide to custom login page in vbulletin 4?
|
Quote:
https://vborg.vbsupport.ru/showthread.php?t=228112 |
Thanks for this article but I have a problem with redirecting the logged in members to the previous page which they have been viewing as guest!
is there any way to do this ? Thank you. |
All times are GMT. The time now is 07:51 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|