This is a discussion on Determine Version within the osCMax v2 Installation issues forums, part of the osCMax v2.0 Forums category; Any typos in following are because I am panicing.I got thrown into something that I may regret soon. Yesterday I ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#1
| |||
| |||
| Any typos in following are because I am panicing.I got thrown into something that I may regret soon. Yesterday I got a call that their oScommerce site had stopped working. They haven't upgraded in 2 years and the developer is nowhere to be found. I discovered that the ISP (Hostcentric) upgraded the site to mySQL5 and PHP 5.. I have gone through many of the instruction to upgrade, and got rid of some of the errors. I notice that my advanced_search_result.php does not look at all like anything out there, I will include it's code after questions. 1. How do I determine what is my version of software? 2. After I determine software version: a. Should I had edit code to make compatible? b. Is there a good upgrade path? c. Would it be best to go to a server with older PHP and mySQL If so, where are concise instructions for moving See attached code Code: <?php
/*
$Id: advanced_search_result.php,v 1.1.1.1 2005/01/15 06:43:44 Michael Sasek Exp $
osCommerce, Open Source E-Commerce Solutions
http://www.oscommerce.com
Copyright (c) 2003 osCommerce
Released under the GNU General Public License
*/
require('includes/application_top.php');
require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_ADVANCED_SEARCH);
$error = false;
if ( (isset($HTTP_GET_VARS['keywords']) && empty($HTTP_GET_VARS['keywords'])) &&
(isset($HTTP_GET_VARS['dfrom']) && (empty($HTTP_GET_VARS['dfrom']) || ($HTTP_GET_VARS['dfrom'] == DOB_FORMAT_STRING))) &&
(isset($HTTP_GET_VARS['dto']) && (empty($HTTP_GET_VARS['dto']) || ($HTTP_GET_VARS['dto'] == DOB_FORMAT_STRING))) &&
(isset($HTTP_GET_VARS['pfrom']) && !is_numeric($HTTP_GET_VARS['pfrom'])) &&
(isset($HTTP_GET_VARS['pto']) && !is_numeric($HTTP_GET_VARS['pto'])) ) {
$error = true;
$messageStack->add_session('search', ERROR_AT_LEAST_ONE_INPUT);
} else {
$dfrom = '';
$dto = '';
$pfrom = '';
$pto = '';
$keywords = '';
if (isset($HTTP_GET_VARS['dfrom'])) {
$dfrom = (($HTTP_GET_VARS['dfrom'] == DOB_FORMAT_STRING) ? '' : $HTTP_GET_VARS['dfrom']);
}
if (isset($HTTP_GET_VARS['dto'])) {
$dto = (($HTTP_GET_VARS['dto'] == DOB_FORMAT_STRING) ? '' : $HTTP_GET_VARS['dto']);
}
if (isset($HTTP_GET_VARS['pfrom'])) {
$pfrom = $HTTP_GET_VARS['pfrom'];
}
if (isset($HTTP_GET_VARS['pto'])) {
$pto = $HTTP_GET_VARS['pto'];
}
if (isset($HTTP_GET_VARS['keywords'])) {
$keywords = $HTTP_GET_VARS['keywords'];
}
$date_check_error = false;
if (tep_not_null($dfrom)) {
if (!tep_checkdate($dfrom, DOB_FORMAT_STRING, $dfrom_array)) {
$error = true;
$date_check_error = true;
$messageStack->add_session('search', ERROR_INVALID_FROM_DATE);
}
}
if (tep_not_null($dto)) {
if (!tep_checkdate($dto, DOB_FORMAT_STRING, $dto_array)) {
$error = true;
$date_check_error = true;
$messageStack->add_session('search', ERROR_INVALID_TO_DATE);
}
}
if (($date_check_error == false) && tep_not_null($dfrom) && tep_not_null($dto)) {
if (mktime(0, 0, 0, $dfrom_array[1], $dfrom_array[2], $dfrom_array[0]) > mktime(0, 0, 0, $dto_array[1], $dto_array[2], $dto_array[0])) {
$error = true;
$messageStack->add_session('search', ERROR_TO_DATE_LESS_THAN_FROM_DATE);
}
}
$price_check_error = false;
if (tep_not_null($pfrom)) {
if (!settype($pfrom, 'double')) {
$error = true;
$price_check_error = true;
$messageStack->add_session('search', ERROR_PRICE_FROM_MUST_BE_NUM);
}
}
if (tep_not_null($pto)) {
if (!settype($pto, 'double')) {
$error = true;
$price_check_error = true;
$messageStack->add_session('search', ERROR_PRICE_TO_MUST_BE_NUM);
}
}
if (($price_check_error == false) && is_float($pfrom) && is_float($pto)) {
if ($pfrom >= $pto) {
$error = true;
$messageStack->add_session('search', ERROR_PRICE_TO_LESS_THAN_PRICE_FROM);
}
}
if (tep_not_null($keywords)) {
if (!tep_parse_search_string($keywords, $search_keywords)) {
$error = true;
$messageStack->add_session('search', ERROR_INVALID_KEYWORDS);
}
}
}
if (empty($dfrom) && empty($dto) && empty($pfrom) && empty($pto) && empty($keywords)) {
$error = true;
$messageStack->add_session('search', ERROR_AT_LEAST_ONE_INPUT);
}
if ($error == true) {
tep_redirect(tep_href_link(FILENAME_ADVANCED_SEARCH, tep_get_all_get_params(), 'NONSSL', true, false));
}
$breadcrumb->add(NAVBAR_TITLE_1, tep_href_link(FILENAME_ADVANCED_SEARCH));
$breadcrumb->add(NAVBAR_TITLE_2, tep_href_link(FILENAME_ADVANCED_SEARCH_RESULT, tep_get_all_get_params(), 'NONSSL', true, false));
$content = CONTENT_ADVANCED_SEARCH_RESULT;
require(DIR_WS_TEMPLATES . TEMPLATENAME_MAIN_PAGE);
require(DIR_WS_INCLUDES . 'application_bottom.php');
?>
|
| Sponsored Links | ||
| ||
|
#2
| ||||
| ||||
| To determine the version, look in english.php and there should be a version line. If it is still set to osCommerce 2.2, and no indication of osCMax, it is v1.7 or earlier. Could be 1.5.5. Version tracking was not very good back in those days, as it was still just a backwater project. If you are using a more recent version, it will be posted in english.php and also displayed when you login to the admin panel. 2. You will have to hand edit code to update versions 1.7 and earlier, as all development on them stopped long ago. There are no patches for them. osCMax 2 upgrades from earlier versions are manual code edits, especially if you dont know the pedigree of the code for your particular shop (could have been customized). Yes, the easiest solution would be to keep your old cart on a server that it is compatible with (php4 and mysql 4.0x) until you can get a grasp on the entire situation. It may be that you just install a new v2.0 cart and migrate the data and design to it. Instructions to move: 1. Dump the database to a sql batch file and recreate it on the new server. 2. Tar the entire catalog directory and subdirectories. Un - tar the entire lot to the new server's web accessable directory. 3. Manually edit includes/configure.php and admin/includes/configure.php to match the path and url information to the new server's path settings. 4. test.
__________________ Michael Sasek osCMax Developer
|
| Sponsored Links | ||
| ||
| Thread Tools | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Unable to determine the page link! | sunspeks | osCMax v2 Installation issues | 2 | 07-27-2005 08:20 AM |
| Unable to determine page link! | brownfox | osCommerce 2.2 Modification Help | 2 | 12-07-2004 05:34 AM |
| Error! Unable to determine the page link! | simonharkin | osCommerce 2.2 Installation Help | 1 | 10-23-2004 08:11 AM |
| Unable to determine the page link! | leob | osCommerce 2.2 Installation Help | 1 | 11-22-2002 06:45 PM |