When user A is concerned about the public number, share a product with a friend. The product URL has uid=a identification parameters.
User B, after clicking on the product link, followed the public number.
How to judge User B is to point to the user a share of the link to focus on it? To judge the idea or code.
The purpose of this decision is to allow the calculated rebate of user A WHO has shared the link after the new User B purchase.
100 points for high-finger teaching, do not know enough, the task urgent, in this extremely grateful!
Reply to discussion (solution)
After the user clicks the share, each person produces the suffix link to be different.
Scheme:
1, when the user concerned about the public number, record the current page URL, to determine who shared the article.
2. Return the money to the sharing person.
The shared link is followed by parameters, randomly generated, and recorded in the library.
After the user clicks the share, each person produces the suffix link to be different.
Scheme:
1, when the user concerned about the public number, record the current page URL, to determine who shared the article.
2. Return the money to the sharing person.
Details? Following the public number, has entered the public number, the interface is the public interface, there is no current page URL it? Get how to get it.
The shared link is followed by parameters, randomly generated, and recorded in the library.
The share link has been added to the argument, the issue has been clarified: the product URL with uid=a identification parameters.
How to record the storage, record what information. How is the information to be recorded obtained?
User B Click on the product link, then your program can record that User B is through a chain, User B after the public number, and then check whether the record corresponds. Such
Didn't you record the UID of a? You should use this, right? For accuracy, you can also record a number of parameters. Most of the existing alliances are based on this idea (attaching the UID of the referrer to the link address).