|
From: Jon O. <jon...@us...> - 2006-06-17 20:46:30
|
Update of /cvsroot/mxbb/mx_dev_startkit In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv4620/modules/mx_dev_startkit Modified Files: mx_dev_startkit.php Log Message: security Index: mx_dev_startkit.php =================================================================== RCS file: /cvsroot/mxbb/mx_dev_startkit/mx_dev_startkit.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** mx_dev_startkit.php 5 Apr 2006 20:55:19 -0000 1.4 --- mx_dev_startkit.php 17 Jun 2006 20:46:27 -0000 1.5 *************** *** 41,45 **** | $mx_module->smilies_pass() | $mx_module->generate_smilies() ! | | | Remember: All instances of page_header and page_tail inclusions should be removed, not to interfer with mxBB headers --- 41,45 ---- | $mx_module->smilies_pass() | $mx_module->generate_smilies() ! | | | Remember: All instances of page_header and page_tail inclusions should be removed, not to interfer with mxBB headers *************** *** 49,53 **** | ------------------ | Core provides a rich set of parameter types. Additional block specific types are defined in module_root/admin/mx_module_defs.php. ! | Block parameters are accessed with the mx_block->get_parameters() method. | | mx_block->get_parameters() Api --- 49,53 ---- | ------------------ | Core provides a rich set of parameter types. Additional block specific types are defined in module_root/admin/mx_module_defs.php. ! | Block parameters are accessed with the mx_block->get_parameters() method. | | mx_block->get_parameters() Api *************** *** 57,61 **** | Examples: | ! | $mx_block->get_parameters( MX_GET_ALL_PARS ) | - returns an array with all parameters :: array('par_name1' => $par1_value, 'par_name2' => $par2_value, ...) | --- 57,61 ---- | Examples: | ! | $mx_block->get_parameters( MX_GET_ALL_PARS ) | - returns an array with all parameters :: array('par_name1' => $par1_value, 'par_name2' => $par2_value, ...) | *************** *** 69,73 **** | Module Settings using additional db tables | ------------------ ! | More advanced modules need additional settings, intended for ALL module blocks. | For example, a image album module needs a defined pics folder and other modules may use global settings | NOTE: Block specific parameters should never use additional (non portal) db tables, since such data is NOT included in the portal cache engine and therefore speed will be affected. --- 69,73 ---- | Module Settings using additional db tables | ------------------ ! | More advanced modules need additional settings, intended for ALL module blocks. | For example, a image album module needs a defined pics folder and other modules may use global settings | NOTE: Block specific parameters should never use additional (non portal) db tables, since such data is NOT included in the portal cache engine and therefore speed will be affected. *************** *** 77,87 **** | Data should be managed in an axtra module adminCP panel | Db tables to be used should be defined in the includes/mx_module_constants.php file ! | Data should be accessed using the standard $db api. | \********************************************************************************/ ! ! if( !defined('IN_PORTAL') ) { ! die("Hacking attempt !!!"); } --- 77,87 ---- | Data should be managed in an axtra module adminCP panel | Db tables to be used should be defined in the includes/mx_module_constants.php file ! | Data should be accessed using the standard $db api. | \********************************************************************************/ ! ! if( !defined('IN_PORTAL') || !is_object($mx_block)) { ! die("Hacking attempt"); } *************** *** 89,93 **** // Load module constants and functions // ! include_once($mx_root_path . $mx_block->module_root_path . "includes/startkit_constants.$phpEx"); // Will load additional module lang keys, definitions, copyrights and theme data include_once($mx_root_path . $mx_block->module_root_path . "includes/startkit_functions.$phpEx"); // Will load additional module functions (be sure to prefix with 'mx_' to avoid function conflicts) --- 89,93 ---- // Load module constants and functions // ! include_once($mx_root_path . $mx_block->module_root_path . "includes/startkit_constants.$phpEx"); // Will load additional module lang keys, definitions, copyrights and theme data include_once($mx_root_path . $mx_block->module_root_path . "includes/startkit_functions.$phpEx"); // Will load additional module functions (be sure to prefix with 'mx_' to avoid function conflicts) *************** *** 140,144 **** { mx_message_die( CRITICAL_ERROR, "Could not query module information", "", __LINE__, __FILE__, $sql ); ! } $results = $db->sql_fetchrow( $result ); $startkit_module_name = $results['module_name']; --- 140,144 ---- { mx_message_die( CRITICAL_ERROR, "Could not query module information", "", __LINE__, __FILE__, $sql ); ! } $results = $db->sql_fetchrow( $result ); $startkit_module_name = $results['module_name']; *************** *** 155,159 **** // ! // Block Body // - not much to do in this simple block // --- 155,159 ---- // ! // Block Body // - not much to do in this simple block // *************** *** 171,202 **** // Pass Block data to template // ! $template->assign_vars( array( // // Titles // 'L_STARTKIT' => $lang['Startkit'], ! 'L_STARTKIT_PARAMETER' => $lang['Startkit_parameter'], 'L_STARTKIT_PARAMETER_EXPLAIN' => $lang['Startkit_parameter_explain'], 'L_TEST_STRING' => $lang['Test_string'], 'L_TEST_NUMBER' => $lang['Test_number'], ! 'L_STARTKIT_PARAMETER_MODIFIED' => $lang['Startkit_parameter_modified'], 'L_STARTKIT_PARAMETER_MODIFIED_EXPLAIN' => $lang['Startkit_parameter_modified_explain'], 'L_TEST_MODIFIED' => $lang['Test_modified'], ! 'L_STARTKIT_PARAMETER_CUSTOM' => $lang['Startkit_parameter_custom'], 'L_STARTKIT_PARAMETER_CUSTOM_EXPLAIN' => $lang['Startkit_parameter_custom_explain'], 'L_TEST_CUSTOM' => $lang['Test_custom'], ! 'L_STARTKIT_CONFIG' => $lang['Startkit_config'], 'L_STARTKIT_CONFIG_EXPLAIN' => $lang['Startkit_config_explain'], 'L_TEST_CONFIG1' => $lang['Test_config1'], 'L_TEST_CONFIG2' => $lang['Test_config2'], ! 'L_STARTKIT_GET' => $lang['Startkit_get'], 'L_STARTKIT_GET_EXPLAIN' => $lang['Startkit_get_explain'], 'L_TEST_GET' => $lang['Test_get_par'], ! // // Values --- 171,202 ---- // Pass Block data to template // ! $template->assign_vars( array( // // Titles // 'L_STARTKIT' => $lang['Startkit'], ! 'L_STARTKIT_PARAMETER' => $lang['Startkit_parameter'], 'L_STARTKIT_PARAMETER_EXPLAIN' => $lang['Startkit_parameter_explain'], 'L_TEST_STRING' => $lang['Test_string'], 'L_TEST_NUMBER' => $lang['Test_number'], ! 'L_STARTKIT_PARAMETER_MODIFIED' => $lang['Startkit_parameter_modified'], 'L_STARTKIT_PARAMETER_MODIFIED_EXPLAIN' => $lang['Startkit_parameter_modified_explain'], 'L_TEST_MODIFIED' => $lang['Test_modified'], ! 'L_STARTKIT_PARAMETER_CUSTOM' => $lang['Startkit_parameter_custom'], 'L_STARTKIT_PARAMETER_CUSTOM_EXPLAIN' => $lang['Startkit_parameter_custom_explain'], 'L_TEST_CUSTOM' => $lang['Test_custom'], ! 'L_STARTKIT_CONFIG' => $lang['Startkit_config'], 'L_STARTKIT_CONFIG_EXPLAIN' => $lang['Startkit_config_explain'], 'L_TEST_CONFIG1' => $lang['Test_config1'], 'L_TEST_CONFIG2' => $lang['Test_config2'], ! 'L_STARTKIT_GET' => $lang['Startkit_get'], 'L_STARTKIT_GET_EXPLAIN' => $lang['Startkit_get_explain'], 'L_TEST_GET' => $lang['Test_get_par'], ! // // Values *************** *** 206,220 **** 'TEST_MODIFIED' => $mx_manipulated_test_number, 'TEST_CUSTOM' => $startkit_module_name, ! 'TEST_CONFIG1' => $mx_module_configs['startkit_config1'], ! 'TEST_CONFIG2' => $mx_module_configs['startkit_config2'], ! 'TEST_GET' => $test_get_var )); ! // // Generate Block // ! $template->pparse( 'body' ); ?> \ No newline at end of file --- 206,220 ---- 'TEST_MODIFIED' => $mx_manipulated_test_number, 'TEST_CUSTOM' => $startkit_module_name, ! 'TEST_CONFIG1' => $mx_module_configs['startkit_config1'], ! 'TEST_CONFIG2' => $mx_module_configs['startkit_config2'], ! 'TEST_GET' => $test_get_var )); ! // // Generate Block // ! $template->pparse( 'body' ); ?> \ No newline at end of file |