Just trying to make a conversion tracking system (pixel+cookie) with PHP for study purpose. Just need some ideas and guides regarding this from tracker point of view.
I have basic understanding on how it works. Basically there are 4 parties involved: merchant, tracker, promoter and user. Merchant places iframe based pixel (from tracker) on their thank you (last check out) page.
User surfs the web, finds an ad/offer and clicks
It directs to tracker. Then tracker puts cookie on user's computer and redirects to merchant's landing page
User likes the product during this first visit. He/she adds to cart, checkouts and make a payment. Thank you page shows up and fires the pixel.
Tracker get necessary parameters and checks for cookie in user's computer, records the sales and gives credit to the promoter.
Well, all this works if there is only one tracker, merchant, promoter.
My questions are:
(a) How to correctly identify sales when multiple parties are involved?
(b) Also user may not buy the product on the same day. Instead he/she might come back directly and buy the product after a week or two.
(a) Scenario
M- Merchant
T1,T2,T3 - trackers (supposing we are T1)
U - user
In this case merchant may join force with all three trackers and put pixel from each on their thank you page.
User may have landed on particular merchants page from all the tracker links including us. In this case user's computer contains all three cookies from three different trackers.
When user buys the product and reaches Thank you page pixel will fire up for all three tracker. Each tracker will check for cookie and finds their cookie present and might confirm sales.
In this case, there is a possibility of 3 recorded sales where in fact is just one sale.
So the question is how each tracker will know, whether this sales is theirs or not and avoid that as they cannot access cookies of other trackers?
(b) Scenario
Same goes for after click tracking.
Supposing cookie duration is 30 days. (i) User buys product after 15 days after clicking the ad. (ii) Multiple cookie must have already been present in user's computer.
So from particular tracker's point of view, how do we identify the sale correctly?
First, it depends on what you mean by "tracker." A tracker usually is a 3rd party affiliate network that uses a tracking solution. They pair up a merchant (who is selling the product) with a publisher (who advertises and displays the link).
So to answer to question A:
I think it would be unlikely for a merchant to have 3 different "trackers" sending them visitors. Typically, if you were the merchant, you sign up with one affiliate network, then recruit publishers within that network. It wouldn't be smart to sign up with more than one, probably for this very reason.
If more than one cookie was set (within the one affiliate network), the affiliate network would typically use the rule of "last cookie," which means the last ad that was clicked before the purchase is the one that the sale goes to.
Take a look at this similar Quora question: http://www.quora.com/Should-merchants-use-multiple-affiliate-networks-to-sell-their-product-Why-or-why-not
In answer to Question B:
If cookie duration is 30 days, and a user comes back in 15, there should be no problem. If the buyer goes directly to the merchant's site, buys the product, and see's the "thank you" page where the tracking pixel (or whatever tracking solution they use) is, that pixel will fire. The pixel calls a server-side script, like PHP, that will test whether the user has the particular cookie. So it doesn't matter whether the user comes back directly, or when they come back to buy the product. As long as they still have that cookie (within the 30 day limit), the sale will be registered.
Related
I want to track user visits & user conversions who come via my Affiliates, however a caveat is that my users will land, register and hence convert on a 3rd party site. I own a Wordpress website and my user registration page is hosted on a 3rd party. My Affiliates will send an email blast to their users with the email containing unique Affiliate link to register on that 3rd party. Successful registration page is also hosted on that 3rd party itself and hence my website never comes into picture during the entire process right from user landing to user conversion.
So essentially following are the basic features that I require:
Ability to manage (create, edit, delete) Affiliates.
Ability to generate required links, creatives and tracking pixels or any code which can help to track user visits and conversions.
Ability to track the number of user impressions and user conversions per Affiliate including how many users from a particular Affiliate landed on the 3rd party registration page and which users (with basic details such as name, country etc.) actually got converted.
Various reports mainly based on Date and Affiliates.
The 3rd part is ready to host some code (such as tracking pixel) from my side.
I have already tried using 'WP Affiliate Manager' plugin in Wordpress, however using its ‘Creatives’ and ‘Tracking Pixels’ can only report the impression/conversion, but not other user details such as Name, Country etc. which would be collected by the 3rd party on the registration page and hence my entire purpose is not fulfilled.
I need to get this done today. Please let me know what could be the quickest solution.
Best Regards!
If you are vCommission affiliate user then go through this link http://developers.hasoffers.com/#/affiliate/controller/Affiliate_AffiliateUser/method/findAll
You will got all user details after 14 days if he does shopping using your affiliate link.
I'm creating a kind of affiliate marketing website with products I've scraped from partner websites. The user clicks on the Buy link and is re-directed to the partner site to complete the purchase. If the user buys the product, I should get a percentage of the sales. So far this model is a pretty common approach.
However the element that I don't yet understand is, what technology or script do other affiliate sites use to track to see if the user, once they've let the main site, does purchase the product or not? How do I track my user's purchase or actions once they've left my site?
I know that cookies can store brief user information but I don't think that's enough. I need to then store this information in a database. Should I use php sessions for this?
Any tips or suggestions is really appreciated.
Cheers
What technology or script do other affiliate sites use to track to see if the user, once they've let the main site, does purchase the product or not?
Javascript. Affiliate Softwares usually have click tracking code which is placed on the landing pages. Once a vsitor comes to landing page through an affiliate website, a random visitor id along with affiliate id mapping is created which gets stored in the database. At this same time, a cookie gets created with the visitor id, affiliate id info etc. When the user finishes a purchase, there is a sales tracking code javascript code which is placed on the purchase page that gets trigerred. You can use create this code and insert the visitor's id along with affiliate id in the database.
How do I track my user's purchase or actions once they've left my site?
I have answered this partly in the above question. But once the user comes back again, it is going to recognise this user based on cookie and preferably you can store the session value in the cookie itself rather than the database, because the sale entry will get created in the database once the user has completed his purchase, if you have placed your sale tracking code at the end of purchase page.
I need some help and out-of-the-box thinking, because I'm genuinely stumped.
I'm making a gift registry website (like for wedding registries). The idea is that the person making the gift registry can add items from anywhere on the web (say, target.com). Then, when someone wants to buy them an item off the registry, they come to our website, find an item, click on the link and are taken to the product page (on target.com) and buy the gift.
The problem is that we need to know if the product was actually purchased so the gift isn't purchased multiple times. Also, we need to give the purchaser the address of the person for whom they're buying a gift.
Here's what we'd like to do:
Unfortunately, the only way I can think of how to do this is through an iframe, which doesn't work with many large retailers (like Amazon and Wal-Mart), which have blocked iframes for legitimate security reasons. Another option is opening two new browser windows, but that's just ugly.
So, what else can I do? Any brilliant JavaScript/css/php or whatever solutions out there?
you can't reliably detect if an item was purchased if it can be any shop in the web. you can only detect if somone clicked a link to the item in the shop but not if he buys it.
you should rely on the user to mark the item as bought.
Your only option, albeit a poor one, is a Bookmarklet. The buyer would have to add/install the bookmarklet before they began shopping. After they complete an order they would have to run the bookmarklet on the order confirmation/receipt page to "verify" the purchase.
You would have to write code for every merchant you support. Anytime the merchant changes their confirmation/receipt page you would have to update your verification script. The bookmarklet would determine the merchant from the page URL and check the page for specific elements to determine which product was purchased.
I would use the bookmarklet as an optional step since you can't assume your users will remember to use it or even know how to use it. I would mark items as "Unverified Purchase" when they choose a product from your list, then mark it as a "Verified Purchase" if the bookmarklet is used. You can also make your bookmarklet verification work on "order history" pages for users who forget to use the bookmarklet during the checkout process but still wish to verify their order.
I'm developing one social game which is similar to friends for sale game.
In the game user buys and sells friends.
Buyer of the user becomes owner of that user.
I developed logic and it works perfect as per calculation.
But when we have many number of users there is problem with this action of buy button.
E.g. 5 users are on same profile i.e. UserXYZ. Now 2 of them clicks on buy button at the same time, same second.
Amount of cash is being loose from both the accounts but only one becomes owner.
I want to stop this cash losing problem.
This problem occurs because script executes at the same time for both the users but only one of them becomes owner.
I have no idea how to stop this over sale clicks. Website is in PHP/MySQL.
Any help will really be appreciated.
without seeing any of your code, i can't really give a code answer, but, in theory i would fix this like so:
when your sending your ajax "buy friend" request, send the current owner id along with it.
In your php, check if the friend that is getting bought has the same owner, if it does, do the sale, if not, reply a friendly message saying "sorry, someone else bought them"
Instead of subtracting the money from the front-end, subtract the money from the backend after the user has been successfully added to that owner. That way you avoid the problem. Make sure you pass the ownerid to the backend, which you should be doing already.
I'm creating a simple online shop with PHP integrated with PayPal that sells unique items. What I'm wondering is how other shops deal with multiple people attempting to go through the payment process with the same item.
This is my current draft strategy:
Items have three status types: available, on hold & sold.
As a user moves to the PayPal payment page it checks the status of all the items in the cart to ensure they're available. It also sets the item's status to "on hold" until they either come back after payment is confirmed or it times out (10 minutes? Not sure what this should be).
Is this standard practice or is there a more practical way I should be going about this?
Thanks in advance!
Have a look at Dell's UK outlet. When someone adds a system to their shopping basket it is held and not available to other customers. If it isn't purchased, the item is removed from the basket after 15mins of inactivity and is then available to other customers.
I would say the first part of your strategy is correct - as you move to the payment page, flag all the products as 'on hold'
When the user has finished the payment, you will get a postback from Paypal which lets you know if the authorisation was successful or not (and possibly also allows you to check the CSC/CVV2 result), and at that point you have the option of either accepting the payment, or rejecting it.
On receipt of the postback you should also check whether the items are still on hold. If they have timed out you can reject the payment and display a message 'sorry - timeout exceeded' or somesuch.
This method also allows you to work out an ideal timeout period if you keep track of how often customers run into the timeout, so you can extend the timeout from (eg) 5 to 10 minutes if too many are timing out, or shorten it if none are timing out.
This is a fairly common issue with fixed inventory systems such as venue, transport/airline tix etc.
I like the airline model where once you get the itinery you want and click select, you get a page with passenger info with a message saying, seats on hold and you now have xx(10/15) minutes to complete the purchase. Everything becomes explicit at that time. For other unique/one of a kind item, I'd think a message on any page, that the user clicks on, saying you have xx(mins) remaining to complete the purchase would be a big motivator for "on the edge" buyers !
woot.com is notorious for this problem but their solution works well. After payment information is verified the user is brought to a page with a small amount of text saying something like "your order is in, we are verifying inventory".
It looks like the paypal API has a "RefundTransaction" message so something like that might not be possible. But the user experience could be awkward if your going to the paypal website then coming back to your site.
This is much like booking theatre tickets or similar online and yes the way you describe is generally the way it works. At some point the item is "reserved" in the system and either the customer completes the transaction or the item is released after some time for others to buy.
Of course at what point you reserve the item (when it's added to the cart, at the point you send them off to pay etc) is up to you. I would expect putting it in the cart would be the best choice as it makes it less likely someone will build up a basket of stuff only to find half of it is no longer available at the checkout.