|
I have a 200 x 200 ad sense unit on this page.
http://directory.nyskiblog.com/Vermont-Ski-Areas-f5001365.html Anyway to replace it there, and there only with an ad of my own?
HTTPS Please!
|
|
Yes, I will prepare the naml for you.
My test forum.
|
|
<div style="text-align: center;"> <a href="http://www.worthskis.com/" rel="nofollow" target="_blank"><img src="http://nyskiblog.com/wp-content/uploads/2012/05/Worth-Skis.jpg" alt="Worth Skis" height="200" width="200" /></a></div>
On Thu, Mar 21, 2013 at 11:29 PM, Pedro <Nabble> [via Nabble Support] <[hidden email]> wrote: Do you have the code of your ad? "Like" us on Facebook: www.facebook.com/NYSkiBlog Follow us on Twitter: http://twitter.com/nyskiblog ---------- Harvey Road: NYSkiBlog.com NY Ski Forum: forum.NYSkiBlog.com NY Ski Magazine: mag.NYSkiBlog.com NY Ski Directory: directory.NYSkiBlog.com
HTTPS Please!
|
|
In reply to this post by Pedro
Is this something we could replicate in other spots?
On Thu, Mar 21, 2013 at 11:29 PM, Pedro <Nabble> [via Nabble Support] <[hidden email]> wrote: Do you have the code of your ad? "Like" us on Facebook: www.facebook.com/NYSkiBlog Follow us on Twitter: http://twitter.com/nyskiblog ---------- Harvey Road: NYSkiBlog.com NY Ski Forum: forum.NYSkiBlog.com NY Ski Magazine: mag.NYSkiBlog.com NY Ski Directory: directory.NYSkiBlog.com
HTTPS Please!
|
|
You should edit your show_custom_ads macro like this:
<override_macro name ="show_custom_ads" parameters="location" requires="servlet" >
<n.if.equal value1="[n.location/]" value2="widget">
<then>
<div class="ad">
<n.if.equal value1="[n.page_node.id/]" value2="5001365">
<then>
<div style="text-align: center;">
<a href="http://www.worthskis.com/" rel="nofollow" target="_blank">
<img src="http://nyskiblog.com/wp-content/uploads/2012/05/Worth-Skis.jpg" alt="Worth Skis" height="200" width="200" />
</a>
</div>
</then>
<else>
<script type="text/javascript">
google_ad_client = "ca-pub-0156740191883467";
/* Small-Square */
google_ad_slot = "1736553008";
google_ad_width = 200;
google_ad_height = 200;
google_page_url="<n.current_url/>"
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</else>
</n.if.equal>
</div>
</then>
<else>
<div class="ad shaded-bg-color rounded" style="padding:.5em 0">
<script type="text/javascript">
google_ad_client = "ca-pub-0156740191883467";
/* Leaderboard */
google_ad_slot = "9529659947";
google_ad_width = 728;
google_ad_height = 90;
google_page_url="<n.current_url/>"
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</div>
</else>
</n.if.equal>
</override_macro>
The code is testing when the app is at that place you want to show the specific ad.
My test forum.
|
|
I couldn't figure out which lines to add so I just replaced the whole thing and it worked. !
If I wanted that ad to appear elsewhere could I just add in the node number to that code without duplicating the whole thing? <n.if.equal value1="[n.page_node.id/]" value2="5001365, XXXXXXX, XXXXXX">
HTTPS Please!
|
| Free forum by Nabble | Edit this page |
