PayPal Item Number - 2ashoporderstring4a

Top  Previous  Next


Starting in AShop V 2.1,there is a field on the PayPal confirmation page that reads "Item Number:

2ashoporderstring4a". What is this and where does it come from?


The "2ashoporderstring4a" is a version of the product string, which contains information about which products have been ordered. In previous versions of AShop this was an 'a' separated list of product id's that was split apart by the different scripts to find out what the shopping cart contained or what had been ordered. Since some of the payment gateways don't allow for more custom fields to be sent we needed a way to pass through information about which payment method had been chosen without adding another field. This information was added to the beginning of the product string, which became the order string.


The 'ashoporderstring' is used to split apart the information about which payment option (id 2 in this case) has been used from the old product string. The reason for making it a word instead of just a single letter is that it needs to be clearly identifiable by the order script to make sure that the value of the right field (the name of the field differs between the different gateways) is used. order.php searches through all input fields that has been sent and when it finds a field that contains 'ashoporderstring' it uses it as the product string.