4images Forum & Community

4images Issues / Ausgaben => Discussion & Troubleshooting => Topic started by: Alain on June 22, 2002, 05:20:42 PM

Title: Authentication
Post by: Alain on June 22, 2002, 05:20:42 PM
I tried discussion solutions at http://www.4homepages.de/forum/viewtopic.php?t=321&highlight=auth but they don't seem to work for me. It is returning an array but with nothing in.

I would like to know how to block people from viewing pictures if they are not registered (I know that it may be possible at the setup process but I can't remember and maybe that it would kill my current config.) ?

Finally, you may have already answered to this question, but how to add a link just below the LogOut button for members? I would like to add a link only for members and if they are already logged in.

Danke gut!!
Title: Authentication
Post by: Jan on June 22, 2002, 06:46:01 PM
Hi,

try this for version 1.5 (be sure to add this code at the top of your file before any HTML output):

Code: [Select]
<?php 
define
&#40;'ROOT_PATH', './'&#41;; 
include&#40;ROOT_PATH.'global.php'&#41;; 
require&#40;ROOT_PATH.'includes/sessions.php'&#41;;
?>


Then use:
Code: [Select]
if ($user_info['user_level'] > USER_AWAITING) {
  // put your link here
}



Greets Jan