niganit Posted September 16, 2009 Posted September 16, 2009 So now I get this error: Parse error: syntax error, unexpected '/' in /home/niganit2/menswork.org/catalog/includes/application_top.php on line 38 Here's my code (not the entire file) // Register Globals Disable Contribution Added 15 SEP 2009 by Rich Wersinger to be compatible with DreamHost PHP5 upgrade - http://www.magic-seo-url.com // Register Globals MOD - http://www.magic-seo-url.com if (version_compare(phpversion(), "4.1.0", "<") === true) { $_GET &= $HTTP_GET_VARS; $_POST &= $HTTP_POST_VARS; $_SERVER &= $HTTP_SERVER_VARS; $_FILES &= $HTTP_POST_FILES; $_ENV &= $HTTP_ENV_VARS; if (isset($HTTP_COOKIE_VARS)) $_COOKIE &= $HTTP_COOKIE_VARS; } if (!ini_get("register_globals")) { extract($_GET, EXTR_SKIP); extract($_POST, EXTR_SKIP); extract($_COOKIE, EXTR_SKIP); } // start the timer for the page parse time log define('PAGE_PARSE_START_TIME', microtime()); // set the level of error reporting error_reporting(E_ALL & ~E_NOTICE); / Check if register_globals is enabled. // Since this is a temporary measure this message is hardcoded. The requirement will be removed before 2.2 is finalized. // /*if (function_exists('ini_get')) { // Register Globals MOD - http://www.magic-seo-url.com - Rich Wersinger 16 SEP 2009 // ini_get('register_globals') or exit('Server Requirement Error: register_globals is disabled in your PHP configuration. This can be enabled in your php.ini configuration file or in the .htaccess file in your catalog directory.'); // }*/ // Set the local configuration parameters - mainly for developers if (file_exists('includes/local/configure.php')) include('includes/local/configure.php'); // include server parameters require('includes/configure.php'); if (strlen(DB_SERVER) < 1) { if (is_dir('install')) { header('Location: install/index.php'); } } // define the project version define('PROJECT_VERSION', 'osCommerce 2.2-MS2'); // set the type of request (secure or not) $request_type = (getenv('HTTPS') == 'on') ? 'SSL' : 'NONSSL'; // set php_self in the local scope if (!isset($PHP_SELF)) $PHP_SELF = $HTTP_SERVER_VARS['PHP_SELF']; if ($request_type == 'NONSSL') { define('DIR_WS_CATALOG', DIR_WS_HTTP_CATALOG); } else { define('DIR_WS_CATALOG', DIR_WS_HTTPS_CATALOG); } // include the list of project filenames require(DIR_WS_INCLUDES . 'filenames.php'); // include the list of project database tables require(DIR_WS_INCLUDES . 'database_tables.php'); // customization for the design layout define('BOX_WIDTH', 125); // how wide the boxes should be in pixels (default: 125) // include the database functions require(DIR_WS_FUNCTIONS . 'database.php'); // make a connection to the database... now tep_db_connect() or die('Unable to connect to database server!'); // set the application parameters $configuration_query = tep_db_query('select configuration_key as cfgKey, configuration_value as cfgValue from ' . TABLE_CONFIGURATION); while ($configuration = tep_db_fetch_array($configuration_query)) { define($configuration['cfgKey'], $configuration['cfgValue']); } // if gzip_compression is enabled, start to buffer the output if ( (GZIP_COMPRESSION == 'true') && ($ext_zlib_loaded = extension_loaded('zlib')) && (PHP_VERSION >= '4') ) { if (($ini_zlib_output_compression = (int)ini_get('zlib.output_compression')) < 1) { if (PHP_VERSION >= '4.0.4') { ob_start('ob_gzhandler'); } else { include(DIR_WS_FUNCTIONS . 'gzip_compression.php'); ob_start(); ob_implicit_flush(); } } else { ini_set('zlib.output_compression_level', GZIP_LEVEL); } } // set the HTTP GET parameters manually if search_engine_friendly_urls is enabled if (SEARCH_ENGINE_FRIENDLY_URLS == 'true') { if (strlen(getenv('PATH_INFO')) > 1) { $GET_array = array(); $PHP_SELF = str_replace(getenv('PATH_INFO'), '', $PHP_SELF); $vars = explode('/', substr(getenv('PATH_INFO'), 1)); for ($i=0, $n=sizeof($vars); $i<$n; $i++) { if (strpos($vars[$i], '[]')) { $GET_array[substr($vars[$i], 0, -2)][] = $vars[$i+1]; } else { $HTTP_GET_VARS[$vars[$i]] = $vars[$i+1]; } $i++; } if (sizeof($GET_array) > 0) { while (list($key, $value) = each($GET_array)) { $HTTP_GET_VARS[$key] = $value; } } } } Can anyone point me in a direction? Thanks and cheers, Rich
FIMBLE Posted September 16, 2009 Posted September 16, 2009 this / Check if register_globals is enabled. should be // Check if register_globals is enabled. Nic Sometimes you're the dog and sometimes the lamp post [/url] My Contributions
niganit Posted September 16, 2009 Author Posted September 16, 2009 this / Check if register_globals is enabled. should be // Check if register_globals is enabled. Nic Thanks so much. Another set of expert eyes finds a newbies mis-typing! :-) That was so helpful. Now I can go onto figuring out why my products are not appearing! See: http://www.menswork.org/catalog/product_in...;products_id=28 Cheers, Rich
FIMBLE Posted September 16, 2009 Posted September 16, 2009 You have the following error Error! Unable to determine the page link! here is a link to help you http://www.oscommerce.com/forums/index.php?sho...t=0&start=0 Nic Sometimes you're the dog and sometimes the lamp post [/url] My Contributions
Guest Posted September 16, 2009 Posted September 16, 2009 post deleted by author. Nic is a smart guy ... go with what he says.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.