squirrelmail-webmail  1.4.22
About: SquirrelMail is a standards-based webmail package with strong MIME support, address books, and folder manipulation (written in PHP4).
  Fossies Dox: squirrelmail-webmail-1.4.22.tar.gz  ("inofficial" and yet experimental doxygen-generated source code documentation)  

options.php File Reference

Go to the source code of this file.

Namespaces

 plugins
 

Functions

 parseConfig ( $cfg_file)
 
 change_to_rel_path ($old_path)
 
 change_to_sm_path ($old_path)
 

Variables

const PAGE_NAME 'administrator_options'
 
const SM_PATH '../../'
 
global $data_dir
 
global $username
 
 $newcfg = array( )
 
foreach( $defcfg as $key=> $def) $cfgfile = SM_PATH . 'config/config.php'
 
 $colapse
 
 if (sqgetGlobalVar( 'switch', $switch, SQ_GET))
 
 $act_grp = 'Titles'
 
foreach( $newcfg as $k=> $v) if( $colapse['Group7']=='off') if( $colapse['Group8']=='on') else
 
 if ($colapse[ 'Group8']=='off')
 

Function Documentation

◆ change_to_rel_path()

change_to_rel_path (   $old_path)

Change paths containing SM_PATH to admin-friendly paths relative to the config dir, i.e.: '' --> <empty string>=""> SM_PATH . 'images/logo.gif' --> ../images/logo.gif '/absolute/path/logo.gif' --> /absolute/path/logo.gif 'http://whatever/' --> http://whatever Note removal of quotes in returned value

Parameters
string$old_pathpath that has to be converted
Returns
string new path @access private

Definition at line 156 of file options.php.

◆ change_to_sm_path()

change_to_sm_path (   $old_path)

Change relative path (relative to config dir) to internal SM_PATH, i.e.: empty_string --> '' ../images/logo.gif --> SM_PATH . 'images/logo.gif' images/logo.gif --> SM_PATH . 'config/images/logo.gif' /absolute/path/logo.gif --> '/absolute/path/logo.gif' C:/absolute/win/path --> 'C:/absolute/win/path' http://whatever/ --> 'http://whatever'

Parameters
string$old_pathpath that has to be converted
Returns
string new path @access private

Definition at line 177 of file options.php.

References elseif, and SM_PATH.

◆ parseConfig()

parseConfig (   $cfg_file)

parse the config file

Parameters
string$cfg_file@access private

Definition at line 25 of file options.php.

References $j, and $newcfg.

Variable Documentation

◆ $act_grp

$act_grp = 'Titles'

Definition at line 282 of file options.php.

◆ $cfgfile

foreach ($defcfg as $key=> $def) $cfgfile = SM_PATH . 'config/config.php'

Definition at line 244 of file options.php.

◆ $colapse

$colapse
Initial value:
= array( 'Titles' => 'off',
'Group1' => getPref($data_dir, $username, 'adm_Group1', 'off' ),
'Group2' => getPref($data_dir, $username, 'adm_Group2', 'on' ),
'Group3' => getPref($data_dir, $username, 'adm_Group3', 'on' ),
'Group4' => getPref($data_dir, $username, 'adm_Group4', 'on' ),
'Group5' => getPref($data_dir, $username, 'adm_Group5', 'on' ),
'Group6' => getPref($data_dir, $username, 'adm_Group6', 'on' ),
'Group7' => getPref($data_dir, $username, 'adm_Group7', 'on' ),
'Group8' => getPref($data_dir, $username, 'adm_Group8', 'on' ),
'Group9' => getPref($data_dir, $username, 'adm_Group9', 'on' ),
'Group10' => getPref($data_dir, $username, 'adm_Group10', 'on' ) )

Definition at line 248 of file options.php.

◆ $data_dir

global $data_dir

Definition at line 225 of file options.php.

Referenced by save_option().

◆ $newcfg

$newcfg = array( )

Definition at line 238 of file options.php.

Referenced by parseConfig().

◆ $username

global $username

Definition at line 225 of file options.php.

Referenced by save_option().

◆ else

if ($fp=@fopen($cfgfile, 'w')) else
Initial value:
{
$sw = '(-)'

Definition at line 524 of file options.php.

◆ if [1/2]

if( $colapse['Group8']=='off')

Definition at line 531 of file options.php.

◆ if [2/2]

Definition at line 261 of file options.php.

◆ PAGE_NAME

const PAGE_NAME 'administrator_options'

This is the administrator_options page

Definition at line 17 of file options.php.

Referenced by adm_check_user(), compose_Header(), Darkness_HeaderPlugin(), displayPageHeader(), is_logged_in(), and set_up_language().

◆ SM_PATH

const SM_PATH '../../'

@ignore

Definition at line 222 of file options.php.

Referenced by change_to_sm_path().

getPref
getPref($data_dir, $username, $string, $default='')
Definition: db_prefs.php:316
$username
global $username
Definition: options.php:225
$data_dir
global $data_dir
Definition: options.php:225