In this case, I need to implement a function to pay by scanning the QR code. I made the QR code into a url link and called JSAPI in the link to initiate charges. Now the problem is that my QR code needs to contain a parameter (item ID ), fees are charged by different IDs, and the last record is ,... in this case, I need to implement a function to pay by scanning the QR code. I made the QR code into a url link and called JSAPI in the link to initiate charges. Now the problem is that my QR code needs to contain a parameter (item ID ), different IDs are used to charge fees, and the records are recorded at last. Considering that there may be an infinite number of product types, it is impossible to make them into subwebpages.
The problem now is that I am using http://shop.com /? The link id = 100 will think? The following parts are also part of the link, and parameters cannot be passed. How do you implement them?
Reply content:
In this case, I need to implement a function to pay by scanning the QR code. I made the QR code into a url link and called JSAPI in the link to initiate charges. Now the problem is that my QR code needs to contain a parameter (item ID ), different IDs are used to charge fees, and the records are recorded at last. Considering that there may be an infinite number of product types, it is impossible to make them into subwebpages.
The problem now is that I am using http://shop.com /? The link id = 100 will think? The following parts are also part of the link, and parameters cannot be passed. How do you implement them?
I encountered this problem in the program that generated the QR code. I tried this problem in two ways.
1. As mentioned above, when using the rewrite path, "?" is not displayed in the path. This will affect the characters that receive parameters.
2. Urlencode,define index.html % 3 factid % 3d3% 26 from % 3d3 ", after receiving decode, the obtained parameter is: index.html? Actid = 3 & from = 3.
Does this website inspire you?
Http://segmentfault.com/q/1010000004324729