[ Index ] |
PHP Cross Reference of osCMax 2.0.4 |
[Summary view] [Print] [Text view]
1 <?php 2 /* 3 $Id: warnings.php 1 2008-09-22 11:11:07Z user $ 4 5 osCMax Power E-Commerce 6 http://oscdox.com 7 8 Copyright 2008 osCMax 9 10 Released under the GNU General Public License 11 */ 12 13 // check if the 'install' directory exists, and warn of its existence 14 if (WARN_INSTALL_EXISTENCE == 'true') { 15 if (file_exists(dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME']) . '/install')) { 16 $messageStack->add('header', WARNING_INSTALL_DIRECTORY_EXISTS, 'warning'); 17 } 18 } 19 20 // check if the configure.php file is writeable 21 if (WARN_CONFIG_WRITEABLE == 'true') { 22 if ( (file_exists(dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME']) . '/includes/configure.php')) && (is_writeable(dirname($HTTP_SERVER_VARS['SCRIPT_FILENAME']) . '/includes/configure.php')) ) { 23 $messageStack->add('header', WARNING_CONFIG_FILE_WRITEABLE, 'warning'); 24 } 25 } 26 27 // check if the session folder is writeable 28 if (WARN_SESSION_DIRECTORY_NOT_WRITEABLE == 'true') { 29 if (STORE_SESSIONS == '') { 30 if (!is_dir(tep_session_save_path())) { 31 $messageStack->add('header', WARNING_SESSION_DIRECTORY_NON_EXISTENT, 'warning'); 32 } elseif (!is_writeable(tep_session_save_path())) { 33 $messageStack->add('header', WARNING_SESSION_DIRECTORY_NOT_WRITEABLE, 'warning'); 34 } 35 } 36 } 37 38 // check session.auto_start is disabled 39 if ( (function_exists('ini_get')) && (WARN_SESSION_AUTO_START == 'true') ) { 40 if (ini_get('session.auto_start') == '1') { 41 $messageStack->add('header', WARNING_SESSION_AUTO_START, 'warning'); 42 } 43 } 44 45 if ( (WARN_DOWNLOAD_DIRECTORY_NOT_READABLE == 'true') && (DOWNLOAD_ENABLED == 'true') ) { 46 if (!is_dir(DIR_FS_DOWNLOAD)) { 47 $messageStack->add('header', WARNING_DOWNLOAD_DIRECTORY_NON_EXISTENT, 'warning'); 48 } 49 } 50 51 if ($messageStack->size('header') > 0) { 52 echo $messageStack->output('header'); 53 } 54 55 if (isset($HTTP_GET_VARS['error_message']) && tep_not_null($HTTP_GET_VARS['error_message'])) { 56 ?> 57 <table border="0" width="100%" cellspacing="0" cellpadding="2"> 58 <tr class="headerError"> 59 <td class="headerError"><?php echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['error_message']))); ?></td> 60 </tr> 61 </table> 62 <?php 63 } 64 65 if (isset($HTTP_GET_VARS['info_message']) && tep_not_null($HTTP_GET_VARS['info_message'])) { 66 ?> 67 <table border="0" width="100%" cellspacing="0" cellpadding="2"> 68 <tr class="headerInfo"> 69 <td class="headerInfo"><?php echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['info_message']))); ?></td> 70 </tr> 71 </table> 72 <?php 73 } 74 ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Fri Jan 1 13:43:16 2010 | Cross-referenced by PHPXref 0.7 |