| Login option on the Portal |
| Author | Text |
nautique Just arrived
Posts: 7

Gender:  Online: No
Version: 4.0.1 Country: Netherlands Languages: Dutch, English |
Date: 03/02/2009 15:27 Login option on the Portal | #post17991 | Hello,
I am thinkin of using the 4.0.1 version.
But i want the website for a closed community.
I did see that you can hide allot of features so only registered members can see the content. But i was wondering if someone is willing to help me adjust the script, so that everyone first have to login before they can see the website (just like the admin part, a check if you are a member of the website)
I appreciate any kind of help/suggestions ! |
|
 |
| |
freaky Donator
Posts: 746

Gender:  Online: No
Version: 401 Country: Switzerland Languages: Englisch, German, French.... |
Date: 04/02/2009 09:40 Re: Login option on the Portal | #post18002 | hello & welcome Nautique
I created a MOD for you!
just Read the README.txt file provided in the ZIP archive.
Tested and worked for me.
Hope it works fine for you
Peace Freaky |
|
 |
| |
nautique Just arrived
Posts: 7

Gender:  Online: No
Version: 4.0.1 Country: Netherlands Languages: Dutch, English |
Date: 04/02/2009 20:49 Re: Login option on the Portal | #post18024 | Hi Freaky !
thank you for your reaction!
i just have a small question about your MOD.
in the description your refer to this :
| code | change to:
window.location.href='http://YOURDOMAIN.COM/users.html'; |
But there is no users.html, so i think i have to refer to users/index.html right ?
can you look at it again for me please to see if you maybe made a mistake ?
|
|
 |
| |
freaky Donator
Posts: 746

Gender:  Online: No
Version: 401 Country: Switzerland Languages: Englisch, German, French.... |
Date: 05/02/2009 08:07 Re: Login option on the Portal | #post18031 | sry about.. I forgot that I use ModRewrite...
change to:
window.location.href=' http://YOURDOMAIN.COM/index.php?page=users';
now it should work...
P.S this quite a simple way to solve your problem. It only redirects you to the user page if your not logged |
|
 |
| |
nautique Just arrived
Posts: 7

Gender:  Online: No
Version: 4.0.1 Country: Netherlands Languages: Dutch, English |
Date: 05/02/2009 10:21 Re: Login option on the Portal | #post18037 | Hmm stil don't work for me
i understand what you are explaining. Basicly i just have to add the code:
| code | if (!isUser($userid) and $check_if_user_log == 0){
?>
<script type="text/javascript">
window.location.href='window.location.href='/index.php?page=users';
</script>
<?php
$check_if_user_log = 1;
}; |
to every page i want private, with the right redirection to the user page. But when i put the index.php?page=users, he still refers to my regular index page. Edited: 05/02/2009 10:21 |
|
 |
| |
freaky Donator
Posts: 746

Gender:  Online: No
Version: 401 Country: Switzerland Languages: Englisch, German, French.... |
Date: 05/02/2009 10:25 Re: Login option on the Portal | #post18038 | no no.. it's works don't copy anything
the code in index.php should look like this for you.:
| code |
if (!isUser($userid) and $check_if_user_log == 0){
?>
<script type="text/javascript">
window.location.href='http://www.themillionaireslife.com/intranet/users.html';
</script>
<?php
$check_if_user_log = 1;
};
|
it should work! Edited: 05/02/2009 10:26 |
|
 |
| |
nautique Just arrived
Posts: 7

Gender:  Online: No
Version: 4.0.1 Country: Netherlands Languages: Dutch, English |
Date: 05/02/2009 10:32 Re: Login option on the Portal | #post18040 | Then i get this:
Because he is now trying to find a page that dont exist Edited: 05/02/2009 10:50 |
|
 |
| |
freaky Donator
Posts: 746

Gender:  Online: No
Version: 401 Country: Switzerland Languages: Englisch, German, French.... |
Date: 05/02/2009 13:10 Re: Login option on the Portal | #post18076 | did you upload all the files?
because at the moment you have a loop on your site and I fixed this by setting a variable in /pages/users/index.php
go in /pages/users/index.php
and find:
$check_if_user_log = 1;
the code works fine for me.. |
|
 |
| |