Hello
we are using an Ad Server like Open X (Revive) that serves ad units in this format:
——–CUT——–
<script type=’text/javascript’><!–//<![CDATA[
var m3_u = (location.protocol==’https:’?’https://www.xxx.it/revive/www/delivery/ajs.php’:’http://www.xxx.it/revive/www/delivery/ajs.php’);
var m3_r = Math.floor(Math.random()*99999999999);
if (!document.MAX_used) document.MAX_used = ‘,’;
document.write (“<scr”+”ipt type=’text/javascript’ src='”+m3_u);
document.write (“?zoneid=20&target=_blank”);
document.write (‘&cb=’ + m3_r);
if (document.MAX_used != ‘,’) document.write (“&exclude=” + document.MAX_used);
document.write (document.charset ? ‘&charset=’+document.charset :
——–CUT——–
It works perfectly on all the ad units: on each unit (for instance before the post body) I have mapped what above with a [shortcode] and therefore I place the shortcode in the ad definition in the theme panel.
I don’t know how to use the same approach for the wallpaper AD. Can you provide some hints?
Regards
Hi
I am not sure what you mean bu if’re referring at the theme’s background click ad that was designed to work only with links. To change this implementation are required some customizations in theme’s files but I can’t offer now a solution. Basically you need to implement a system which can render a code like other ad-spots or to be able to accepts a shortcode as a parameter: http://screencast.com/t/0A8j4TfwM
This is a complex task as at them moment the background it’s controlled by javascript and implementing a new type of ads can create some conflicts.
Thanks!
Forgive me if I’m not using the right terms.
I think my request is not to change the current background ad behaviour.
What I would reach is to manage the background space as any other DIV with some ads inside.
If in that DIV I can place the script above (maybe via a shortcode) then I don’t need the current background ad support. The URL, the Image and the way the href will open the link will be managed by the script.
Exactly the same as per e.g. the leaderboard ad.
Hi
You can insert a new container near page content in header.php file like here: http://screencast.com/t/XmNVmU8j0c http://screencast.com/t/cl1dXMVb In this container you can display any add, including a shortcode for a specific ad-spot using do_shortcode() function. http://screencast.com/t/Fbx66wcDI2m
Hope this help.
Thanks!
Hi
Make sure you give a fixed position to the new container as I did in this example here: http://screencast.com/t/IrsPSkFMTgd By giving a fixed position to a container that will remain in the same place even if you scroll up or down.
.left{
position: fixed;
top: 300px;
left: 60px;
}
Thanks!
I’ve implemented the new DIV for the wallpaper Ad as suggested from you , here above:
I’ve added this div:
<div class="left">
<?php echo do_shortcode ('[myCode]') ?>
</div>
This causes the wallpaper is rendered before the leaderboard ad.
Our advertiser is asking to make the leaderboard as the first call.
I think I managed this by moving the new piece of code on the bottom of the header file, after this lines.
do_action('td_wp_booster_after_header'); //used by unique articles
?>
Is it correct?