bigbird_3156 Posted February 5, 2014 Posted February 5, 2014 Hi, I'm just catching up on some upgrades (my site is not live as I'm slowly customising and learning) and upgraded from 2.3.3.2 to 2.3.3.3 But after doing the upgrade I got this error.... Error! Unable to determine connection method on a link! Known methods: NONSSL SSL I assume it is because I do not have SSL yet (that will come closer to when I am ready to go live) if this is the problem, is there some way to get around it until I do have my Certificate?? If this is not the problem, does anyone have a clue where I went wrong ? Basically my Catalog index page shows my header and breadcrumb, but then gives me the above error, and I cannot access my admin at all... Firefox tells me the page is not redirecting properly.
Guest Posted February 5, 2014 Posted February 5, 2014 @@bigbird_3156 If you do not have SSL enabled in the two configure.php files you should not be trying to access the site using https:// (once you purchase an SSL, you can enable the SSL in osCommerce) Chris
bigbird_3156 Posted February 5, 2014 Author Posted February 5, 2014 Thx Chris, However both configure.php have Enable SSL set to false, Also (As far as I'm aware I'm only accessing the site through http:// - (unless there is code that references https://)
bigbird_3156 Posted February 5, 2014 Author Posted February 5, 2014 the error shows where the left column would normally load
bigbird_3156 Posted February 5, 2014 Author Posted February 5, 2014 ok the error seems to stem from the upgrade in includes/modules/boxes/bm_search.php from; ' ' . tep_draw_form('quick_find', tep_href_link(FILENAME_ADVANCED_SEARCH_RESULT, '', 'NONSSL', false), 'get') . to ' ' . tep_draw_form('quick_find', tep_href_link(FILENAME_ADVANCED_SEARCH_RESULT, '', $request_type,false), 'get') . can anyone shed any light on what is going wrong??
burt Posted February 5, 2014 Posted February 5, 2014 Did you make $request_type global ? includes/modules/boxes/bm_search.php - line 34(ish)
MrPhil Posted February 5, 2014 Posted February 5, 2014 Yeah, $request_type should resolve to either 'SSL' or 'NONSSL'. Yours is probably unset or blank or empty or null. Failing to global it near the top of a function can cause that problem.
bigbird_3156 Posted February 6, 2014 Author Posted February 6, 2014 I think that is set... function execute() { global $request_type, $oscTemplate; $oscTemplate->addBlock($this->boxData(), $this->group); } so that is not the problem
MrPhil Posted February 6, 2014 Posted February 6, 2014 it should be set by application_top.php, unless you have some sort of odd server setup. The code checks the HTTPS environment variable for 'on', though on some servers it's '1'. However, in that case it would always be 'NONSSL'. I trust that line was removed or something? Did someone add an @ to the getenv to suppress error messages? Finally, you can try echoing out $request_type at several points to see if it exists and has the expected value.
bigbird_3156 Posted February 6, 2014 Author Posted February 6, 2014 Is this possibly related to my other problem of not being to log into the admin section.... I played around with the application_top.php file and commented out the following section of code that then let me log into admin... but I have previously not modified this file in either of the last two updates... there is obviously something going wrong somewhere I just dont know where... // if the first page request is to the login page, set the current page to the index page // so the redirection on a successful login is not made to the login page again // if ( ($current_page == FILENAME_LOGIN) && !tep_session_is_registered('redirect_origin') ) { // $current_page = FILENAME_DEFAULT; // $HTTP_GET_VARS = array(); // } // if ($current_page != FILENAME_LOGIN) { // if (!tep_session_is_registered('redirect_origin')) { // tep_session_register('redirect_origin'); // $redirect_origin = array('page' => $current_page, // 'get' => $HTTP_GET_VARS); // } // try to automatically login with the HTTP Authentication values if it exists // if (!tep_session_is_registered('auth_ignore')) { // if (isset($HTTP_SERVER_VARS['PHP_AUTH_USER']) && !empty($HTTP_SERVER_VARS['PHP_AUTH_USER']) && isset($HTTP_SERVER_VARS['PHP_AUTH_PW']) && !empty($HTTP_SERVER_VARS['PHP_AUTH_PW'])) { // $redirect_origin['auth_user'] = $HTTP_SERVER_VARS['PHP_AUTH_USER']; // $redirect_origin['auth_pw'] = $HTTP_SERVER_VARS['PHP_AUTH_PW']; // } // } // $redirect = true; // } // if (!isset($login_request) || isset($HTTP_GET_VARS['login_request']) || isset($HTTP_POST_VARS['login_request']) || isset($HTTP_COOKIE_VARS['login_request']) || isset($HTTP_SESSION_VARS['login_request']) || isset($HTTP_POST_FILES['login_request']) || isset($HTTP_SERVER_VARS['login_request'])) { // $redirect = true; // } // if ($redirect == true) { // tep_redirect(tep_href_link(FILENAME_LOGIN, (isset($redirect_origin['auth_user']) ? 'action=process' : ''))); // } // unset($redirect); }
bigbird_3156 Posted February 11, 2014 Author Posted February 11, 2014 ok... Ive narrowed the problem down to my includes/header.php file, which I have changed around a fair bit, but I cant work out why it is causing problems... (If I change this file around to an unmodified one it works, but when I put this one back it does not work)... Can someone have a look and see if they can detect the problem... I must admit I'm not up to this level with my coding yet... <?php /* $Id$ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2010 osCommerce Released under the GNU General Public License */ if ($messageStack->size('header') > 0) { echo '<div class="grid_24">' . $messageStack->output('header') . '</div>'; } ?> <div class="grid_24" > <div class="grid_12 alpha"> <?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'store_logo.png', STORE_NAME) . '</a>'; ?> </div> <div class="grid_126 omega headboxholder ui-corner-all"> <div class="grid_6 alpha"> <?php echo tep_header_greeting(); ?> </div> <div class="grid_6 omega"> <div class="grid_1 alpha"> <?php if ($cart->count_contents() == 0) { echo tep_image(DIR_WS_ICONS . 'bagwhite.png'); } else { echo tep_image(DIR_WS_ICONS . 'baggreen.png'); } ?> </div> <div class="grid_5 omega"> <p><?php echo HEADER_CART_ITEMS . $cart->count_contents(); ?><?php echo' · '; ?> <?php echo HEADER_CART_TOTAL . $currencies->format($cart->show_total()); ?> <?php if ($cart->count_contents() > 0) { echo '<br> <a href="' . tep_href_link(FILENAME_VIEW_CART, '', 'SSL') . '">' . HEADER_VIEW_CART . '</a>'; echo ' · <a href="' . tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL') . '">' . HEADER_CART_CHECKOUT . '</a></p>'; } ?> </p> </div> </div> </div> </div> <div class="grid_24 ribbon ui-corner-bottom ui-corner-top"> <div class="grid_18 push_6 alpha"> <div class="head_breadcrumb"><?php echo ' ' . $breadcrumb->trail(' » '); ?></div> </div> <div class="grid_6 pull_18 omega"> <?php if (class_exists(bm_search)) { $boxdata = new bm_search; echo $boxdata->boxData(); } ?> </div> </div> <?php if (isset($HTTP_GET_VARS['error_message']) && tep_not_null($HTTP_GET_VARS['error_message'])) { ?> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr class="headerError"> <td class="headerError"><?php echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['error_message']))); ?></td> </tr> </table> <?php } if (isset($HTTP_GET_VARS['info_message']) && tep_not_null($HTTP_GET_VARS['info_message'])) { ?> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr class="headerInfo"> <td class="headerInfo"><?php echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['info_message']))); ?></td> </tr> </table> <?php } ?>
tgely Posted February 18, 2014 Posted February 18, 2014 I dont see anything, but maybe in your language constant could be contain bad links or $boxdata class return when echo called. osCommerce based shop owner with minimal design and focused on background works. When the less is more.Email managment with tracking pixel, package managment for shipping, stock management, warehouse managment with bar code reader, parcel shops management on 3000 pickup points without local store.
Oooooooo Posted January 23, 2015 Posted January 23, 2015 I have the same problem too. Is there any solution now? Thanks.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.