Activity Stream
48,167 MEMBERS
62638 ONLINE
besthostingforums On YouTube Subscribe to our Newsletter besthostingforums On Twitter besthostingforums On Facebook besthostingforums On facebook groups

Results 1 to 9 of 9
  1.     
    #1
    Member

    Default Redirect to Login Page

    Ok, when anyone who is not registered who is not logged in, when they click on any of the forums, instead of hiding threads to them from that section, I want them to be redirected to the login page.....

    Any ways to do this or any mods?
    D@rekills4 Reviewed by D@rekills4 on . Redirect to Login Page Ok, when anyone who is not registered who is not logged in, when they click on any of the forums, instead of hiding threads to them from that section, I want them to be redirected to the login page..... Any ways to do this or any mods? Rating: 5

  2.   Sponsored Links

  3.     
    #2
    Member
    for vb3**

    Go to admin cp>style manager>all style options>place in your header Code:
    Code: 
    <if condition="$bbuserinfo['usergroupid'] == 1">
    <meta HTTP-EQUIV="REFRESH" content="X; url=http://www.yourforum*********register.php">
    </if>
    Replace X with how many seconds you want the unregistered to view your board.
    Replace "yourforum" with your site name.
    Press save and all done!



    for vb4**

    Code: 
    <vb:if condition="THIS_SCRIPT != 'register'" AND condition="$bbuserinfo['userid'] == 0">
    	<meta HTTP-EQUIV="REFRESH" content="15; url=http://yoursite.com/register.php">
    </vb:if>
    Paste this block in the headinclude template just after the rest of the meta tags in the top of the form. With this hack, if you have a visitor to your site checking things out, they will be redirected to the registration form in 15 seconds using this code. To change the time of the redirect change 15 to what ever.
    go

  4.     
    #3
    Member
    Thanks for the help mate

  5.     
    #4
    Member
    Website's:
    ZilleJulle.com PornBoxIt.com TheCavernForum.com TheFlix.net
    leonight do you know about same thing for smf ?
    Webmaster add your site!

  6.     
    #5
    Member
    Website's:
    reddit.com
    I dont know anything about SMF, but look into the template system, search for "register" (that means only guests will be able to see it) and thake the code from there..

    Lets say for example it can be something like <ifguest><a href="register.php>Register</a></ifguest>

    Just take that code and modify it like:
    Code: 
    <ifguest><meta HTTP-EQUIV="REFRESH" content="X; url=http://www.yourforum*********register.php"></ifguest>
    And then place it in the header alongside the other meta tags.

    Although this does not what OP requested, it just refreshes the page after X second, works on any html page.
    I design free logos. click here.

  7.     
    #6
    Member
    Website's:
    reddit.com
    Now to the OP's request:
    Open the template forumhome_forumbit_level1_nopost
    find:
    Code: 
    <a href="forumdisplay.php?$session[sessionurl]f=$forum[forumid]">$forum[title]</a>
    replace that bit with:
    Code: 
    <if condition="$bbuserinfo['usergroupid'] == 1"><a href="register.php">$forum[title]</a></if><if condition="$bbuserinfo['usergroupid'] == 2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20"><a href="forumdisplay.php?$session[sessionurl]f=$forum[forumid]">$forum[title]</a></if>
    Should do the trick. Although guests will still be able to visit through a direct link.
    (I know, it's messy using all the usergroup id's, but i don't remember the short code off my head.)

    edit. yeah, now that i think of it, a simple "else" would do the job!
    I design free logos. click here.

  8.     
    #7
    Member
    Quote Originally Posted by leonight View Post
    for vb3**

    Go to admin cp>style manager>all style options>place in your header Code:
    Code: 
    <if condition="$bbuserinfo['usergroupid'] == 1">
    <meta HTTP-EQUIV="REFRESH" content="X; url=http://www.yourforum*********register.php">
    </if>
    Replace X with how many seconds you want the unregistered to view your board.
    Replace "yourforum" with your site name.
    Press save and all done!



    for vb4**

    Code: 
    <vb:if condition="THIS_SCRIPT != 'register'" AND condition="$bbuserinfo['userid'] == 0">
        <meta HTTP-EQUIV="REFRESH" content="15; url=http://yoursite.com/register.php">
    </vb:if>
    Paste this block in the headinclude template just after the rest of the meta tags in the top of the form. With this hack, if you have a visitor to your site checking things out, they will be redirected to the registration form in 15 seconds using this code. To change the time of the redirect change 15 to what ever.



    Sorry but this thing directly redirects users to the login page....
    I want them to be redirected when they click on any forum or thread...
    Except the ones in the Announcements section....

  9.     
    #8
    Member
    Website's:
    reddit.com
    My solution does what you ask for. It just does it on every forum.
    You can add another <if condition... to limit the forum id's, but it will become a little more complicated.
    I design free logos. click here.

  10.     
    #9
    Member
    NA.....
    That would just make it complicated.....

    Anyone else?


    EDIT: My bad, I think J have figured it out.....

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. how to redirect 404 page to date?
    By dr2015 in forum General Discussion
    Replies: 5
    Last Post: 29th Oct 2012, 09:49 PM
  2. How to make redirect page in wp?
    By flippy07 in forum Wordpress
    Replies: 4
    Last Post: 18th Jul 2012, 08:52 PM
  3. Replies: 4
    Last Post: 3rd Nov 2011, 11:08 PM
  4. Redirect to Login Page to SMF
    By PBI NetWork in forum Web Application/Script Support
    Replies: 0
    Last Post: 10th Feb 2011, 06:23 PM
  5. Redirect to another html page
    By cybertuga in forum Technical Help Desk Support
    Replies: 5
    Last Post: 3rd Jan 2010, 05:54 PM

Tags for this Thread

BE SOCIAL