title: PayPal Convertings Spaces in _cart Form to Plus Sign
body: <p>Recently (starting March 2017), the <code>_cart</code> form integration with PayPal payments standard has started encoding spaces in all item info (names and options) to the plus sign (<code>+</code>). I verified this was happening in Chrome and added the <code>enctype</code> attribute to the form, which seemed to solve the issue for me. In Chrome and Firefox, I can send data to PayPal and spaces are preserved properly. Perhaps this is a fluke?</p>
  
  <p>However, almost every customer that purchases is getting their info encoded improperly, which results in the IPN request not being able to verify the products they purchased.</p>
  
  <p>The form:</p>
  
  <pre><code>&lt;form action="https://www.paypal.com/cgi-bin/webscr" method="post" enctype="application/x-www-form-urlencoded"&gt;
  &lt;input type="hidden" name="cmd" value="_cart"&gt; 
  &lt;input type="hidden" name="upload" value="1"&gt; 
  &lt;input type="hidden" name="business" value="name@example.com"&gt;
  &lt;input type="hidden" name="charset" value="utf-8"&gt;
  &lt;input type="hidden" name="item_name_1" value="Product With Spaces"&gt;
  &lt;input type="hidden" name="quantity_1" value="1"&gt; 
  &lt;input type="hidden" name="amount_1" value="30.00"&gt;
  &lt;input type="hidden" name="on0_1" value="Name"&gt;
  &lt;input type="hidden" name="os0_1" value="First Last"&gt;
  &lt;input type="hidden" name="on1_1" value="Email"&gt;
  &lt;input type="hidden" name="os1_1" value="customer@example.com"&gt;
  &lt;input type="image" src="https://www.paypal.com/en_US/i/btn/btn_xpressCheckout.gif" align="left" style="margin-right:7px; margin-top: 2px;"&gt;
  &lt;img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>When submitted to PayPal, the product is shown as <code>Product+With+Spaces</code> and the name as <code>First+Last</code>. Thus the transaction record on PayPal and the IPN request have the incorrectly encoded data also.</p>
  
  <p>I tried encoding the spaces as <code>%20</code> or <code>+</code> (which would normally result in double-encoding, so I didn't expect it to help), but those literal characters were shown on PayPal.</p>
  
  <p>I've read over the PayPal developer docs, and I seem to be using the most up-to-date fields and URLs. Also, this code has been running successfully for years without trouble.</p>