Changeset 804 for trunk/category.php


Ignore:
Timestamp:
Jul 17, 2005, 5:06:39 PM (19 years ago)
Author:
plg
Message:
  • new feature : use Apache authentication. If $confapache_authentication is set true : if no user matches $_SERVERREMOTE_USER in "users" table, PWG automatically creates one. This way, users can customize the behaviour of the application.
  • template : new organisation of identification menu (category.php). Simplification is required for Apache authentication (no logout link even if user is externally logged in)
  • new : usernames can contain quotes (required because Apache authentication authorized quotes in usernames)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/category.php

    r801 r804  
    255255//--------------------------------------------------------------------- summary
    256256
    257 if ( !$user['is_the_guest'] )
    258 {
    259   $template->assign_block_vars('logout',array());
    260   // administration link
    261   if ( $user['status'] == 'admin' )
    262   {
    263     $template->assign_block_vars('logout.admin', array());
     257if ($user['is_the_guest'])
     258{
     259  $template->assign_block_vars('register', array());
     260  $template->assign_block_vars('login', array());
     261 
     262  $template->assign_block_vars('quickconnect', array());
     263  if ($conf['authorize_remembering'])
     264  {
     265    $template->assign_block_vars('quickconnect.remember_me', array());
    264266  }
    265267}
    266268else
    267269{
    268   $template->assign_block_vars('login',array());
    269   if ($conf['authorize_remembering'])
    270   {
    271     $template->assign_block_vars('login.remember_me',array());
     270  $template->assign_block_vars('hello', array());
     271  $template->assign_block_vars('profile', array());
     272
     273  // the logout link has no meaning with Apache authentication : it is not
     274  // possible to logout with this kind of authentication.
     275  if (!$conf['apache_authentication'])
     276  {
     277    $template->assign_block_vars('logout', array());
     278  }
     279
     280  if ('admin' == $user['status'])
     281  {
     282    $template->assign_block_vars('admin', array());
    272283  }
    273284}
Note: See TracChangeset for help on using the changeset viewer.