2 ms·
You can use JavaScript, PHP (or any other server side language), and JSON. Each website in the network gets a unique ID and includes a script tag in their HTML
by byoung2 17y ago
You can use JavaScript, PHP (or any other server side language), and JSON.
Each website in the network gets a unique ID and includes a script tag in their HTML with the src set to http://www.example.com/code/?id=12345 http://www.example.com/code/?id=12345 where 12345 is the unique ID.
You have your server side script look up that ID and pull the relevant ad data from your database and return JavaScript that writes this data in a JSON object and includes functions to write it to the browser.
When the visitor goes to the site, the browser renders the page with the JavaScript customized for that site, which displays the appropriate ad. Your server side code should track the number of impressions for each add and integrate with your billing/payment system.