Hi,
Does anyone have a solution or have had to implement a PHP setup where you fire iframe pixels from your script based on conversions from an external page.
FYI: the script where the iframe code will be loaded is not rendered by a viewer - it's a secured php script within the application that pulls the select iframe from database and print to screen within a loop/array.
For example:
External link: http://domain1.com/index.php?leadid=123
Where: $leadid is the tracking value to know where lead originated from to load correct pixel
$c=track1 // this is conversion value assigned that will fire on iframe pixel (below)
iframe pixel for #123: <iFrame scr="http://www.domain.com/pixel.php?p=$c" ></iFrame>
Therefore, the snippet of code would look like:
<?php $c = track1; // this is the value that will identify the campaign where conversion assigned $pixel = " <iFrame scr="http://www.domain.com/pixel.php?p="; // building the iframe pixel $pixel .= "$c\" ></iFrame>"; // appending variable $c and completing the iframe if ($_GET[leadid] == 123) { echo pixel; // fire or pring the iframe to the php page ?>
Note: the domain (URL) is not real - just used to demo the setup.
Now, here's the issue: that snippet of code will work if I load to php page via traditional web browser methods (calling in Firefor, IE, etc...)
However, that's not how the setup is defined:
Setup:
1. external offer will fire the pixel back to me (say at site: http://tracking.com) and once I have their return data - via $_GET function (pulling values from url),
I then implement the above code to alert the specified publish who is awarded the lead. This is where the problem arise....
Issue: b/c the application receives hundreds (at a minimum) per hundred, there is no simple way to load each individual iframe - in the php page and render it - so it fires correctly.
Note: I've already tried creating a loop to parse the database - that captures the data and via sql query, I can fire each (loading them individually).
Problem: that query parses through each so fast (within seconds), there is not enough time for any one set of pixels to fire the select iframe.
-----------
This is where I need some feedback on how to accomplish this to support objective from an application perspective - having to load multiple pixels (each different based on where lead data logged to database).
Again, how can I successfully load each iframe (as they logged to database) to fire, being there is no 'public' page being viewed?
There's only the php script processing the lead and parsing the iframe - echoing it but only showing for less than one second.
I know there's a solution but just having pin pointed it yet....