none
PayPal "Add to Cart" Button takes visitor to PayPal account, not shopping cart RRS feed

  • Question

  • Greetings:

     

    This is my first time posting. Just finished spending about 70 hours to go through the first 19 "hours" of Sams Teach Yourself MEW3 in 24 hours. :)

    Great book.

     

    Anyway. the title above pretty well explains my problem. I read an earlier thread dealing with PayPal buttons, but that thread didn't address my problem. The answer to that thread was to post the html from paypal button in code view. This is what I have done. The button looks good on my site, but doesn't take you to a shopping cart.

    Here is a link to my site .

    I really appreciate any help. I've contacted paypal but their "answer" wasn't helpful.

    Friday, June 11, 2010 3:43 PM

Answers

  • Your working Add button has name="cmd".  Your non-working button has name="cmd1".  My guess is that paypal cares what the name is, and that "cmd" means command, while "cmd1" means nothing.  Try changing it.
    • Marked as answer by sierranomad Friday, June 11, 2010 7:27 PM
    Friday, June 11, 2010 6:23 PM

All replies

  • Your link 404's. Not sure it matters as this is PayPal issue and should be resolved through their resources.

     

    For information on PayPal button use their documentation (its great):

    https://www.paypalobjects.com/WEBSCR-630-20100607-1/en_US/pdf/PP_WebsitePaymentsStandard_IntegrationGuide.pdf

    https://www.paypal.com/us/cgi-bin/webscr?cmd=p/xcl/web-accept-to-sc-button-outside


    --
    Chris Hanscom - Microsoft MVP
    On Facebook | On Twitter | Resource Center | Veign's Blog | Web Development Help

    Get a Complete Website Analysis by Veign
    Friday, June 11, 2010 3:48 PM
  • Sorry about the 404. It should link properly now.

    What I don't get is that I've used paypal buttons in my previous website and never had a problem. In fact, my old pages buttons still work.

    I added the buttons the same with both editors, namely paste the html in code view.

    Anyone else use paypal buttons?

    Friday, June 11, 2010 3:57 PM
  • This isn't an EW question.

    The only suggestion I have, in addition, obviously, to going to the PayPal site for help, is to compare the pages' code views among the working and non-working buttons you have.  Perhaps you did not create your buttons correctly, or copy them correctly.

    Regardless, it doesn't matter what editor you use.  Look in Code View.  The HTML doesn't care what editor created it.

    Friday, June 11, 2010 4:47 PM
  • I've used them many times.

    Post a link to the page where its working and a link to a page where it fails.

    The editor has nothing to do with whether PayPal works or not.  PayPal has full control over what happens based on the request you send - if the request is the same, the result is the same...


    --
    Chris Hanscom - Microsoft MVP
    On Facebook | On Twitter | Resource Center | Veign's Blog | Web Development Help

    Get a Complete Website Analysis by Veign
    Friday, June 11, 2010 4:48 PM
  • OK, thanks. Thought maybe it was MEW related. This is all still new to me, though I'm learning. Maybe the surrounding html I created isn't conducive for the buttons?

    Here is a link to a page where the button is not working.

    Here is a link to a page where it is working.

    I do appreciate your thoughts/insight.

    Friday, June 11, 2010 5:55 PM
  • After looking at the code this is a 100% PayPal issue.  Has nothing to do with EW and there's nothing we can do to help since you are using PayPal's hosted code.

    Onto PayPal for resolution...


    --
    Chris Hanscom - Microsoft MVP
    On Facebook | On Twitter | Resource Center | Veign's Blog | Web Development Help

    Get a Complete Website Analysis by Veign
    Friday, June 11, 2010 6:00 PM
  • Your working Add button has name="cmd".  Your non-working button has name="cmd1".  My guess is that paypal cares what the name is, and that "cmd" means command, while "cmd1" means nothing.  Try changing it.
    • Marked as answer by sierranomad Friday, June 11, 2010 7:27 PM
    Friday, June 11, 2010 6:23 PM
  • You are right CMD1 is nothing, CMD is a special name that tells PayPal what to expect. Plus the _s_click means all the information about what the button does is encrypted and stored with the persons account.

    https://cms.paypal.com/us/cgi-bin/?cmd=_render-content&content_ID=developer/e_howto_html_Appx_websitestandard_htmlvariables


    --
    Chris Hanscom - Microsoft MVP
    On Facebook | On Twitter | Resource Center | Veign's Blog | Web Development Help

    Get a Complete Website Analysis by Veign
    Friday, June 11, 2010 6:32 PM
  • Your working Add button has name="cmd".  Your non-working button has name="cmd1". 

    Thank you. I'll try that. I wouldn't have come up with that myself because I pasted it in code exactly as copied from paypal and I would have assumed that any changes in the code were updates on paypal.

    I'll report on the outcome.

    Again, THANKS! :0)

    Friday, June 11, 2010 7:07 PM
  • It worked!!

    Why the new code inserted the numbers after cmd I'll never know.

    What was obvious to you who are familiar with code would've taken me hours, and paypal support certainly wasn't helpful. Thanks for helping me even though the problem turned out not to be EW related.

    Sinerely,

    Jon

    Friday, June 11, 2010 7:30 PM
  • Because IDs cannot be used more than once on a page so EW makes IDs unique on paste. Requiring the same id to be used more than once on a page is common in cgi scripting but not something that should be done in modern coding practices.

    There is an option to make/not make ids unique on paste in EW but I don't remember which menu it is under (Tools> Page Editor Options would be my guess) since I don't have it available to check right now.


    MS MVP Expression Tutorials & Help http://by-expression.com
    Friday, June 11, 2010 10:38 PM

  • Because IDs cannot be used more than once on a page so EW makes IDs unique on paste. Requiring the same id to be used more than once on a page is common in cgi scripting but not something that should be done in modern coding practices.

     


    MS MVP Expression Tutorials & Help http://by-expression.com

    Sorry for the ignorance, but what does this mean to me? Should I remove any duplicate button for the same product on the same page? But the extra number was added even on the pages that has several products only had one button each. I want to be in concert with current coding practices.

    Thank you,

    Jon

    Friday, June 11, 2010 11:01 PM
  • It doesn't require you to do anything.   It won't work if you don't have the correct name, so put in the correct name.  Use what PayPal requires, or the buttons won't work.
    Friday, June 11, 2010 11:07 PM
  • PayPal doesn't care about IDs, they are concerned with the Name / Value pair.
    --
    Chris Hanscom - Microsoft MVP
    On Facebook | On Twitter | Resource Center | Veign's Blog | Web Development Help

    Get a Complete Website Analysis by Veign
    Friday, June 11, 2010 11:20 PM