Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

pchem

Members
  • Posts

    47
  • Joined

  • Last visited

Posts posted by pchem

  1. Thanks again Jack!

    I got the contact_us.php working with the revision you provided.

    At about line 309 in create_account.php I ended up just trying the code recommended in the install file even though the commands looked quite a bit different, and it seems to be working fine.

  2. Thanks for the add-on @Jack_mcs.  I installed the MS2 v1.10 on my v2.2 RC2a based site, but there are some differences I am running into.

    Emails are not being sent from catalog/contact_us.php and it just returns to the catalog/contact_us.php page like nothing happened.

    In catalog/contact_us.php the directions state to:

    FIND:

    <?php echo tep_draw_form('contact_us', tep_href_link('contact_us.php', 'action=send'), 'post', 'class="form-horizontal"', true); ?>

    REPLACE WITH:

    <?php //BEGIN HONEYPOT ?>
    <?php echo tep_draw_form('contact_us', tep_href_link('contact_us.php', 'action=send'), 'post', ' onsubmit="return validateMyForm();" class="form-horizontal"', true); ?>
    <?php //END HONEYPOT ?>   

    My version has this on line 105 instead:
    <?php echo tep_draw_form('contact_us', tep_href_link(FILENAME_CONTACT_US, 'action=send')); ?>

    I tried to replace it with this:
    <?php echo tep_draw_form('contact_us', tep_href_link(FILENAME_CONTACT_US, 'action=send'), 'onsubmit="return validateMyForm();"'); ?>

    Should I have done something different?

    Likewise, in catalog/create_account.php the directions state to find:

    <?php echo tep_draw_form('create_account', tep_href_link('create_account.php', '', 'SSL'), 'post', '', true) . tep_draw_hidden_field('action', 'process'); ?>

    REPLACE WITH:

    <?php //BOC Honeypot ?>
    <?php echo tep_draw_form('create_account', tep_href_link('create_account.php', '', 'SSL'), 'post', 'class="form-horizontal" onSubmit="return validateMyForm(create_account);"', true) . tep_draw_hidden_field('action', 'process'); ?>
    <?php //EOC Honeypot ?>


    Instead, on line 309 I found:
    <?php echo tep_draw_form('create_account', tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL'), 'post', 'onSubmit="return check_form(create_account);"') . tep_draw_hidden_field('action', 'process'); ?>

    And changed it to:
    <?php echo tep_draw_form('create_account', tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL'), 'post', 'class="form-horizontal" onSubmit="return validateMyForm(create_account);"',) . tep_draw_hidden_field('action', 'process'); ?>
     

    I an getting a syntax error, but I don't know enough to know what is wrong.  Will someone please point me in the right direction?

  3. I was able to get the most expensive rate automatically selected by doing the following:

     

    In catalog/includes/classes/shipping.php at line 111 I changed:

     

    if ($rates[$i]['cost'] < $cheapest['cost']) {

    To:

    if ($rates[$i]['cost'] > $cheapest['cost']) {

     

    Just the less than "<" to greater than ">" was changed to automatically select the most expensive method radio button.

     

    Ideally, I want to change it to automatically select 2-Day for USA and most expensive for rest of world. This idea may work in catalog/includes/classes/shipping.php, but I still do not know how to write the "if, then" statements. Can anyone help me out?

  4. Has anyone been successfully using the ship separate check box?

    Searched the thread to no avail.

     

    I have everything but that functioning correctly.

    I can check the box to my hearts content, but I never get multi-package totals.

    This really screws me up as I have a number of oversize items, in addition to many items that can be shipped together.

     

    For some reason it just does not seem to toggle the code.

     

    My shop is running v2.2 RC2 with FedEx module 2.07 and an 2.07.1.1 update. It acted the same way. What I did to fix this is go to the admin control panel for modules. Click shipping, then Federal Express. Edit the following to suit your needs:

     

    Max. weight

     

    Max. quantity of ship boxes

     

    These values are NOT only for when the FedEx site is disabled, but are also used for the ship separately function. My values were set to low for some of my heavy items. I arbitrarily picked 10 for the number of boxes and 150 pounds. Now it seems to be working fine.

  5. Has anyone been successfully using the ship separate check box?

    Searched the thread to no avail.

     

    I have everything but that functioning correctly.

    I can check the box to my hearts content, but I never get multi-package totals.

    This really screws me up as I have a number of oversize items, in addition to many items that can be shipped together.

     

    For some reason it just does not seem to toggle the code.

     

    Mine acts the same. Any fixes for it?

  6. My shop is a v2.2 RC2a with FedEx Direct 2.07 (and upgraded to 2.07.1 with the patch fedex1.php). I only use FedEx as a shipping method. It has worked fine for the last year, but now I need to ship some items separately since they require Hazmat shipping. My problems are now two fold:

     

    Problem 1:

    When I check the "Ship Separately" box for "Product A" in the admin>catalog>Categories/Products product descriptions and either 2 or more of "Product A" are purchased on the website or "Product A" + any other product are purchased together, then no shipping options are offered. One "Product A" alone brings up FedEx just fine at checkout. I have changed the sort order of the FedEx shipping module as outlined here, but it made no difference.

     

    What is needed for the "Ship Separately" option to work?

     

    Problem 2:

    I want to add a $20.00 Hazmat surcharge to about 25 specific items in my store. I want these items to ship separately (individually if possible) from non-Hazmat items. If non-Hazmat item are also in the cart, I want the customer to still choose what FedEx service they want for those items. I read about making an array on this post. Has anyone written an array like that for the FedEx Direct module? Where would this array be inserted in catalog>includes>modules>shipping>fedex1.php?

     

    Has anyone successfully used Individual Product Shipping Methods or Individual Product Shipping Prices with the FedEx Direct module?

     

     

    Can anyone please help????

  7. Proof of concept code;

     

    $products_surcharge = array(20, 21, 22, 23); // any of these ID's in the cart, add the surcharge
         $products = $cart->get_products();
         for ($i=0, $n=sizeof($products); $i<$n; $i++) {
           if (in_array($products[$i]['id'], $products_surcharge)) {
             $cost += 5; // amount to be added
             break;
           }
         }

     

    burt, How would one do this with the FedEx Direct module that I inquired about here.

  8. My shop is a v2.2 RC2a with FedEx Direct 2.07 (and upgraded to 2.07.1 with the patch fedex1.php). I only use FedEx as a shipping method. It has worked fine for the last year, but now I need to ship some items separately since they require Hazmat shipping. My problems are now two fold:

     

    Problem 1:

    When I check the "Ship Separately" box for "Product A" in the admin>catalog>Categories/Products product descriptions and either 2 or more of "Product A" are purchased on the website or "Product A" + any other product are purchased together, then no shipping options are offered. One "Product A" alone brings up FedEx just fine at checkout. I have changed the sort order of the FedEx shipping module as outlined here, but it made no difference.

     

    What is needed for the "Ship Separately" option to work?

     

    Problem 2:

    I want to add a $20.00 Hazmat surcharge to about 25 specific items in my store. I want these items to ship separately (individually if possible) from non-Hazmat items. If non-Hazmat item are also in the cart, I want the customer to still choose what FedEx service they want for those items. I read about making an array on this post. Has anyone written an array like that for the FedEx Direct module? Where would this array be inserted in catalog>includes>modules>shipping>fedex1.php?

     

    Has anyone successfully used Individual Product Shipping Methods or Individual Product Shipping Prices with the FedEx Direct module?

  9. I just installed the "Second Address Line" contribution on my store (my site is v2.2 RC2) where I have been using PayPal Direct 1.1. I am still working up to testing the 2nd address, but from this page PayPal suggest that the second address is not required (see Table 4.7 CardOwner: AddressType Fields).

     

    Did you get the 2nd address working properly for you?

  10. Thanks again for the contribution. I have it up and running and it works perfectly using Mozilla/Firefox, but with Internet Explorer (IE 6 and IE 7) all the parent categories of the pop out menu are displayed, but many of the children or sub categories are missing. For example the x-linker section has three sub categories, but only two are listed in the menu. Is there a known reason for this?

  11. Thanks again Sam! I'll check those out on my demo site and see if I can get the desired effect.

     

    I want to eliminate page rank duplicate content penalties that I might be receiving. In some regard I'd like to mimic the effect this site is using. They have parent categories with children products of different packaging sizes, yet there is only one product info page per product. Can anyone tell what contributions might have been used there?

  12. Robert,

    Thank you for this wonderful contribution. The menu and all site maps work fine. The RSS feed looks good, but only appears to contains feeds from catalog/index.php even though I added the proper code (<link rel="alternate" type="application/rss+xml" href="fwrrss.xml" /> directly below <link rel="stylesheet" type="text/css" href="stylesheet.css">) in the following catalog files: index.php, product_info.php, contact_us.php, conditions.php, privacy.php, shipping.php, sitemap.php, etc. The instructions indicate that code goes in all catalog files that you want included in the RSS feed. Is that correct, or did I misunderstand something?

     

    Also, what is the suggested/preferred way to add the RSS button?

  13. My Website sells scientific reagents. We have the same description of products that only differ in package size and I want to minimize any potential duplicate content hits. I would like to know if OSC can be modified to list the product information (from catalog/product_info.php) below the listing of products (catalog/index.php).

     

    For example, put the information from pages like this for CHCA below the table on the CHCA matrix "Category" page. I would also remove hyperlinks from the table on the CHCA matrix page linking to the CHCA product info page.

     

    Is this possible? Or are good templates already available for this layout?

  14. The Independent_Seo_Url_Validation contribution won't prevent duplicate urls in the way google is probably looking at them. It is meant to prevent the same url from being accessed with a different name. It doesn't prevent duplicate urls where the arguments of the url are changed due to language, sorting or something else, at least the last I looked it didn't. You need to use the new Canonical meta tag. If you have the latest version of Header Tags SEO installed, it will handle that for you. Otherwise, search the forums for Canonical to find other ways to handle it. That may not be your problem but I know that google is listing a lot more duplicate urls than before so my guess is that it is.

     

    Jack

    Thanks Jack and Robert for your input. I think I figured it out. I had New Google Sitemap Generator (NGS-1.2-misstop.co.uk) which made URLs, but did not add the descriptive content from the category and/or product name. Therefore, Google was prbably getting the redirect error when going from the sitemap and trying to access the optimized page:

    http://www.XXXXXXX.com/-c-1_17_24.html

    vs.

    http://www.XXXXXXX.com/zerolengthcrosslink...-c-1_17_24.html

     

    I now have Jack's Google XML Sitemap SEO V 1.1 installed and I am already seeing pages drop from Google's URL error report. Thanks again Jack for that!

  15. I've had the 23 Nov 2008 version of 2.1d ORIGINAL updated on my site since late last year. Initially the Google indexing went way up (top 10 in many cases, even #1), but I have been loosing ground over the last few months (dropping off the charts to 200-300). Google has lots of my links with "URLs not followed" due to "Redirect error" (the same URLs are listed in "Errors for URLs in Sitemaps" also as "Redirect error"). But the URLs work fine (same with the sitemap)!

     

    I thought this could be due to duplication errors, but the SEO contrib that I used appears to include the Independent_Seo_Url_Validation_v1.0.4 contrib. Any thoughts that might be causing this problem?

  16. Maestro and Solo cards (MasterCard's debit card in UK and possibly other parts or Europe) were not desired on my site. I cleaned up the look of the page by removing the Credit Card Valid From and Card Issue Number from the PayPal Direct module. To do this I commented out the code at about line 35 & 106 in catalog/inculdes/modules/payment/paypal_direct.php

     

    Changed this:

          $this->cc_types = array('VISA' => 'Visa',
                                 'MASTERCARD' => 'MasterCard',
                                 'DISCOVER' => 'Discover Card',
                                 'AMEX' => 'American Express',
                                 'SWITCH' => 'Maestro',
                                 'SOLO' => 'Solo');
       }

     

    To this:

    $this->cc_types = array('VISA' => 'Visa',
                                 'MASTERCARD' => 'MasterCard',
                                 'DISCOVER' => 'Discover Card',
                                 'AMEX' => 'American Express');
                           //    'SWITCH' => 'Maestro',
                           //    'SOLO' => 'Solo');   **commented out, removed "," after AmEx and then added ");" **
       }

     

     

    Changed this:

                                                  array('title' => MODULE_PAYMENT_PAYPAL_DIRECT_CARD_VALID_FROM,
                                                       'field' => tep_draw_pull_down_menu('cc_starts_month', $months_array) . ' ' . 
    
    tep_draw_pull_down_menu('cc_starts_year', $year_valid_from_array) . ' ' . MODULE_PAYMENT_PAYPAL_DIRECT_CARD_VALID_FROM_INFO),
                                                 array('title' => MODULE_PAYMENT_PAYPAL_DIRECT_CARD_EXPIRES,
                                                       'field' => tep_draw_pull_down_menu('cc_expires_month', $months_array) . ' ' . 
    
    tep_draw_pull_down_menu('cc_expires_year', $year_expires_array)),
                                                 array('title' => MODULE_PAYMENT_PAYPAL_DIRECT_CARD_CVC,
                                                       'field' => tep_draw_input_field('cc_cvc_nh-dns', '', 'size="5" maxlength="4"')),
                                                 array('title' => MODULE_PAYMENT_PAYPAL_DIRECT_CARD_ISSUE_NUMBER,
                                                       'field' => tep_draw_input_field('cc_issue_nh-dns', '', 'size="3" maxlength="2"') . ' ' . 
    
    MODULE_PAYMENT_PAYPAL_DIRECT_CARD_ISSUE_NUMBER_INFO)));
    
         return $confirmation;
       }

     

    TO THIS:

                                      //  array('title' => MODULE_PAYMENT_PAYPAL_DIRECT_CARD_VALID_FROM,
                                      //        'field' => tep_draw_pull_down_menu('cc_starts_month', $months_array) . ' ' . 
    
    tep_draw_pull_down_menu('cc_starts_year', $year_valid_from_array) . ' ' . MODULE_PAYMENT_PAYPAL_DIRECT_CARD_VALID_FROM_INFO),
                                        array('title' => MODULE_PAYMENT_PAYPAL_DIRECT_CARD_EXPIRES,
                                              'field' => tep_draw_pull_down_menu('cc_expires_month', $months_array) . ' ' . 
    
    tep_draw_pull_down_menu('cc_expires_year', $year_expires_array)),
                                        array('title' => MODULE_PAYMENT_PAYPAL_DIRECT_CARD_CVC,
                                              'field' => tep_draw_input_field('cc_cvc_nh-dns', '', 'size="5" maxlength="4"')));
                               //       array('title' => MODULE_PAYMENT_PAYPAL_DIRECT_CARD_ISSUE_NUMBER,
                               //               'field' => tep_draw_input_field('cc_issue_nh-dns', '', 'size="3" maxlength="2"') . ' ' . 
    
    MODULE_PAYMENT_PAYPAL_DIRECT_CARD_ISSUE_NUMBER_INFO));
         }

     

    This change works on my site and I hope others will also find it useful!

  17. I am using PayPal direct (US) and it processes credit cards fine, but it lacks the error message when any fields are incomplete. The standard pink box shows up, but no text is present nor the error.gif. I want customers to know why they might not be proceeding to the confirmation page.

     

    Feel free to check it out at mysite. The test account is "[email protected]" and the PW is "2test".

     

    I'll be very grateful if someone can help.

     

    This code is present in catalog/includes/languages/english/modules/payment/paypal_direct.php and appears fine:

     

    define('MODULE_PAYMENT_PAYPAL_DIRECT_ERROR_ALL_FIELDS_REQUIRED', 'Error: All payment information fields are required.');

     

    The code surrounding MODULE_PAYMENT_PAYPAL_DIRECT_ERROR_ALL_FIELDS_REQUIRED in catalog/includes/modules/payment/paypal_direct.php is as follows:

    starting at line 119:

        function pre_confirmation_check() {
         if (MODULE_PAYMENT_PAYPAL_DIRECT_CARD_INPUT_PAGE == 'Payment') {
           global $HTTP_POST_VARS;
    
           if (!isset($HTTP_POST_VARS['cc_owner']) || empty($HTTP_POST_VARS['cc_owner']) || (strlen($HTTP_POST_VARS['cc_owner']) < CC_OWNER_MIN_LENGTH) || !isset($HTTP_POST_VARS['cc_type']) || !isset($this->cc_types[$HTTP_POST_VARS['cc_type']]) || !isset($HTTP_POST_VARS['cc_number_nh-dns']) || empty($HTTP_POST_VARS['cc_number_nh-dns']) || (strlen($HTTP_POST_VARS['cc_number_nh-dns']) < CC_NUMBER_MIN_LENGTH)) {
             $payment_error_return = 'payment_error=' . $this->code . '&error=' . urlencode(MODULE_PAYMENT_PAYPAL_DIRECT_ERROR_ALL_FIELDS_REQUIRED) . '&cc_owner=' . urlencode($HTTP_POST_VARS['cc_owner']) . '&cc_starts_month=' . $HTTP_POST_VARS['cc_starts_month'] . '&cc_starts_year=' . $HTTP_POST_VARS['cc_starts_year'] . '&cc_expires_month=' . $HTTP_POST_VARS['cc_expires_month'] . '&cc_expires_year=' . $HTTP_POST_VARS['cc_expires_year'];
    
             tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, $payment_error_return, 'SSL', true, false));
           }
         }
    
         return false;
       }
    
       function confirmation() {
         $confirmation = array();

     

    starting at line 281:

            if (($response_array['ACK'] != 'Success') && ($response_array['ACK'] != 'SuccessWithWarning')) {
             tep_redirect(tep_href_link(FILENAME_SHOPPING_CART, 'error_message=' . stripslashes($response_array['L_LONGMESSAGE0']), 'SSL'));
           }
         } else {
           tep_redirect(tep_href_link(FILENAME_CHECKOUT_CONFIRMATION, 'error_message=' . MODULE_PAYMENT_PAYPAL_DIRECT_ERROR_ALL_FIELDS_REQUIRED, 'SSL'));
         }
       }
    
       function after_process() {
         return false;
       }
    
       function get_error() {
         if (MODULE_PAYMENT_PAYPAL_DIRECT_CARD_INPUT_PAGE == 'Payment') {
           global $HTTP_GET_VARS;
    
           $error = array('error' => stripslashes(urldecode($HTTP_GET_VARS['error'])));
    
           return $error;
         }
    
         return false;
       }

×
×
  • Create New...