Page 1 of 3 123 LastLast
Results 1 to 10 of 25
  1. #1
    Join Date
    Jun 2008
    Posts
    328
    Plugin Contributions
    0

    help question [Done 1.3.9] "Invalid Gift Certificate Redemption Code"

    One of my test customers reports that she tries applying a gift certificate during checkout but it fails with the error message:
    Invalid Gift Certificate Redemption Code
    I checked the customer table and can see that she has the correct GV balance ($4.28).

    However, while the tabular GV Balance shows the correct value, the one in the right pane shows $0.00...

    I am attaching a snapshot here - she is the only one who tried redeeming a gift certificate so far.

    How do I begin troubleshooting this problem?
    Attached Images Attached Images  

  2. #2
    Join Date
    Jun 2008
    Posts
    328
    Plugin Contributions
    0

    Default Re: "Invalid Gift Certificate Redemption Code"

    I would like to add that when trying to redeem gift certificates that I sent to a test account that *I* created, I don't encounter any problem.

    I am attaching a snapshot of the database table coupon_gv_customer. The customer ID in question is 18. Do you notice anything that could explain this problem?
    Attached Images Attached Images  

  3. #3
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: "Invalid Gift Certificate Redemption Code"

    This is a bug ... there isn't an Order yet and the SELECT statement is written in such a way that because there isn't an Order, the value is coming up as 0.00 ...

    I am moving this to the Bug Reports ... thanks!
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  4. #4
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: "Invalid Gift Certificate Redemption Code"

    Add this function to the:
    /admin/includes/functions/general.php

    PHP Code:
        function zen_user_has_gv_balance($c_id) {
          global 
    $db;
            
    $gv_result $db->Execute("select amount from " TABLE_COUPON_GV_CUSTOMER " where customer_id = '" . (int)$c_id "'");
            if (
    $gv_result->RecordCount() > 0) {
              if (
    $gv_result->fields['amount'] > 0) {
                return 
    $gv_result->fields['amount'];
              }
            }
            return 
    0;
        } 
    The edit the file:
    /admin/customers.php

    And change:
    PHP Code:
            $contents[] = array('text' => '<br />' TEXT_INFO_GV_AMOUNT ' ' $currencies->format($customers_orders->fields['amount'])); 
    to read:
    PHP Code:
            $customer_gv_balance zen_user_has_gv_balance($cInfo->customers_id);
            
    $contents[] = array('text' => '<br />' TEXT_INFO_GV_AMOUNT ' ' $currencies->format($customer_gv_balance)); 
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  5. #5
    Join Date
    Jun 2008
    Posts
    328
    Plugin Contributions
    0

    help question Re: [Done 1.4.0] "Invalid Gift Certificate Redemption Code"

    Ajeh, thank you for your bugfix and I am glad that I was able to contribute something to "perfecting" Zen Cart.

    My question now relates to the fact that the bugfix is in the admin code only:

    I understand that it fixes the display on the Admin's right panel for Gift Certificate balance (when no order exists yet for a customer).

    Does that also solve the problem I described as seen by the customer?

  6. #6
    Join Date
    Jun 2008
    Posts
    328
    Plugin Contributions
    0

    red flag Re: [Done 1.4.0] "Invalid Gift Certificate Redemption Code"

    Quote Originally Posted by zcnb View Post
    Does that also solve the problem I described as seen by the customer?
    OK - I did some more elaborate testing after applying the fix and there seems to still be a problem from the customer's point of view:
    • If the customer clicks the GC redemption link, then everything is fine (at checkout, she can elect to apply any amount in her GC balance).
    • On the other hand, if the customer starts checkout before redeeming the GC (and has a GC balance of $0.00), then the "Apply Amount" edit box is missing in step 2 (of 3), and the customer is taken directly to PayPal...

    Some of my test customers were really confused by this.

    Any suggestion how to workaround this (except for asking the customers in the GC email to always use the link)?

  7. #7
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: [Done 1.4.0] "Invalid Gift Certificate Redemption Code"

    If your customer actually enters the GV redemption code during checkout, the funds will be added to their account. They can then fill in the amount they wish to redeem before they complete checkout.
    But they certainly have to redeem the code before the funds are available to them.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  8. #8
    Join Date
    Jun 2008
    Posts
    328
    Plugin Contributions
    0

    red flag Re: [Done 1.4.0] "Invalid Gift Certificate Redemption Code"

    Quote Originally Posted by DrByte View Post
    If your customer actually enters the GV redemption code during checkout, the funds will be added to their account. They can then fill in the amount they wish to redeem before they complete checkout.
    But they certainly have to redeem the code before the funds are available to them.
    I just tried this procedure again and it seems that describing the problem off my memory was inaccurate: During checkout, the customer is actually given the edit box to enter the GC redemption code and the funds are actually added to their account. However, the customer is not given the edit box to fill in the amount he wishes to redeem before he completes checkout. If, after being directed to PayPal, the customer choses to leave PayPal and return to the store, then the edit box to fill in the amount to apply appears...

    If the customer redeems the GC before checkout, however, then what you just described actually happens: the customer is given the edit box to fill in the amount he wishes to redeem before he completes checkout.

    Notice this subtle difference in behavior - I just tried it with a test setup that has the latest fix by Ajeh.

    Can you reproduce this problem?
    Last edited by zcnb; 18 Nov 2008 at 03:16 AM. Reason: added info

  9. #9
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: [Done 1.4.0] "Invalid Gift Certificate Redemption Code"

    I don't see any technical problem that needs reproducing. It's working as the code is written to work.

    The customer cannot use the GV funds until they've redeemed the code.

    1. Customer can redeem the code before they start checkout, by using the link in the email, or the redemption option in the GV-FAQ page, etc. Then they can easily redeem available funds during checkout.

    2. Customer can enter the code and choose payment method, and then on the order-confirmation screen click Edit to go back and apply a GV amount.

    3. If the customer enters the GV code in the box and presses Enter or clicks Continue *without* choosing a payment method, they'll immediately be able to use the funds, because they will be redeemed when they're returned to the same page to select the payment method.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  10. #10
    Join Date
    Jun 2008
    Posts
    328
    Plugin Contributions
    0

    Default Re: [Done 1.4.0] "Invalid Gift Certificate Redemption Code"

    Quote Originally Posted by DrByte View Post
    The customer cannot use the GV funds until they've redeemed the code.
    Indeed, that is the way I expect it to be - and it works as advertised.

    Quote Originally Posted by DrByte View Post
    1. Customer can redeem the code before they start checkout, by using the link in the email, or the redemption option in the GV-FAQ page, etc. Then they can easily redeem available funds during checkout.
    Works great (and without the customer being confused).

    Quote Originally Posted by DrByte View Post
    2. Customer can enter the code and choose payment method, and then on the order-confirmation screen click Edit to go back and apply a GV amount.
    OK, although IMHO it would be better to present the 'Apply Amount' box without having to go back.

    Quote Originally Posted by DrByte View Post
    3. If the customer enters the GV code in the box and presses Enter or clicks Continue *without* choosing a payment method, they'll immediately be able to use the funds, because they will be redeemed when they're returned to the same page to select the payment method.
    Aha! This is where I see the problem: in my shop, there currently is only one payment method (PayPal). Therefore, the customer is never returned back to be given the option to immediately use the funds. A picture is worth a thousand words, so I am attaching a snapshot of this special case.

    Do you see where this can be confusing to the customer?
    Attached Images Attached Images  

 

 
Page 1 of 3 123 LastLast

Similar Threads

  1. v150 Changing the word "Redemption Code" for Gift Certificates, but not Coupons
    By ShanghaiLad in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 1
    Last Post: 30 Nov 2012, 09:17 PM
  2. Invalid Gift Certificate Redemption code
    By deb in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 1
    Last Post: 18 May 2009, 12:27 AM
  3. gift certificate - redemption code invalid
    By ozmosaics in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 2
    Last Post: 25 Apr 2009, 12:37 PM
  4. How to Change "Redemption Code" to "Coupon Code" & "GV Code"
    By dmfelder in forum Basic Configuration
    Replies: 5
    Last Post: 16 Apr 2008, 05:50 PM
  5. Sent out several Gift Certificates in a batch, and they get "Invalid code" message??
    By Aussiebod in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 0
    Last Post: 27 Feb 2008, 08:07 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR