Jump to content

raiwa

♥Ambassador
  • Content count

    4,200
  • Joined

  • Last visited

  • Days Won

    138

Posts posted by raiwa


  1. pretty much what i'm noticing is once a redirect occurs - say product to mobile product - the links in the also purchased module are sometimes correct, and sometimes opposite.

    Site is here

     

    @@Roaddoctor

    Working on the 6.0 update I found the reason for the also purchased modules link problem:

     

    It's the cache option.

     

    When "use cache" is set to "true" in "Admin-cache" the also purchased module is cached, so if you visit first the desktop page and then the mobile page it shows the cached desktop content.

     

    Here the fix:

     

    In: catalog/includes/functions/cache.php

     

    add this at the end before the closing ?>: (this is a duplicated and renamed "tep_cache_also_purchased" function)

     

    ////
    //! Cache the mobile also purchased module
    // Cache the mobile also purchased module
    function tep_cache_mobile_also_purchased($auto_expire = false, $refresh = false) {
    global $HTTP_GET_VARS, $language, $languages_id;
    $cache_output = '';
    if (isset($HTTP_GET_VARS['products_id']) && is_numeric($HTTP_GET_VARS['products_id'])) {
     if (($refresh == true) || !read_cache($cache_output, 'also_purchased-' . $language . '.cache' . $HTTP_GET_VARS['products_id'], $auto_expire)) {
     ob_start();
     include(DIR_MOBILE_MODULES . FILENAME_ALSO_PURCHASED_PRODUCTS);
     $cache_output = ob_get_contents();
     ob_end_clean();
     write_cache($cache_output, 'mobile_also_purchased-' . $language . '.cache' . $HTTP_GET_VARS['products_id']);
     }
    }
    return $cache_output;
    }
    

     

    In: mobile_product_info.php

    find:

     

    if (tep_not_null(tep_cache_also_purchased(3600))) {
    echo tep_cache_also_purchased(3600);
    

     

    and replace with:

    if (tep_not_null(tep_cache_mobile_also_purchased(3600))) {
    echo tep_cache_mobile_also_purchased(3600);
    

     

    That's it


  2. @@raiwa

     

    I'm noticing that links built like this are no longer working. I'm guessing due to the latest changes with getting rid of the redirectcancelled stuff.

     

    define('TEXT_CALL_FOR_PRICE', '<a title="Call for Quote" href="' . ((mobile_session() == true) ?FILENAME_MOBILE_CONTACT_US: FILENAME_CONTACT_US . '?redirectCancelled=true') . '"> <b>Call for Quote!</b></a>');
    

     

    How would I fix these?

     

    Thanks

     

    @@Roaddoctor

     

    try this:

     

    define('TEXT_CALL_FOR_PRICE', '<a title="Call for Quote" href="' . ((mobile_session() == true) ?FILENAME_MOBILE_CONTACT_US: FILENAME_CONTACT_US) . '"> <b>Call for Quote!</b></a>');
    

     

    or this:

     

    define('TEXT_CALL_FOR_PRICE', '<a title="Call for Quote" href="' . (defined('FILENAME_MOBILE_CONTACT_US') ? FILENAME_MOBILE_CONTACT_US : FILENAME_CONTACT_US) . '"> <b>Call for Quote!</b></a>');
    

     

    regards

    Rainer


  3. One last quick thing and this will be me how can i set an image size in my mobile_product_info.php file? i want all my images to be able to fit on the screen how can i get this to work? I apparently have fancybox installed but i have no idea how to adapt that to a mobile site. can anyone help me? many thanks incase ur wondering my site is www.theonlinefurniturestore.org.uk

     

    you got the answer here (instead of checkout mobile_files compare mobile_product_info and mobile_catalogue to your standard files):

     

    @@alexpacteau compare your checkouts mobile_ files to your standard files. Make sure all paypal related changes made to standard files are also made in the mobile_ files. Paypal express should work once that is done.


  4. @@raiwa

     

    I hope your enjoying your trip!

     

    When you get back there is something not right with the manufacturer drop down. When I select a manufacturer the link looks like

     

    domain.com/-mm-14.html

     

    where it should read

     

    domain.com/ManufacturerName-mm-14.html

     

    and if you select Back to categories you get

     

    domain.com/-mm-.html instead of mobile_catalogue.php

     

    I'm assuming this is a SEO URL 2.2d issue but haven't studied the problem yet.

     

    And for the time being I've removed also_purchased until we can sort that out as well.

     

    -Dave

    @@Roaddoctor

     

    I just checked the manufacturer menu in my SEO URL 2.2d Testshop and everythin seems to work correct.

    So please send me a copy of your relevant files:

    - includes/application_top.php

    - includes/classes/seo_class.php

    - includes/footer.php

    - mobile/includes/footer.ph

    - .htaccess

    - mobile_catalogue.php

     

    I assume you have still my mail

    I'll do some research, maybe there is missing something in the update/install instr.

     

    For the also_purchased_products:

    Can't find a rule when this error appears and recreate it.

    So it's very difficult to research.

    As it is a very minor problem in my opinion, I would ask you to wait for iOSC6 which will resolve any redirect problem since it will use a different approach.

    The only thing what could be tried is to change the filename definition from:

    define ('FILENAME_PRODUCT_INFO', 'mobile_product_info.php');
    

     

    to

    define ('FILENAME_MOBILE_PRODUCT_INFO', 'mobile_product_info.php');
    

     

    and then do a search for:

    FILENAME_PRODUCT_INFO
    

    and replace with:

    FILENAME_MOBILE_PRODUCT_INFO
    

    in all mobile files.

     

    regards

    Rainer


  5. Raiwa your too quick too post updates :) lol I never thought I would ever say that.. Anyway the following needs to be added to that update.

     

    In /admin/includes/functions/header_tags.php

    FIND

     

    				 5 => 'specials.php');
    

     

    REPLACE WITH

     

    				 5 => 'specials.php',
    // Begin iOSC
    6 => 'mobile_catalogue.php',
    7 => 'mobile_product_reviews.php',
    8 => 'mobile_product_reviews_info.php',
    9 => 'mobile_product_reviews_write.php');
    // End iOSC
    

     

    In /includes/header_tags.php

     

    if exists, also comment out or remove:

    // mobile_catalogue.php
    case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_CATALOGUE):
    if (! ReadCacheHeaderTags($header_tags_array, basename($_SERVER['PHP_SELF']), '')) {
     $header_tags_array = tep_header_tag_page(FILENAME_MOBILE_CATALOGUE);
     WriteCacheHeaderTags($header_tags_array, basename($_SERVER['PHP_SELF']), '');
    }
    break;
    

     

    after changes, upload the admin file first, then the other, to prevent auto re-detection of the basefiles.

     

    Thanks to Jack_mcs for the guidance. There "might" be more needed to perfect...

     

     

    @@Roaddoctor

     

    Very sorry, I'm on a trip and can sit with the computer only in the evening for a very short time, so I thought to update this fast yesterday.

    Now I uploaded this fix and if there is anything more missing=another update.

     

    Regards

    Rainer


  6. @@raiwa

    I've noticed that on the mobile side that header tags do not work correctly in product reviews (displays the generics rather than product name, specifics...)

    I think this change needs is needed in /includes/header_tags.php

     

    1. Make sure your local file matches your stores version, make a safe backup, then

     

    FIND

    // PRODUCT_INFO.PHP
    // PRODUCT_REVIEWS.PHP
    // PRODUCT_REVIEWS_INFO.PHP
    // PRODUCT_REVIEWS_WRITE.PHP
    case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_INFO):
    case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS):
    case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS_INFO):
    case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS_WRITE):
    switch (true)
    {
     case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_INFO):		 $filename = FILENAME_PRODUCT_INFO;		 break;
     case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS):	 $filename = FILENAME_PRODUCT_REVIEWS;	 break;
     case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS_INFO): $filename = FILENAME_PRODUCT_REVIEWS_INFO; break;
     case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS_WRITE): $filename = FILENAME_PRODUCT_REVIEWS_WRITE; break;
     default: $filename = FILENAME_PRODUCT_INFO;
    }
    

     

    Replace with

    // PRODUCT_INFO.PHP
    // PRODUCT_REVIEWS.PHP
    // PRODUCT_REVIEWS_INFO.PHP
    // PRODUCT_REVIEWS_WRITE.PHP
    // MOBILE_PRODUCT_REVIEWS.PHP
    // MOBILE_PRODUCT_REVIEWS_INFO.PHP
    // MOBILE_PRODUCT_REVIEWS_WRITE.PHP
    case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_INFO):
    case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS):
    case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS_INFO):
    case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS_WRITE):
    // Begin iOSC
    case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS):
    case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS_INFO):
    case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE):
    // End iOSC
    switch (true)
    {
     case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_INFO):		 $filename = FILENAME_PRODUCT_INFO;		 break;
     case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS):	 $filename = FILENAME_PRODUCT_REVIEWS;	 break;
     case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS_INFO): $filename = FILENAME_PRODUCT_REVIEWS_INFO; break;
     case (basename($_SERVER['PHP_SELF']) === FILENAME_PRODUCT_REVIEWS_WRITE): $filename = FILENAME_PRODUCT_REVIEWS_WRITE; break;
    // Begin iOSC
     case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS):	 $filename = FILENAME_MOBILE_PRODUCT_REVIEWS;	 break;
     case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS_INFO): $filename = FILENAME_MOBILE_PRODUCT_REVIEWS_INFO; break;
     case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE): $filename = FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE; break;
    // Begin iOSC
     default: $filename = FILENAME_PRODUCT_INFO;
    }
    

     

    Then, if exists, delete or comment out the following 3 bits

     

    // mobile_product_reviews_write.php
    case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE):
    if (! ReadCacheHeaderTags($header_tags_array, basename($_SERVER['PHP_SELF']), '')) {
     $header_tags_array = tep_header_tag_page(FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE);
     WriteCacheHeaderTags($header_tags_array, basename($_SERVER['PHP_SELF']), '');
    }
    break;
    

     

    // mobile_product_reviews.php
    case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS):
    if (! ReadCacheHeaderTags($header_tags_array, basename($_SERVER['PHP_SELF']), '')) {
     $header_tags_array = tep_header_tag_page(FILENAME_MOBILE_PRODUCT_REVIEWS);
     WriteCacheHeaderTags($header_tags_array, basename($_SERVER['PHP_SELF']), '');
    }
    break;
    

     

    // mobile_product_reviews_info.php
    case (basename($_SERVER['PHP_SELF']) === FILENAME_MOBILE_PRODUCT_REVIEWS_INFO):
    if (! ReadCacheHeaderTags($header_tags_array, basename($_SERVER['PHP_SELF']), '')) {
     $header_tags_array = tep_header_tag_page(FILENAME_MOBILE_PRODUCT_REVIEWS_INFO);
     WriteCacheHeaderTags($header_tags_array, basename($_SERVER['PHP_SELF']), '');
    }
    break;
    

     

    Could you test this please. There might be more todo - not sure

     

    @@Roaddoctor

     

    Thank you!

     

    I tested this and it seems to be fine.

    Uploaded already the update.

     

    Regards

    Rainer


  7. @@raiwa

    That is what I thought. I asked because my shop, as far as I can tell, is already doing the canonical correctly and it seemed possibly redundant. This may not be nescessary for 2.2d seo url users?? or do it anyway?....

     

    @@Roaddoctor

     

    Yes, it is possible that it isn't necessary for SEO URLs, but for standard URLs.

     

    Another issue:

     

    I began to work on iOSC 6.0:

     

    main features:

     

    - all mobile files moved to mobile/ directory.

    - can be installed in subdomain/different domain.

    - much easier redirect scripts

    - same mobile filenames as desktop filenames

    - no additional filename definitions needed

    (except files which doesn't exist on desktop version like: catalogue.php, search.php, about.php

    - no additional SEO URL support needed.

     

    What do you think about?

    If you like I can send you a beta version for testing.

     

    Regards

    Rainer


  8. @@raiwa

     

    Just curious/verifying why the below is needed?

     

    4d. /catalog/includes/header_tags.php
    
    FIND
    	 $canonical_url = StripSID(tep_href_link(basename($_SERVER['PHP_SELF']), $args, 'NONSSL', false) );
    REPLACE WITH
    	 $args = str_replace('-mp-', '-p-', $args);
    	 $canonical_url = StripSID(tep_href_link(str_replace('mobile_', '', basename($_SERVER['PHP_SELF'])), $args, 'NONSSL', false) );
    

     

     

    Thank you

     

    @@Roaddoctor

     

    The desktop URL should be shown,in the canonical URL Tag also on the mobile page. So as the canonical URL shown in the header tag is set up by the actual page URL, the mobile page URL is corrected here to the correspondent Desktop URL.

     

    Rainer


  9. pretty much what i'm noticing is once a redirect occurs - say product to mobile product - the links in the also purchased module are sometimes correct, and sometimes opposite.

    Site is here

     

    @@Roaddoctor

     

    I found this happens in my shop with the also purchased products module too (with Ultimate Seo Urls 5 PRO).

    Didn't notice until now, I'll work on this.

     

    Contribution support 1.8 uploaded.

     

    regards

    Rainer


  10. Hi.. Rainer

     

    I notice that the mobile_password_reset only changes the password on the desktop. I tried using the old and the new andriod phone and the password change does not function properly. Don't know if I did something wrong.

     

    Using my mobile phone

    (Mobile site)

    I sign-in to my account -> my account -> your password

    But the password does not change.

     

    Thank you!

     

     

    mobile_password_reset.php

     

    <?php

     

    require_once('mobile/includes/application_top.php');

     

    require(DIR_WS_LANGUAGES . $language . '/' . str_replace("mobile_", "", FILENAME_PASSWORD_RESET));

     

    $error = false;

     

    if ( !isset($HTTP_GET_VARS['account']) || !isset($HTTP_GET_VARS['key']) ) {

    $error = true;

     

    $messageStack->add_session('password_forgotten', TEXT_NO_RESET_LINK_FOUND);

    }

     

    if ($error == false) {

    $email_address = tep_db_prepare_input($HTTP_GET_VARS['account']);

    $password_key = tep_db_prepare_input($HTTP_GET_VARS['key']);

     

    if ( (strlen($email_address) < ENTRY_EMAIL_ADDRESS_MIN_LENGTH) || (tep_validate_email($email_address) == false) ) {

    $error = true;

     

    $messageStack->add_session('password_forgotten', TEXT_NO_EMAIL_ADDRESS_FOUND);

    } elseif (strlen($password_key) != 40) {

    $error = true;

     

    $messageStack->add_session('password_forgotten', TEXT_NO_RESET_LINK_FOUND);

    } else {

    $check_customer_query = tep_db_query("select c.customers_id, c.customers_email_address, ci.password_reset_key, ci.password_reset_date from " . TABLE_CUSTOMERS . " c, " . TABLE_CUSTOMERS_INFO . " ci where c.customers_email_address = '" . tep_db_input($email_address) . "' and c.customers_id = ci.customers_info_id");

    if (tep_db_num_rows($check_customer_query)) {

    $check_customer = tep_db_fetch_array($check_customer_query);

     

    if ( empty($check_customer['password_reset_key']) || ($check_customer['password_reset_key'] != $password_key) || (strtotime($check_customer['password_reset_date'] . ' +1 day') <= time()) ) {

    $error = true;

     

    $messageStack->add_session('password_forgotten', TEXT_NO_RESET_LINK_FOUND);

    }

    } else {

    $error = true;

     

    $messageStack->add_session('password_forgotten', TEXT_NO_EMAIL_ADDRESS_FOUND);

    }

    }

    }

     

    if ($error == true) {

    tep_redirect(tep_href_link(FILENAME_PASSWORD_FORGOTTEN));

    }

     

    if (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'process') && isset($HTTP_POST_VARS['formid']) && ($HTTP_POST_VARS['formid'] == $sessiontoken)) {

    $password_new = tep_db_prepare_input($HTTP_POST_VARS['password']);

    $password_confirmation = tep_db_prepare_input($HTTP_POST_VARS['confirmation']);

     

    if (strlen($password_new) < ENTRY_PASSWORD_MIN_LENGTH) {

    $error = true;

     

    $messageStack->add('password_reset', ENTRY_PASSWORD_NEW_ERROR);

    } elseif ($password_new != $password_confirmation) {

    $error = true;

     

    $messageStack->add('password_reset', ENTRY_PASSWORD_NEW_ERROR_NOT_MATCHING);

    }

     

    if ($error == false) {

    tep_db_query("update " . TABLE_CUSTOMERS . " set customers_password = '" . tep_encrypt_password($password_new) . "' where customers_id = '" . (int)$check_customer['customers_id'] . "'");

     

    tep_db_query("update " . TABLE_CUSTOMERS_INFO . " set customers_info_date_account_last_modified = now(), password_reset_key = null, password_reset_date = null where customers_info_id = '" . (int)$check_customer['customers_id'] . "'");

     

    $messageStack->add_session('login', SUCCESS_PASSWORD_RESET, 'success');

     

    tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL'));

    }

    }

     

    $breadcrumb->add(NAVBAR_TITLE_1, tep_mobile_link(FILENAME_LOGIN, '', 'SSL'));

    $breadcrumb->add(NAVBAR_TITLE_2);

    require(DIR_MOBILE_INCLUDES . 'header.php');

    require('includes/form_check.js.php');

    $headerTitle->write();

    ?>

    <!-- header_eof //-->

    <div id="iphone_content">

    <!-- body //-->

    <?php echo tep_draw_form('password_reset', tep_mobile_link(FILENAME_MOBILE_PASSWORD_RESET, 'account=' . $email_address . '&key=' . $password_key . '&action=process', 'SSL'), 'post', 'onsubmit="return check_form(password_reset);"', true);

    ?>

    <div id="messageStack">

    <?php

    if ($messageStack->size('password_reset') > 0) {

    echo $messageStack->output('password_reset');

    }

    ?>

     

    <div class="contentContainer">

    <div class="contentText">

    <?php echo TEXT_MAIN; ?>

    </div>

    </div>

     

    <?php

    ?>

    </div>

    <div id="returning_cust">

    <?php echo TEXT_MAIN; ?>

    <br /><br />

    <label for="password" class="float"><?php echo ENTRY_PASSWORD; ?></label>

    <?php echo tep_draw_password_field('password'); ?>

    <br />

    <label for="confirmation" class="float"><?php echo ENTRY_PASSWORD_CONFIRMATION; ?></label>

    <?php echo tep_draw_password_field('confirmation'); ?>

    <br />

    <?php echo ''.tep_mobile_button(IMAGE_BUTTON_CONTINUE).''; ?>

    </div>

    </form>

    <?php require(DIR_MOBILE_INCLUDES . 'footer.php');

    ?>

     

    Hello ,@@Lucky4444

     

    can you please post your shops url to see what happens

     

    Kind regards

    Rainer


  11. @@Roaddoctor

     

    Never noticed this in my shops.

    To resolve it the only way would be to change the filename definition in mobile/includes/configure.php:

     

    to

    define ('FILENAME_MOBILE_PRODUCT_INFO', 'mobile_product_info.php');

    But this means to search all mobile pages and replace it there too.

     

    Just thought about and this should'nt be related to the filename definition, but with the seo url support, not sure, I'll research on this.

    Fot the ? in some urls: I'll check this.

     

    @@Roaddoctor

     

    If you look at this part of seo_class.php:

    		    $seo_pages = array(FILENAME_DEFAULT,
    							   'product_info.php',
    							   FILENAME_POPUP_IMAGE,
    							   'product_reviews.php',
    							   FILENAME_PRODUCT_REVIEWS_INFO);
    							   if ( defined('FILENAME_ALLPRODS_SEO') ) $seo_pages[] = FILENAME_ALLPRODS_SEO;
    							   if ( defined('FILENAME_MOBILE_ALLPRODS_SEO') ) $seo_pages[] = FILENAME_MOBILE_ALLPRODS_SEO;
    							   if ( defined('FILENAME_ARTICLES') ) $seo_pages[] = FILENAME_ARTICLES;
    							   if ( defined('FILENAME_ARTICLE_INFO') ) $seo_pages[] = FILENAME_ARTICLE_INFO;
    							   if ( defined('FILENAME_INFORMATION') ) $seo_pages[] = FILENAME_INFORMATION;
    							   if ( defined('FILENAME_POLLBOOTH') ) $seo_pages[] = FILENAME_POLLBOOTH;
    							   if ( defined('FILENAME_FAQDESK_INFO') ) $seo_pages[] = FILENAME_FAQDESK_INFO;
    							   if ( defined('FILENAME_FAQDESK_INDEX') ) $seo_pages[] = FILENAME_FAQDESK_INDEX;
    							   if ( defined('FILENAME_FAQDESK_REVIEWS_INFO') ) $seo_pages[] = FILENAME_FAQDESK_REVIEWS_INFO;
    							   if ( defined('FILENAME_FAQDESK_REVIEWS_ARTICLE') ) $seo_pages[] = FILENAME_FAQDESK_REVIEWS_ARTICLE;
    							   if ( defined('FILENAME_LINKS') ) $seo_pages[] = FILENAME_LINKS;
    							   if ( defined('FILENAME_NEWSDESK_INFO') ) $seo_pages[] = FILENAME_NEWSDESK_INFO;
    							   if ( defined('FILENAME_NEWSDESK_INDEX') ) $seo_pages[] = FILENAME_NEWSDESK_INDEX;
    							   if ( defined('FILENAME_NEWSDESK_REVIEWS_INFO') ) $seo_pages[] = FILENAME_NEWSDESK_REVIEWS_INFO;
    							   if ( defined('FILENAME_NEWSDESK_REVIEWS_ARTICLE') ) $seo_pages[] = FILENAME_NEWSDESK_REVIEWS_ARTICLE;
    							   if ( defined('FILENAME_PAGES') ) $seo_pages[] = FILENAME_PAGES;
    							   if ( defined('FILENAME_CATALOG') ) $seo_pages[] = FILENAME_CATALOG;
    							   $seo_pages[] = 'mobile_product_info.php';
    							   $seo_pages[] = 'mobile_product_reviews.php';
    							   if ( defined('FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE') ) $seo_pages[] = FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE;
    							   if ( defined('FILENAME_MOBILE_POPUP_IMAGE') ) $seo_pages[] = FILENAME_MOBILE_POPUP_IMAGE;
    							   if ( defined('FILENAME_MOBILE_INFORMATION') ) $seo_pages[] = FILENAME_MOBILE_INFORMATION;
    							   if ( defined('FILENAME_MOBILE_PRODUCT_REVIEWS_INFO') ) $seo_pages[] = FILENAME_MOBILE_PRODUCT_REVIEWS_INFO;								  
    

     

    I'm not sure if these lines are correct:

     

    							   $seo_pages[] = 'mobile_product_info.php';
    							   $seo_pages[] = 'mobile_product_reviews.php';
    

     

    compare to:

    		    $seo_pages = array(FILENAME_DEFAULT,
    							   'product_info.php',
    							   FILENAME_POPUP_IMAGE,
    							   'product_reviews.php',
    							   FILENAME_PRODUCT_REVIEWS_INFO);
    

    maybe it should be:

     

    		    $seo_pages = array(FILENAME_DEFAULT,
    							   'product_info.php',
    							   FILENAME_POPUP_IMAGE,
    							   'product_reviews.php',
    							   FILENAME_PRODUCT_REVIEWS_INFO),
    							   'mobile_product_info.php',
    							   'mobile_product_reviews.php';
    ...................
    							   if ( defined('FILENAME_PAGES') ) $seo_pages[] = FILENAME_PAGES;
    							   if ( defined('FILENAME_CATALOG') ) $seo_pages[] = FILENAME_CATALOG;
    							   if ( defined('FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE') ) $seo_pages[] = FILENAME_MOBILE_PRODUCT_REVIEWS_WRITE;
    							   if ( defined('FILENAME_MOBILE_POPUP_IMAGE') ) $seo_pages[] = FILENAME_MOBILE_POPUP_IMAGE;
    
    

     

     

    what do you think? could you try this?

     

    regards

    Rainer


  12. Argh. I have something wrong then. Sometimes it has the correct -mp- link, and sometimes it has the -p- and redirects to desktop.

     

    @@Roaddoctor

     

    Never noticed this in my shops.

    To resolve it the only way would be to change the filename definition in mobile/includes/configure.php:

     

    to

    define ('FILENAME_MOBILE_PRODUCT_INFO', 'mobile_product_info.php');

    But this means to search all mobile pages and replace it there too.

     

    Just thought about and this should'nt be related to the filename definition, but with the seo url support, not sure, I'll research on this.

    Fot the ? in some urls: I'll check this.


  13. @@raiwa

    Noticing, for example

     

    from desktop, on an individual product review:

    /...-pri-29.html?reviews_id=25

     

    click to mobile side:

    -mpri-29.html?reviews_id=25

     

    click back to desktop:

    -pri-29.html?reviews_id=25&redirectCancelled=true

     

    So far all perfect.

     

    now if I click some other link, such as the back button to go to the main review page, or even add to cart, etc

    -pr-29.html?redirectCancelled=true

    /shopping_cart.php?redirectCancelled=true

    ...

     

    The ?redirectCancelled=true remains in the link for one more additional click, then it disappears. This happens in several areas of the store, and in some areas (like clicking on the Home page or a product page) it does not seem to happen. This probably isn't a big deal other than perhaps how cleanly the site gets indexed.

     

    Dave

     

    @@Roaddoctor

     

    Hello Dave,

     

    Just uploaded the new update iOSC5.4rev2 which resolves this.

    redirect cancelled=true will not show any more in the urls.

    Thanks for the push in this direction

     

    The seo urls and header tags support update is on the way, please be patient.

     

    regards

    Rainer


  14. @@raiwa

     

    I Just noticed that the also_purchased_products.php on the mobile side is displaying classic side links... see example here

     

    Here is the current code. Any idea whats wrong?

     

    <?php
    if (isset($HTTP_GET_VARS['products_id'])) {
    $orders_query = tep_db_query("select p.products_id, p.products_image from " . TABLE_ORDERS_PRODUCTS . " opa, " . TABLE_ORDERS_PRODUCTS . " opb, " . TABLE_ORDERS . " o, " . TABLE_PRODUCTS . " p where opa.products_id = '" . (int)$HTTP_GET_VARS['products_id'] . "' and opa.orders_id = opb.orders_id and opb.products_id != '" . (int)$HTTP_GET_VARS['products_id'] . "' and opb.products_id = p.products_id and opb.orders_id = o.orders_id and p.products_status = '1' group by p.products_id order by o.date_purchased desc limit " . MAX_DISPLAY_ALSO_PURCHASED);
    $num_products_ordered = tep_db_num_rows($orders_query);
    if ($num_products_ordered >= MIN_DISPLAY_ALSO_PURCHASED) {
    ?>
    <!-- also_purchased_products //-->
    <div id="also_purchased">
    <h1><?php echo TEXT_ALSO_PURCHASED_PRODUCTS; ?></h1>
    <?php
     $col = 0;
     $info_box_contents = array();
     while ($orders = tep_db_fetch_array($orders_query)) {
     if($col > 2) break;
    
     $orders['products_name'] = tep_get_products_name($orders['products_id']);
     $col ++;
     $path = '<a href="' . tep_mobile_link(FILENAME_PRODUCT_INFO, 'products_id=' . $orders['products_id']) . '">';
     $img = tep_image(DIR_WS_IMAGES . $orders['products_image'], $orders['products_name'], MOBILE_IMAGE_WIDTH, MOBILE_IMAGE_HEIGHT);
    ?>
     <div id="prodCell_also">
     <div class="prodImg"><?php echo $path . $img . '</a>'; ?></div>
     <div class="prodName"><?php echo $path . $orders['products_name'] . '</a>'; ?></div>
     </div>
    <?php	
     }
    ?>
    </div>
    <!-- also_purchased_products_eof //-->
    <?php
    }
    }
    ?>
    

     

    @@Roaddoctor

     

    This is correct, the filename for mobile_product_info is defined like this in mobile/includes/configure.php:

    define ('FILENAME_PRODUCT_INFO', 'mobile_product_info.php');
    

     

    so beeing on the mobile page it will link correct to mobile_product_info.php

     

    I know this is confusing, have already plans to fix this.


  15. The parse time thing is strange so if I turn off parse time in the osc admin under configuration, logging, Store Page Parse Time it goes away. I like seeing that on the pages to see how fast my server is running. It seems to be coming from the iosc mobile/includes/application_bottom.php file:

    if (DISPLAY_PAGE_PARSE_TIME == 'true') {
    

    I just changed it to false and all good!

     

    @@mrossi

    Checked this and there is one closing </div> tag to remove in the mobile footer.

     

    Then it should look like this:

     

    </table>
    <?php
    }
    ?>
    </div>
    </body>
    </html>
    

     

    I'll fix this in the next update


  16. For the parse time message:

    this is showing also on the desktop shop at the very end of the footer.

    So this seems to be added by your server and if it doesn't show where you wants on the mobile side you should play with different </div> tags at the end of the mobile footer or disable this feature in your server settings.

    If you added this code, it shows like this in the source code:

    </div>
    </div>
    </body>
    </html>
    <span class="smallText">Parse Time: 0.050s</span>
    

    then try to move the line:

    <span class="smallText">Parse Time: 0.050s</span>
    

    before the last </div> tag that the code shows like this:

    </div>
    <span class="smallText">Parse Time: 0.050s</span>
    </div>
    </body>
    </html>
    

     

     

    For the not showing images in mobile header:

    I found that you are using an image cache/thumbnail contribution.

    Try to change in mobile/includes/header.php line 57:

    change:

    tep_image(DIR_MOBILE_IMAGES. "home.png")
    

    to:

    tep_image(DIR_WS_HTTP_CATALOG . DIR_MOBILE_IMAGES. "home.png")
    

    or this:

    tep_image('/' . DIR_MOBILE_IMAGES. "home.png")
    

     

    the same for the other images line 58-61

     

     

    Please let me know if one of this changes works, it will be included in the troubleshooting section in the next update.

     

    Kind regards

    Rainer


  17. installed 5.4rev1, seems to be working but how do I remove the parse time that keeps showing right below the header and make the index page go to products by default instead of sign in? PS great MOD just wish the colors weren't so ugly. Almost forgot changed the header image in header.php but that does not seem to work either.

     

    Hello Matthew,

     

    For the message can you please post the URL to your shop to see better what happens.

    I'll check then what happens with your logo too.

     

    For the colors: colors are a personal taste and in the install instr. I wrote "change the colors to fit your shops design" :rolleyes:

     

    regards

    Rainer


  18. @@raiwa

     

    In the upgrade instructions for 5.4 rev1

     

    For #1, does this apply to the SEO 2.2d version? if so, I didn't see any similar change in the support package file

     

    Also your instructions say

     

    ***FIND:
    			 if (strpos($_SERVER['REQUEST_URI'], 'cPath=') == FALSE) {
    				 $mobile_site = 'mobile_index.php';
    
    ***REPLACE WITH:
    if (strpos($_SERVER['REQUEST_URI'], 'manufacturers_id=') == TRUE) {
    							 $mobile_site = str_replace('index.php', 'mobile_catalogue.php', ($_SERVER['REQUEST_URI']));						
    			 } else if ( (strpos($_SERVER['REQUEST_URI'], 'cPath=') == FALSE)) {
    

     

    Shouldn't it be:

     

    ***FIND:
    			 if (strpos($_SERVER['REQUEST_URI'], 'cPath=') == FALSE) {
    
    ***REPLACE WITH:
    					 if (strpos($_SERVER['REQUEST_URI'], 'manufacturers_id=') == TRUE) {
    							 $mobile_site = str_replace('index.php', 'mobile_catalogue.php', ($_SERVER['REQUEST_URI']));						
    			 } else if ( (strpos($_SERVER['REQUEST_URI'], 'cPath=') == FALSE)) {
    

     

    For #2 and #3

    Again, is there a SEO URL version of these lines?

    Your instructions say:

    ***FIND:
    
    if (!isset($lng) || (isset($lng) && !is_object($lng))) {
    
     ***REPLACE WITH:
    
    if (!tep_session_is_registered('language') || isset($HTTP_GET_VARS['language'])) {
    

     

    The code I have currently is:

     

    if ((SEO_ENABLED != 'true') and ((!isset($lng) || (isset($lng) && !is_object($lng))))) { // for seo urls 2.2d
    

     

    Thanks!

     

    The first part I'll check tomorrow, it seems to be a mistake.

    For 2+3, yes it is not necessary any change for SEO URL, the standard code of iOSC5.4rev1 (should) work.

    Sorry no update instr. added yet, will do this in the next update.

    For the next post: You are right, Header tags has not been updated yet.

    I'll do this the next days.


  19. The above for the 2.2d seo_class seems to be working just fine. Once I added this last bit to /includes/application_top.php all seems good.

     if ($url_basename == 'product_reviews_info.php') {
    		 if (SEO_ENABLED == 'true'){
    										 $mobile_site = str_replace('-pri-', '-mpri-', $_SERVER['REQUEST_URI']);
    		 }	
     }	
    

     

    cheers

     

     

    Hello Dave@@Roaddoctor,

     

    I just uploaded the updates.

     

    I'm not shure if you already added this line to .htaccess:

    RewriteRule ^(.*)-mpri-(.*).html$ mobile_product_reviews_info.php?products_id=$2&%{QUERY_STRING}
    

     

    regards

    Rainer


  20. @@raiwa

     

    For the 5.4 upgrade, looking at the code change needed in 2.2d seo_class.php... Do these three lines look appropriate....

     

    Line 603 add this

    							 if ( defined('FILENAME_MOBILE_PRODUCT_REVIEWS_INFO') ) $seo_pages[] = FILENAME_MOBILE_PRODUCT_REVIEWS_INFO;
    

     

    Line 680 add this

    									 'products_id_mobile_review_info' => '-mpri-'
    

     

    Line 918 add this

    										 case ( $page == 'mobile_product_reviews_info.php' ):													
    												 $url = $this->make_url($page, $this->get_product_name($p2[1]), 'products_id_mobile_review_info', $p2[1], '.html');
    												 break;
    

     

    Should that do it??

     

    @@Roaddoctor

     

    This looks very nice, I was working today on the SEO URL update for SEO URLs USU5, tomorrow I'll try to do the job for your version and upload soon the update.

     

    regards

    Rainer


  21. Thanks alot for all your help thats it working now :) Ive now found a couple of wee niggles though that i am stuck on :( and i was really hoping u could help me. On the index page http://www.theonlinefurniturestore.org.uk/mobile_index.php?language= it does not show my store logo for some reason how do i change which image it uses? Also why is it coming up with language= at the end? In addition when your are viewing a product http://www.theonlinefurniturestore.org.uk/mobile_product_info.php/arctic-burnt-orange-rug-mp-1193 it comes up huge when viewing it on an iphone. Is there any way to change the image sizes to fit a screen of my choice? many thanks and sorry for asking so much...

     

    Hello Alex,

     

    For the language=

    It is empty because you are viewing the site in the default language.

    This shouldn't be added but it doesn't disturb neither.

    I planned to arange this in the next update.

     

    For the Shop Logo:

    Open mobile/includes/header.php

    and change the logo in line 54:

    replace: "baner_sar_mobile.jpg" to the name of your logo.

     

    For the images:

    I saw that you use some add-on for image managing/caching on your desktop site.

     

    You should install the code you modified in product_info.php also in mobile_product_info.php

     

    It should be in these lines:

     

    	  if (tep_not_null($pi['htmlcontent'])) {
    	    $pi_entry .= '#piGalimg_' . $pi_counter;
    	  } else {
    	    $pi_entry .= tep_href_link(DIR_WS_IMAGES . $pi['image'], '', 'NONSSL', false);
    	  }
    	  $pi_entry .= '" target="_blank" rel="fancybox">' . tep_image(DIR_WS_IMAGES . $pi['image'],$product_info['products_name'], MOBILE_IMAGE_WIDTH, MOBILE_IMAGE_HEIGHT) . '</a>';
    	  if (tep_not_null($pi['htmlcontent'])) {
    	    $pi_entry .= '<div style="display: none;"><div id="piGalimg_' . $pi_counter . '">' . $pi['htmlcontent'] . '</div></div>';
    	  }
    	  $pi_entry .= '</li>';
    	  echo $pi_entry;
        }
    ?>
      </ul>
       </div>
    <?php
      } else {
    ?>
       <div id="piGal">
       <?php echo '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image'], '', 'NONSSL', false) . '" target="_blank" rel="fancybox">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), MOBILE_IMAGE_WIDTH, MOBILE_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '</a>'; ?>
       </div>
    

     

    The same you should do in mobile/includes/modules/products.php

     

    with the image wrapper code you added to:

    includes/modules/product_listing.php

     

     

    For this remember what is said in the installation instructions of iOSC:

     

    This package will work "out of the box" only with unmodified OSCommerce 2.3.2. and 2.3.3. shops.

     

     

     

    If you have any other add-on which affects the catalog site of your shop installed,

    download the latest version of: "Contribution support for iOSC 5.x"

    here:

    http://addons.oscommerce.com/info/8578

     

    and install the support for the add-ons you are using once you finished this installation.

     

    Add-ons which are not yet included in this package you will need to adapt and install yourself to the mobile-pages.

    If you do so it would be very appreciated if you include your solutions to the support package.

     

    If you use SEO URL add-ons you need to install the corresponding support for correct links from and to the IOSC pages.

     

    Support for:

     

    ULTIMATE Seo Urls 5 ( r205 ) - by FWR Media

    http://addons.oscommerce.com/info/6768

     

    and

     

    Ultimate SEO 2-2.2d-12 - by chemo

    http://addons.oscommerce.com/info/2823

     

    is included in the support package.

     

     

    regards

    Rainer


  22. Are you sure these are the correct lines for a 2.2d shop? posted is my existing htaccess before making changes. I already have a mm in there too

     

    RewriteRule ^([a-z0-9/-]+)-mm-([0-9_]+).html$ mobile_catalogue.php [NC,L,QSA]
    RewriteRule ^([a-z0-9/-]+)-mpri-([0-9]+).html$ mobile_product_reviews_info.php [NC,L,QSA]
    

     

    before changes

     

    RewriteBase /
    RewriteRule ^(.*)-p-(.*).html$ product_info.php?products_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-c-(.*).html$ index.php?cPath=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-m-(.*).html$ index.php?manufacturers_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-pi-(.*).html$ popup_image.php?pID=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-by-(.*).html$ all-products.php?fl=$2&%{QUERY_STRING}
    # IOSC mobile site
    RewriteRule ^(.*)-mby-(.*).html$ mobile_all-products.php?fl=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-t-(.*).html$ articles.php?tPath=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-a-(.*).html$ article_info.php?articles_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-au-(.*).html$ articles.php?authors_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-pr-(.*).html$ product_reviews.php?products_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-pri-(.*).html$ product_reviews_info.php?products_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-f-(.*).html$ faqdesk_info.php?faqdesk_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-fc-(.*).html$ faqdesk_index.php?faqPath=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-fri-(.*).html$ faqdesk_reviews_info.php?faqdesk_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-fra-(.*).html$ faqdesk_reviews_article.php?faqdesk_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-i-(.*).html$ information.php?info_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-links-(.*).html$ links.php?lPath=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-pm-([0-9]+).html$ info_pages.php?pages_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-n-(.*).html$ newsdesk_info.php?newsdesk_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-nc-(.*).html$ newsdesk_index.php?newsPath=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-nri-(.*).html$ newsdesk_reviews_info.php?newsdesk_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-nra-(.*).html$ newsdesk_reviews_article.php?newsdesk_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-po-([0-9]+).html$ pollbooth.php?pollid=$2&%{QUERY_STRING}
    # IOSC mobile site
    RewriteRule ^(.*)-mp-(.*).html$ mobile_product_info.php?products_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-mc-(.*).html$ mobile_catalogue.php?cPath=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-mm-(.*).html$ mobile_catalogue.php?manufacturers_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-mpi-(.*).html$ mobile_popup_image.php?pID=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-mpr-(.*).html$ mobile_product_reviews.php?products_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-mprw-(.*).html$ mobile_product_reviews_write.php?products_id=$2&%{QUERY_STRING}
    RewriteRule ^(.*)-mi-(.*).html$ mobile_information.php?info_id=$2&%{QUERY_STRING}
    

     

    No need if its already there I also see that the entries are different because of 2.2d, my lines were for SEO URLs USU5.

    Sorry I did this very fast, next week the revised update please be patient.

    And you are right the seo.class.php has to be updated too.

×