Jump to content

lyonsperf

Members
  • Content count

    348
  • Joined

  • Last visited

Everything posted by lyonsperf

  1. mobile/includes/header.php <!DOCTYPE html> <head> <?php /*** Begin Header Tags SEO ***/ if ( file_exists(DIR_WS_INCLUDES . 'header_tags.php') ) { require(DIR_WS_INCLUDES . 'header_tags.php'); } else { ?> <meta charset="<?php echo ((CHARSET == 'utf-8')? CHARSET : MOBILE_CHARSET); ?>" /> <?php if (HEADER_TAGS_DISPLAY_PAGE_TOP_TITLE == 'true') { echo '<title>' . $header_tags_array['title'] . '</title>'; } else { echo '<title>' . $headerTitleText = $breadcrumb->_trail[sizeof($breadcrumb->_trail) - 1]['title'] . '</title>'; } } /*** End Header Tags SEO ***/ ?> <meta name="viewport" content="width=320, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" /> <meta name="HandheldFriendly" content="True"> <meta name="MobileOptimized" content="" /> <meta name="apple-mobile-web-app-capable" content="yes" /> <meta name="apple-mobile-web-app-status-bar-style" content="default" /> <?php if (strpos($PHP_SELF,'checkout') || strpos($PHP_SELF,'shopping_cart') || strpos($PHP_SELF,'account') || strpos($PHP_SELF,'log') ) { ?> <meta name="googlebot" content="noindex, nofollow"> <meta name="robots" content="noindex, nofollow"> <?php } ?> <base href="<?php echo (($request_type == 'SSL') ? HTTPS_MOBILE_SERVER . DIR_WS_HTTPS_MOBILE : HTTP_MOBILE_SERVER . DIR_WS_HTTP_MOBILE); ?>" /> <style type="text/css" media="screen"> @[member='import'] "<?php echo (($request_type == 'SSL') ? HTTPS_MOBILE_SERVER . DIR_WS_HTTPS_MOBILE : HTTP_MOBILE_SERVER . DIR_WS_HTTP_MOBILE) . DIR_MOBILE_INCLUDES; ?>mobile_stylesheet.css?<?php echo time()?>"; </style> <!--Include JQM--> <link rel="stylesheet" href="ext/css/theme-<?php echo CSS;?>-min.css?time=<?php echo time()?>" /> <link rel="stylesheet" href="ext/jquery/mobile/jquery.mobile.structure-1.3.2.min.css" /> <link rel="stylesheet" href="ext/css/custom-bar.css" /> <script src="ext/jquery/jquery-1.10.2.min.js"></script> <link rel="stylesheet" type="text/css" href="ext/jquery/fancybox/jquery.fancybox-2.1.5.css"> <script type="text/javascript" src="ext/jquery/fancybox/jquery.fancybox.pack-2.1.5.js"></script> <?php /* Desactivate Ajax for the checkout and catalog_mb pages !*/ if (AJAX_ENABLED != 'true' || substr(basename($PHP_SELF), 0, 8) == 'checkout' || substr(basename($PHP_SELF), 0, 10) == 'catalog_mb' || substr(basename($PHP_SELF), 0, 7) == 'account' || substr(basename($PHP_SELF), 0, 12) == 'address_book' || substr(basename($PHP_SELF), 0, 5) == 'login') echo '<script type="text/javascript"> $(document).bind("mobileinit", function () { $.mobile.ajaxEnabled = false; }); </script>'; ?> <script src="ext/jquery/mobile/jquery.mobile-1.3.2.min.js"></script> <script src="ext/js/jquery.validate.js"></script> </head> <body> <!-- header //--> <div data-role="page" class="ui-page" data-dom-cache="false"> <div id="errorMsg"> <?php if ($messageStack->size('header') > 0) { echo $messageStack->output('header'); } ?> </div> <!-- error msg --> <?php echo '<div data-role="header" class="nav-glyphish-example" data-tap-toggle="false" data-hide-during-focus=""> <div id="headerLogo"><a href="' . tep_mobile_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_HTTP_MOBILE . DIR_MOBILE_IMAGES . 'homepage_02.jpg', STORE_NAME, 0,30) . '</a></div> <div data-role="navbar" class="nav-glyphish-example" data-grid="d" data-hide-during-focus=""> <ul> <li>'.tep_button_jquery( TEXT_HOME, tep_mobile_link(FILENAME_DEFAULT), 'a' , '' , 'id="homes" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_SHOP, tep_mobile_link(FILENAME_CATALOG_MB), 'a' , '' , 'id="boutique" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_ACCOUNT, tep_mobile_link(FILENAME_ACCOUNT, '', 'SSL'), 'a' , '' , 'id="compte" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( IMAGE_BUTTON_SEARCH, tep_mobile_link(FILENAME_SEARCH), 'a' , '' , 'id="search" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_ABOUT, tep_mobile_link(FILENAME_ABOUT), 'a' , '' , 'id="about" data-icon="custom"' ).'</li> </ul> </div> </div>'; ?> <div id="header"> <?php if(sizeof($breadcrumb->_trail) > 0) $headerTitleText = $breadcrumb->_trail[sizeof($breadcrumb->_trail) - 1]['title']; if (isset($HTTP_GET_VARS['error_message']) && tep_not_null($HTTP_GET_VARS['error_message'])) echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['error_message']))); ?> </div> mobile/includes/header_with_htseo.php <?php if(isset($HTTP_GET_VARS['ajax']) == false) { ?> <!DOCTYPE html> <head> <?php /*** Begin Header Tags SEO ***/ if ( file_exists(DIR_WS_INCLUDES . 'header_tags.php') ) { require(DIR_WS_INCLUDES . 'header_tags.php'); } else { ?> <meta charset="<?php echo ((CHARSET == 'utf-8')? CHARSET : MOBILE_CHARSET); ?>" /> <?php if (HEADER_TAGS_DISPLAY_PAGE_TOP_TITLE == 'true') { echo '<title>' . $header_tags_array['title'] . '</title>'; } else { echo '<title>' . $headerTitleText = $breadcrumb->_trail[sizeof($breadcrumb->_trail) - 1]['title'] . '</title>'; } } /*** End Header Tags SEO ***/ ?> <meta name="viewport" content="width=320, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" /> <meta name="apple-mobile-web-app-capable" content="yes" /> <meta name="apple-mobile-web-app-status-bar-style" content="default" /> <?php if (strpos($PHP_SELF,'checkout') || strpos($PHP_SELF,'shopping_cart') || strpos($PHP_SELF,'account') || strpos($PHP_SELF,'log') ) { ?> <meta name="googlebot" content="noindex, nofollow"> <meta name="robots" content="noindex, nofollow"> <?php } ?> <base href="<?php echo (($request_type == 'SSL') ? HTTPS_MOBILE_SERVER . DIR_WS_HTTPS_MOBILE : HTTP_MOBILE_SERVER . DIR_WS_HTTP_MOBILE); ?>" /> <style type="text/css" media="screen"> @[member='import'] "<?php echo (($request_type == 'SSL') ? HTTPS_MOBILE_SERVER . DIR_WS_HTTPS_MOBILE : HTTP_MOBILE_SERVER . DIR_WS_HTTP_MOBILE) . DIR_MOBILE_INCLUDES; ?>mobile_stylesheet.css?<?php echo time()?>"; </style> <!--Include JQM--> <link rel="stylesheet" href="ext/css/theme-<?php echo CSS;?>-min.css?time=<?php echo time()?>" /> <link rel="stylesheet" href="ext/jquery/mobile/jquery.mobile.structure-1.3.2.min.css" /> <link rel="stylesheet" href="ext/css/custom-bar.css" /> <script src="ext/jquery/jquery-1.10.2.min.js"></script> <link rel="stylesheet" type="text/css" href="ext/jquery/fancybox/jquery.fancybox-2.1.5.css"> <script type="text/javascript" src="ext/jquery/fancybox/jquery.fancybox.pack-2.1.5.js"></script> <?php /* Desactivate Ajax for the checkout and catalog_mb pages !*/ if (AJAX_ENABLED != 'true' || substr(basename($PHP_SELF), 0, 8) == 'checkout' || substr(basename($PHP_SELF), 0, 10) == 'catalog_mb' || substr(basename($PHP_SELF), 0, 7) == 'account' || substr(basename($PHP_SELF), 0, 12) == 'address_book') echo '<script type="text/javascript"> $(document).bind("mobileinit", function () { $.mobile.ajaxEnabled = false; }); </script>'; ?> <script src="ext/jquery/mobile/jquery.mobile-1.3.2.min.js"></script> <script src="ext/js/jquery.validate.js"></script> </head> <body> <!-- header //--> <div data-role="page" class="ui-page" data-dom-cache="false"> <div id="errorMsg"> <?php if ($messageStack->size('header') > 0) { echo $messageStack->output('header'); } ?> </div> <!-- error msg --> <?php echo '<div data-role="header" class="nav-glyphish-example" data-tap-toggle="false" data-hide-during-focus=""> <div id="headerLogo"><a href="' . tep_mobile_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_HTTP_MOBILE . DIR_MOBILE_IMAGES . 'homepage_02.jpg', STORE_NAME, 0,30) . '</a></div> <div data-role="navbar" class="nav-glyphish-example" data-grid="d" data-hide-during-focus=""> <ul> <li>'.tep_button_jquery( TEXT_HOME, tep_mobile_link(FILENAME_DEFAULT), 'a' , '' , 'id="homes" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_SHOP, tep_mobile_link(FILENAME_CATALOG_MB), 'a' , '' , 'id="boutique" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_ACCOUNT, tep_mobile_link(FILENAME_ACCOUNT, '', 'SSL'), 'a' , '' , 'id="compte" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( IMAGE_BUTTON_SEARCH, tep_mobile_link(FILENAME_SEARCH), 'a' , '' , 'id="search" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_ABOUT, tep_mobile_link(FILENAME_ABOUT), 'a' , '' , 'id="about" data-icon="custom"' ).'</li> </ul> </div> </div>'; ?> <div id="header"> <?php if(sizeof($breadcrumb->_trail) > 0) $headerTitleText = $breadcrumb->_trail[sizeof($breadcrumb->_trail) - 1]['title']; if (isset($HTTP_GET_VARS['error_message']) && tep_not_null($HTTP_GET_VARS['error_message'])) echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['error_message']))); ?> </div> mobile/includes/header_with_products_htseo.php <!DOCTYPE html> <head> <?php /*** Begin Header Tags SEO ***/ if ( file_exists(DIR_WS_INCLUDES . 'header_tags.php') ) { require(DIR_WS_INCLUDES . 'header_tags.php'); } else { ?> <meta charset="<?php echo ((CHARSET == 'utf-8')? CHARSET : MOBILE_CHARSET); ?>" /> <?php if (HEADER_TAGS_DISPLAY_PAGE_TOP_TITLE == 'true') { echo '<title>' . $header_tags_array['title'] . '</title>'; } else { echo '<title>' . $headerTitleText = $breadcrumb->_trail[sizeof($breadcrumb->_trail) - 1]['title'] . '</title>'; } } /*** End Header Tags SEO ***/ ?> <meta name="viewport" content="width=320, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" /> <meta name="HandheldFriendly" content="True"> <meta name="MobileOptimized" content="" /> <meta name="apple-mobile-web-app-capable" content="yes" /> <meta name="apple-mobile-web-app-status-bar-style" content="default" /> <base href="<?php echo (($request_type == 'SSL') ? HTTPS_MOBILE_SERVER . DIR_WS_HTTPS_MOBILE : HTTP_MOBILE_SERVER . DIR_WS_HTTP_MOBILE); ?>" /> <style type="text/css" media="screen"> @[member='import'] "<?php echo (($request_type == 'SSL') ? HTTPS_MOBILE_SERVER . DIR_WS_HTTPS_MOBILE : HTTP_MOBILE_SERVER . DIR_WS_HTTP_MOBILE) . DIR_MOBILE_INCLUDES; ?>mobile_stylesheet.css?<?php echo time()?>"; </style> <!--Include JQM--> <link rel="stylesheet" href="ext/css/theme-<?php echo CSS;?>-min.css?time=<?php echo time()?>" /> <link rel="stylesheet" href="ext/jquery/mobile/jquery.mobile.structure-1.3.2.min.css" /> <link rel="stylesheet" href="ext/css/custom-bar.css" /> <script src="ext/jquery/jquery-1.10.2.min.js"></script> <link rel="stylesheet" type="text/css" href="ext/jquery/fancybox/jquery.fancybox-2.1.5.css"> <script type="text/javascript" src="ext/jquery/fancybox/jquery.fancybox.pack-2.1.5.js"></script> <?php /* Desactivate Ajax for the checkout and catalog_mb pages !*/ if (AJAX_ENABLED != 'true' || substr(basename($PHP_SELF), 0, 8) == 'checkout' || substr(basename($PHP_SELF), 0, 10) == 'catalog_mb' || substr(basename($PHP_SELF), 0, 7) == 'account' || substr(basename($PHP_SELF), 0, 12) == 'address_book') echo '<script type="text/javascript"> $(document).bind("mobileinit", function () { $.mobile.ajaxEnabled = false; }); </script>'; ?> <script src="ext/jquery/mobile/jquery.mobile-1.3.2.min.js"></script> <script src="ext/js/jquery.validate.js"></script> </head> <body> <!-- header //--> <div data-role="page" class="ui-page" data-dom-cache="false"> <div id="errorMsg"> <?php if ($messageStack->size('header') > 0) { echo $messageStack->output('header'); } ?> </div> <!-- error msg --> <?php echo '<div data-role="header" class="nav-glyphish-example" data-tap-toggle="false" data-hide-during-focus=""> <div id="headerLogo"><a href="' . tep_mobile_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_HTTP_MOBILE . DIR_MOBILE_IMAGES . 'homepage_02.jpg', STORE_NAME, 0,30) . '</a></div> <div data-role="navbar" class="nav-glyphish-example" data-grid="d" data-hide-during-focus=""> <ul> <li>'.tep_button_jquery( TEXT_HOME, tep_mobile_link(FILENAME_DEFAULT), 'a' , '' , 'id="homes" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_SHOP, tep_mobile_link(FILENAME_CATALOG_MB), 'a' , '' , 'id="boutique" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_ACCOUNT, tep_mobile_link(FILENAME_ACCOUNT, '', 'SSL'), 'a' , '' , 'id="compte" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( IMAGE_BUTTON_SEARCH, tep_mobile_link(FILENAME_SEARCH), 'a' , '' , 'id="search" data-icon="custom"' ).'</li> <li>'.tep_button_jquery( TEXT_ABOUT, tep_mobile_link(FILENAME_ABOUT), 'a' , '' , 'id="about" data-icon="custom"' ).'</li> </ul> </div> </div>'; ?> <div id="header"> <?php if(sizeof($breadcrumb->_trail) > 0) $headerTitleText = $breadcrumb->_trail[sizeof($breadcrumb->_trail) - 1]['title']; if (isset($HTTP_GET_VARS['error_message']) && tep_not_null($HTTP_GET_VARS['error_message'])) echo htmlspecialchars(stripslashes(urldecode($HTTP_GET_VARS['error_message']))); ?> </div>
  2. Also, just a suggestion, but a cheatsheet on how and where to change colors, fonts and text alignment would be nice.
  3. Minor issue with my mobile shop www.lyonsperformance.com/mobile The store logo no longer appears at the top of the page. I'm sure this is a minor glitch but if you could direct me on how to fix it I would appreciate it. Thanks! osc 2.2rc2
  4. New version works great! Look forward to future improvements.
  5. Thanks so much for your help. It works great!
  6. OK got the mobile site to work. But when I click on the shopping cart icon for the store I get this message "The page you are looking for can not be found. Return to the main page and try again. " it is http://www.lyonsperformance.com/catalog_mb.php. How do I change the button links to /mobile/?
  7. OK I fixed the error that blanked out my site. The mobile code was added twice in catalog/includes/application_top.php. Now when I activate the mobile site in admin panel and click the mobile link in the footer I get these errors. Warning: include_once(includes/kiss_error_handler.php) [function.include-once]: failed to open stream: No such file or directory in /home/lyons/public_html/includes/application_top.php on line 29 Warning: include_once() [function.include]: Failed opening 'includes/kiss_error_handler.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/lyons/public_html/includes/application_top.php on line 29 Warning: require(includes/local/zz_configure.php) [function.require]: failed to open stream: No such file or directory in /home/lyons/public_html/includes/configure.php on line 53 Warning: require(includes/local/zz_configure.php) [function.require]: failed to open stream: No such file or directory in /home/lyons/public_html/includes/configure.php on line 53 Fatal error: require() [function.require]: Failed opening required 'includes/local/zz_configure.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/lyons/public_html/includes/configure.php on line 53
  8. Should the mobile/includes/application_top.php file have the same require statements as the catalog/includes/application_top.php file? If so, what else needs to be transferred over to the mobile side for this to work?
  9. OK I ran through the instructions and found a few mistakes. It is still throwing the same error.
  10. Here is my config file <?php /* $Id: configure.php 1739 2007-12-20 00:52:16Z hpdl $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright © 2003 osCommerce Released under the GNU General Public License */ // Define the webserver and path parameters // * DIR_FS_* = Filesystem directories (local/physical) // * DIR_WS_* = Webserver directories (virtual/URL) define('HTTP_SERVER', 'http://www.lyonsperformance.com'); // eg, http://localhost - should not be empty for productive servers define('HTTPS_SERVER', 'https://www.lyonsperformance.com'); // eg, https://localhost - should not be empty for productive servers define('ENABLE_SSL', true); // secure webserver for checkout procedure? define('HTTP_COOKIE_DOMAIN', '.lyonsperformance.com'); define('HTTPS_COOKIE_DOMAIN', '.lyonsperformance.com'); define('HTTP_COOKIE_PATH', '/'); define('HTTPS_COOKIE_PATH', '/'); define('DIR_WS_HTTP_CATALOG', '/'); define('DIR_WS_HTTPS_CATALOG', '/'); // define('DIR_WS_IMAGES', 'images/'); define('DIR_WS_MANUALS', 'manuals/'); define('DIR_WS_CATALOG_MANUALS', 'DIR_WS_CATALOG' . 'manuals/'); // define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/'); // define('DIR_WS_INCLUDES', 'includes/'); //BOF Mobile define('HTTP_MOBILE_SERVER', HTTP_SERVER); define('HTTPS_MOBILE_SERVER', HTTPS_SERVER); define('DIR_WS_HTTP_MOBILE', DIR_WS_HTTP_CATALOG . 'mobile/'); define('DIR_WS_HTTPS_MOBILE', DIR_WS_HTTPS_CATALOG . 'mobile/'); (defined('MOBILE_SESSION') ? define('DIR_WS_IMAGES', HTTP_SERVER . DIR_WS_HTTP_CATALOG . 'images/') : define('DIR_WS_IMAGES', 'images/')); define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/'); (defined('MOBILE_SESSION') ? define('DIR_WS_INCLUDES', '../includes/') : define('DIR_WS_INCLUDES', 'includes/')); //EOF Mobile define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); //BOF Mobile define('DIR_MOBILE_IMAGES', 'images/'); define('DIR_MOBILE_INCLUDES','includes/'); define('DIR_MOBILE_MODULES', DIR_MOBILE_INCLUDES . 'modules/'); define('DIR_MOBILE_CLASSES', DIR_MOBILE_INCLUDES . 'classes/'); define('DIR_MOBILE_HEADERS', DIR_MOBILE_INCLUDES . 'headers/'); define('DIR_MOBILE_LANGUAGES', DIR_MOBILE_INCLUDES . 'languages/'); //EOF Mobile // include local zz_configure.php require('includes/local/zz_configure.php'); //BOF Mobile (defined('MOBILE_SESSION') ? define('DIR_WS_DOWNLOAD_PUBLIC', HTTP_SERVER . DIR_WS_HTTP_CATALOG . 'pub/') : define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/')); //EOF Mobile define('DIR_FS_CATALOG', $_SERVER['DOCUMENT_ROOT'] . '/'); //BOF Mobile define('DIR_FS_MOBILE', DIR_FS_CATALOG . 'mobile/'); //EOF Mobile define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); I currently do not have the mobile site activated due to it causing the redirect error and blocking my site from showing.
  11. I posted my redirect file yesterday. Where would I update the device list. I had this working before the upgrade to version 6. So I might have missed something.
  12. Any ideas on how to fix the fatal error I posted for mobile_redirect.php?
  13. Here is the code for the mobile_redirect.php <?php // Le navigateur est-il un Smartphone ? function smartphone() { $smartphone = false; $useragent=$_SERVER['HTTP_USER_AGENT']; //BEGIN detectmobilebrowser 10 june 2013 (copy and paste only line 3 from detectmobilebrowser.php) if(preg_match('/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows (ce|phone)|xda|xiino/i',$useragent)||preg_match('/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i',substr($useragent,0,4))) //END detectmobilebrowser (copy and paste only line 3) { $smartphone = true; } return $smartphone; } class mobileRedirect { var $redirected; var $mobileDir = "mobile/"; function mobileRedirect() { $this->redirected = $this->needRedirect(); if($this->redirected) $this->redirect(); } function needRedirect() { if($this->isCancelled()) return false; if(strpos($_SERVER['SCRIPT_NAME'],$this->mobileDir . $this->mobileFile) > 0) return false; if(smartphone() == true) return true; return false; } function isCancelled() { if (tep_session_is_registered('redirectCancelled')) return true; if(isset($_GET['redirectCancelled']) && $_GET['redirectCancelled'] == 'true') { tep_session_register('redirectCancelled'); return true; } return false; } function redirect() { global $mobile_url; tep_redirect($mobile_url); } } ?>
  14. I'm getting this error Fatal error: Cannot redeclare smartphone() (previously declared in /home/lyons/public_html/mobile/includes/classes/mobile_redirect.php:5) in /home/lyons/public_html/mobile/includes/classes/mobile_redirect.php on line 14 After upgrading my 2.2 install. Any ideas?
  15. lyonsperf

    Multi_Vendor_Shipping new thread

    edited
  16. lyonsperf

    USPS Rate V4, Intl Rate V2 (official support thread)

    Sorry, MVS is Multiple Vendor Shipping its a addon for stores that dropship directly from the supplier or from other locations other than the main store address.
  17. lyonsperf

    USPS Rate V4, Intl Rate V2 (official support thread)

    This is going to be a real mess to convert for the MVS users. I am trying to work on a version but the code is so much different from the last rendition. Any suggestions would be much appreciated.
  18. Has anyone ported Additional Images Mod and/or MVS for this contribution?
  19. Google is bouncing my product feeds for a missing value "google product category". Where can I add this in the googlefeed file so that it will list it with each product? Being that my sites are all of the same product category, I would only need it to repeat for each product.
  20. lyonsperf

    Article Manager v1.0

    HI Jack, I have been using this mod sucessfully for a while. I just added a new article that is several pages long but when viewed through my site it is truncated to the first page of the article. Is there a field I need to change to extend the viewable length?
  21. lyonsperf

    Multi_Vendor_Shipping new thread

    OK, after many winmerge compares of different free shipping mods and not finding a single difference, I finally found the answer. If you enable free shipping in your admin panel/vendor section you must also go into admin panel-Modules-Order Total-Shipping, then click edit for the shipping line and change allow free shipping from true to false. This then allows the new MVS free shipping mod to enable! Three days of work for one simple change! Hope this helps someone else!
  22. lyonsperf

    Multi_Vendor_Shipping new thread

    I need it to offer free shipping after a minimum is reached.
  23. lyonsperf

    Multi_Vendor_Shipping new thread

    Here's the code I have <?php /* $Id$ freeamount.php 2 Modified for MVS_1.2.3 2010/03/03 Motorcity Modified for MVS V1.0 2006/03/25 JCK/CWG osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2006 osCommerce Released under the GNU General Public License ---------------------------------------------- ane - 06/02/02 - modified freecount.php to allow for freeshipping on minimum order amount originally written by dwatkins 1/24/02 Modified BearHappy 09/04/04 ---------------------------------------------- */ class freeamount { var $code, $title, $description, $icon, $enabled; // class constructor function freeamount() { global $order, $vendors_id; $this->code = 'freeamount'; $this->title = MODULE_SHIPPING_FREEAMOUNT_TEXT_TITLE; $this->description = MODULE_SHIPPING_FREEAMOUNT_TEXT_DESCRIPTION; $this->icon =''; $this->delivery_country_id = $order->delivery['country']['id']; $this->delivery_zone_id = $order->delivery['zone_id']; } //MVS start function sort_order($vendors_id = '1') { if (defined(@ constant('MODULE_SHIPPING_FREEAMOUNT_SORT_ORDER_' . $vendors_id))) { $this->sort_order = @ constant('MODULE_SHIPPING_FREEAMOUNT_SORT_ORDER_' . $vendors_id); } else { $this->sort_order = '-'; } return $this->sort_order; } function tax_class($vendors_id='1') { $this->tax_class = constant('MODULE_SHIPPING_FREEAMOUNT_TAX_CLASS_' . $vendors_id); return $this->tax_class; } function enabled($vendors_id='1') { $this->enabled = false; $status = @ constant('MODULE_SHIPPING_FREEAMOUNT_STATUS_' . $vendors_id); if (isset ($status) && $status != '') { $this->enabled = (($status == 'True') ? true : false); } if (($this->enabled == true) && ((int) constant('MODULE_SHIPPING_FREEAMOUNT_ZONE_' . $vendors_id) > 0)) { $check_flag = false; $check_query = tep_db_query("select zone_id from " . TABLE_ZONES_TO_GEO_ZONES . " where geo_zone_id = '" . (int) constant('MODULE_SHIPPING_FREEAMOUNT_ZONE_' . $vendors_id) . "' and zone_country_id = '" . $this->delivery_country_id . "' order by zone_id"); while ($check = tep_db_fetch_array($check_query)) { if ($check['zone_id'] < 1) { $check_flag = true; break; } elseif ($check['zone_id'] == $this->delivery_zone_id) { $check_flag = true; break; } } if ($check_flag == false) { $this->enabled = false; } //if } //if return $this->enabled; } function zones($vendors_id = '1') { if (($this->enabled == true) && ((int) constant('MODULE_SHIPPING_FREEAMOUNT_ZONE_' . $vendors_id) > 0)) { $check_flag = false; $check_query = tep_db_query("select zone_id from " . TABLE_ZONES_TO_GEO_ZONES . " where geo_zone_id = '" . (int) constant('MODULE_SHIPPING_FREEAMOUNT_ZONE_' . $vendors_id) . "' and zone_country_id = '" . $order->delivery['country']['id'] . "' order by zone_id"); while ($check = tep_db_fetch_array($check_query)) { if ($check['zone_id'] < 1) { $check_flag = true; break; } elseif ($check['zone_id'] == $order->delivery['zone_id']) { $check_flag = true; break; } //if } //while if ($check_flag == false) { $this->enabled = false; } //if } //if return $this->enabled; } //function //MVS End // class methods function quote($method = '', $module = '', $vendors_id = '1') { global $_POST, $order, $cart, $total_count, $shipping_weight, $shipping_num_boxes; //MVS Start $vendors_data_query = tep_db_query("select handling_charge, handling_per_box, vendor_country, vendors_zipcode from " . TABLE_VENDORS . " where vendors_id = '" . (int) $vendors_id . "'"); $vendors_data = tep_db_fetch_array($vendors_data_query); $country_name = tep_get_countries($vendors_data['vendor_country'], true); $get_total = false; $get_weight = false; $handling_charge = $vendors_data['handling_charge']; $handling_per_box = $vendors_data['handling_per_box']; if ($handling_charge > $handling_per_box * $shipping_num_boxes) { $handling = $handling_charge; } else { $handling = $handling_per_box * $shipping_num_boxes; } $shipping = @[member='constant']('MODULE_SHIPPING_FREEAMOUNT_COST_' . $vendors_id) + $handling; //MVS End if ($shipping_weight > @[member='constant']('MODULE_SHIPPING_FREEAMOUNT_WEIGHT_MAX_' . $vendors_id)) { if (@[member='constant']('MODULE_SHIPPING_FREEAMOUNT_DISPLAY_' . $vendors_id) == 'False') return; // This next line might be used by some sites, but most wouldn't want it by default. // $this->quotes['error'] = MODULE_SHIPPING_FREEAMOUNT_TEXT_TOO_HEAVY . ' (' . $shipping_weight . ') ' . MODULE_SHIPPING_FREEAMOUNT_TEXT_UNIT; $get_weight = false; } else { $get_weight = true; } if ($cart->show_total() < @[member='constant']('MODULE_SHIPPING_FREEAMOUNT_AMOUNT_' . $vendors_id)) { if (@[member='constant']('MODULE_SHIPPING_FREEAMOUNT_DISPLAY_' . $vendors_id) == 'False') return; $this->quotes['error'] = MODULE_SHIPPING_FREEAMOUNT_TEXT_ERROR . ' (' . @[member='constant']('MODULE_SHIPPING_FREEAMOUNT_AMOUNT_' . $vendors_id) . ') '; $get_total = false; } else { $get_total = true; if (($get_total == true && $get_weight == true)) { $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_FREEAMOUNT_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => MODULE_SHIPPING_FREEAMOUNT_TEXT_WAY, 'cost' => $shipping))); } } if ($this->tax_class($vendors_id) > 0) { $this->quotes['tax'] = tep_get_tax_rate($this->tax_class($vendors_id), $order->delivery['country']['id'], $order->delivery['zone_id']); } if (tep_not_null($this->icon)) $this->quotes['icon'] = tep_image($this->icon, $this->title); return $this->quotes; } function check($vendors_id = '1') { if (!isset ($this->_check)) { $check_query = tep_db_query("select configuration_value from " . TABLE_VENDOR_CONFIGURATION . " where configuration_key = 'MODULE_SHIPPING_FREEAMOUNT_STATUS_" . $vendors_id . "'"); $this->_check = tep_db_num_rows($check_query); } return $this->_check; } function install($vendors_id = '1') { tep_db_query("insert into " . TABLE_VENDOR_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added, vendors_id) values ('Enable Free Shipping with Minimum Purchase', 'MODULE_SHIPPING_FREEAMOUNT_STATUS_" . $vendors_id . "', 'True', 'Do you want to offer minimum order free shipping?', '6', '7', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now(), '" . $vendors_id . "')"); tep_db_query("insert into " . TABLE_VENDOR_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added, vendors_id) values ('Maximum Weight', 'MODULE_SHIPPING_FREEAMOUNT_WEIGHT_MAX_" . $vendors_id . "', '10', 'What is the maximum weight you will ship?', '6', '8', now(), '" . $vendors_id . "')"); tep_db_query("insert into " . TABLE_VENDOR_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added, vendors_id) values ('Enable Display', 'MODULE_SHIPPING_FREEAMOUNT_DISPLAY_" . $vendors_id . "', 'True', 'Do you want to display text way if the minimum amount is not reached?', '6', '7', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now(), '" . $vendors_id . "')"); tep_db_query("insert into " . TABLE_VENDOR_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added, vendors_id) values ('Minimum Cost', 'MODULE_SHIPPING_FREEAMOUNT_AMOUNT_" . $vendors_id . "', '50.00', 'Minimum order amount purchased before shipping is free?', '6', '8', now(), '" . $vendors_id . "')"); tep_db_query("insert into " . TABLE_VENDOR_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added, vendors_id) values ('Sort Order', 'MODULE_SHIPPING_FREEAMOUNT_SORT_ORDER_" . $vendors_id . "', '0', 'Sort order of display.', '6', '0', now(), '" . $vendors_id . "')"); tep_db_query("insert into " . TABLE_VENDOR_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added, vendors_id) values ('Tax Class', 'MODULE_SHIPPING_FREEAMOUNT_TAX_CLASS_" . $vendors_id . "', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'tep_get_tax_class_title', 'tep_cfg_pull_down_tax_classes(', now(), '" . $vendors_id . "')"); tep_db_query("insert into " . TABLE_VENDOR_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added, vendors_id) values ('Shipping Zone', 'MODULE_SHIPPING_FREEAMOUNT_ZONE_" . $vendors_id . "', '0', 'If a zone is selected, only enable this shipping method for that zone.', '6', '0', 'tep_get_zone_class_title', 'tep_cfg_pull_down_zone_classes(', now(), '" . $vendors_id . "')"); } function remove($vendors_id) { tep_db_query("delete from " . TABLE_VENDOR_CONFIGURATION . " where configuration_key in ('" . implode("', '", $this->keys($vendors_id)) . "')"); } function keys($vendors_id) { return array ( 'MODULE_SHIPPING_FREEAMOUNT_STATUS_' . $vendors_id, 'MODULE_SHIPPING_FREEAMOUNT_WEIGHT_MAX_' . $vendors_id, 'MODULE_SHIPPING_FREEAMOUNT_SORT_ORDER_' . $vendors_id, 'MODULE_SHIPPING_FREEAMOUNT_DISPLAY_' . $vendors_id, 'MODULE_SHIPPING_FREEAMOUNT_TAX_CLASS_' . $vendors_id, 'MODULE_SHIPPING_FREEAMOUNT_AMOUNT_' . $vendors_id, 'MODULE_SHIPPING_FREEAMOUNT_ZONE_' . $vendors_id ); } } ?>
  24. lyonsperf

    Multi_Vendor_Shipping new thread

    Works fine for flat rate.
  25. lyonsperf

    Multi_Vendor_Shipping new thread

    Thanks Jim that worked great! Heres another for you. I activated the free shipping module in mvs and it works fine until the customer gets to the checkout shipping page. The system is looking for the customer to select the shipping method for the order, which would be free shipping when the order is over the minimum. But there is no button or box for the customer to select. If you click continue the page reloads with a warning to please select a shipping method. Any ideas? Thanks Matt
×