Changeset 1689


Ignore:
Timestamp:
Jan 2, 2007, 11:30:18 PM (17 years ago)
Author:
rub
Message:

Issue ID 0000529 Re-Fixed.

Problem with "Options +MultiViews" .htaccess configuration.

Location:
branches/branch-1_6/include
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/branch-1_6/include/common.inc.php

    r1686 r1689  
    176176if ($user['is_the_guest'] and !$conf['guest_access']
    177177    and !in_array( script_basename(),
    178                       array('identification.php',
    179                             'password.php',
    180                             'register.php'
     178                      // Array of basename without file extention
     179                      array('identification',
     180                            'password',
     181                            'register'
    181182                        )
    182183                  )
  • branches/branch-1_6/include/functions.inc.php

    r1686 r1689  
    971971/**
    972972 * Return basename of the current script
    973  * Return value are chnage to loawer case
     973 * Lower case convertion is applied on return value
     974 * Return value is without file extention ".php"
    974975 *
    975976 * @param void
     
    983984    $file_name = $_SERVER['SCRIPT_NAME'];
    984985  }
    985   else if (!empty($_SERVER['PHP_SELF']))
    986   {
    987     $file_name = $_SERVER['PHP_SELF'];
    988   }
    989986  else if (!empty($_SERVER['SCRIPT_FILENAME']))
    990987  {
    991988    $file_name = $_SERVER['SCRIPT_FILENAME'];
    992989  }
    993   else if (!empty($_SERVER['PATH_TRANSLATED']))
    994   {
    995     $file_name = $_SERVER['PATH_TRANSLATED'];
    996   }
    997990  else
    998991  {
     
    1000993  }
    1001994
    1002   // $_SERVER return lower string following var ans systems
    1003   return basename(strtolower($file_name));
     995  // $_SERVER return lower string following var and systems
     996  return basename(strtolower($file_name), '.php');
    1004997}
    1005998
  • branches/branch-1_6/include/functions_calendar.inc.php

    r1686 r1689  
    178178
    179179  $must_show_list = true; // true until calendar generates its own display
    180   if (script_basename() != 'picture.php')
     180  if (script_basename() != 'picture') // basename without file extention
    181181  {
    182182    $template->assign_block_vars('calendar', array());
  • branches/branch-1_6/include/section_init.inc.php

    r1686 r1689  
    8787
    8888$next_token = 0;
    89 if (script_basename() == 'picture.php')
     89if (script_basename() == 'picture') // basename without file extention
    9090{ // the first token must be the identifier for the picture
    9191  if ( isset($_GET['image_id'])
     
    626626$page['cat_nb_images'] = isset($page['items']) ? count($page['items']) : 0;
    627627
    628 if (script_basename() == 'picture.php'
     628if (script_basename() == 'picture'
    629629    and !isset($page['image_id']) )
    630630{
Note: See TracChangeset for help on using the changeset viewer.