Thursday, July 16, 2009

PayPal buttons and URL masking

I have been having this really weird issue the past week with my PayPal subscription links. No matter what I did all users that were trying to subscribe to my service were being redirected to https://www.paypal.com/cgi-bin/webscr, the PayPal homepage. Nothing was working. I took me a while to figure it out, but after plenty of test buttons with generated code and a phone call to PayPal, I realized that the POST variables weren't getting to the PayPal server. Why?? So weird, what changed? Turns out that you cannot POST anything from a GoDaddy server (maybe any server) that has a masked URL. If you're using URL masking to make a particular directory of a webserver appear to be root directory, PayPal buttons will NOT POST variables correctly. For me, REMOVING url masking solved my problem.

If your PayPal links do not work, and you're using masked URLs, turn them off. That should do it!

2 comments:

  1. I'm not sure what you mean by "url masking". Is it mod_rewrite use or 404 error direction?

    ReplyDelete
  2. had the same problem with my url, regular buy now (non subscription based) buttons worked fine from masked urls (hosted on godaddy), but any subscription based button would redirect to the paypal main page. I wish there was a way to get it to work within a masked url, that's the whole reason i bought the domain!

    ReplyDelete