Changeset 95 for trunk/include
- Timestamp:
- Mar 3, 2009, 8:33:23 PM (16 years ago)
- Location:
- trunk/include
- Files:
-
- 3 added
- 3 deleted
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/config_from_xoops.class.php
r92 r95 26 26 var $module_path; 27 27 var $module_url; 28 var $module_db_prefix; 29 var $xoops_upload_path; 30 var $xoops_upload_url; 31 28 32 29 33 function __constructor() //for PHP5 30 34 { 31 35 $this->ConfigFromXoops(); 36 32 37 } 33 38 … … 89 94 } 90 95 } 96 97 // define from /settings/definition.inc.php (XCL) or /include/common.php(2016a-JP) 98 $this->xoops_upload_path = $this->xoops_root_path .'/uploads'; 99 $this->xoops_upload_url = $this->xoops_url . '/uploads'; 100 101 if ($this->module_name == 'wordpress') 102 $this->module_db_prefix = $this->xoops_db_prefix . '_wp_'; 103 else 104 $this->module_db_prefix = $this->xoops_db_prefix . '_' . $this->module_name . '_'; 105 91 106 } 92 107 -
trunk/include/notification.inc.php
r61 r95 1 1 <?php 2 3 function xpress_notify_info( $category , $item_id ) 2 function xpress_notify( $category , $item_id ) 4 3 { 5 $db =& Database::getInstance() ;6 4 $mydirname = basename( dirname( dirname( __FILE__ ) ) ) ; 7 8 9 // $module_handler =& xoops_gethandler( 'module' ) ;10 // $module =& $module_handler->getByDirname( $mydirname ) ;11 5 12 6 if( $category == 'global' ) { -
trunk/include/set_cash_cookie_path.php
r92 r95 50 50 */ 51 51 if ( !defined('COOKIEPATH') ) 52 define('COOKIEPATH', preg_replace('|https?://[^/]+|i', '', XOOPS_URL. '/' ) );52 define('COOKIEPATH', preg_replace('|https?://[^/]+|i', '', $xoops_config->xoops_url . '/' ) ); 53 53 54 54 /** … … 57 57 */ 58 58 if ( !defined('SITECOOKIEPATH') ) 59 define('SITECOOKIEPATH', preg_replace('|https?://[^/]+|i', '', XOOPS_URL. '/' ) );59 define('SITECOOKIEPATH', preg_replace('|https?://[^/]+|i', '', $xoops_config->xoops_url . '/' ) ); 60 60 61 61 /** -
trunk/include/xpress_block_render.php
r89 r95 62 62 function get_block_stylesheet_url($mydirname) 63 63 { 64 $mydirpath = XOOPS_ROOT_PATH . '/modules/' . $mydirname; 64 global $xoops_config; 65 $mydirpath = $xoops_config->xoops_root_path . '/modules/' . $mydirname; 65 66 $select_theme = get_xpress_theme_name($mydirname); 66 67 $style_file = $mydirpath . '/wp-content/themes/' . $select_theme . '/blocks/style.css'; 67 68 if (file_exists($style_file)) 68 return XOOPS_URL. '/modules/' .$mydirname . '/wp-content/themes/' . $select_theme . '/blocks/style.css';69 return $xoops_config->xoops_url . '/modules/' .$mydirname . '/wp-content/themes/' . $select_theme . '/blocks/style.css'; 69 70 else 70 return XOOPS_URL. '/modules/' .$mydirname . '/wp-content/themes/xpress_default/blocks/style.css';71 return $xoops_config->xoops_url . '/modules/' .$mydirname . '/wp-content/themes/xpress_default/blocks/style.css'; 71 72 } 72 73 … … 88 89 function get_block_file_path($mydirname,$file_name) 89 90 { 90 $mydirpath = XOOPS_ROOT_PATH . '/modules/' . $mydirname; 91 global $xoops_config; 92 $mydirpath = $xoops_config->xoops_root_path . '/modules/' . $mydirname; 91 93 $select_theme = get_xpress_theme_name($mydirname); 92 94 $block_file = $mydirpath . '/wp-content/themes/' . $select_theme . '/blocks/' . $file_name; 93 95 94 96 if (!file_exists($block_file)) 95 $block_file = XOOPS_ROOT_PATH. '/modules/' .$mydirname . '/wp-content/themes/xpress_default/blocks/' . $file_name;97 $block_file = $xoops_config->xoops_root_path . '/modules/' .$mydirname . '/wp-content/themes/xpress_default/blocks/' . $file_name; 96 98 return $block_file; 97 99 } -
trunk/include/xpress_cache.php
r36 r95 4 4 function xpress_cache_read($mydirname,$collation_key) 5 5 { 6 $cache_dir = XOOPS_ROOT_PATH . '/cache/'; 6 global $xoops_config; 7 $cache_dir = $xoops_config->xoops_root_path . '/cache/'; 7 8 $cache_time = 0; 8 9 $filename = $cache_dir .$mydirname . '_' . $collation_key; … … 19 20 function xpress_cache_write($mydirname,$collation_key,$content) 20 21 { 21 $cache_dir = XOOPS_ROOT_PATH . '/cache/'; 22 global $xoops_config; 23 $cache_dir = $xoops_config->xoops_root_path . '/cache/'; 22 24 $cache_time = 0; 23 25 … … 35 37 function xpress_cache_clear($mydirname) 36 38 { 37 $cache_dir = XOOPS_ROOT_PATH . '/cache/'; 39 global $xoops_config; 40 $cache_dir = $xoops_config->xoops_root_path . '/cache/'; 38 41 $cache_time = 0; 39 42 if ($dh = opendir($cache_dir)) {
Note: See TracChangeset
for help on using the changeset viewer.