Wordpress Themes - WP Forum at BFA
Click here to register or to donate.
Auto self-registration is not available here - far too many spammers. This forum has many, many backlinks and because of that there is an intense desire among spammers to drop their links here.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Header configuration & styling »

Adding AdServe to the header


  #1  
Old Apr 18, 2009, 11:04 PM
dahljh
 
2 posts · Apr 2009
I can successfully add the plugin AdServe to footer.php with this code:
Code:
<?php AdServe("LeaderBoard") ?>
I have added a row of ads at the top of the header (bfa.header.config) with code instructions I got from this forum.

Code:
// Ad Banner Area
$logo_area .='
<td rowspan="2" valign="middle" class="header-banner">
<a href="http://www.mywebsite.com/?page_id=38" target="_self"><img src="../wp-content/ads/yourbannerhere.jpg" width="234" height="60" border="0"></a>
</td> 
<td rowspan="2" valign="middle" class="header-banner">
<a href="http://www.mywebsite.com" target="_blank"><img src="../wp-content/ads/Woods Household 468 x 60.jpg" width="468" height="60" border="0"></a>
<td rowspan="2" valign="middle" class="header-banner">
<a href="http://www.mywebsite.com/?page_id=38" target="_self"><img src="../wp-content/ads/yourbannerhere.jpg" width="234" height="60" border="0"></a>
</td> 
';
// END Ad Banner Area
Now, when I try and add the code for AdServe (so that it rotates ads) in place of the <a href> it will not work.

Anyone with suggestions?
  #2  
Old Apr 19, 2009, 09:34 AM
Flynn's Avatar
Flynn
 
3,768 posts · Oct 2008
Munich, Germany
The second code you posted from bfa_header_code is already inside PHP open/close tags. To put PHP code somewhere inside there you'd have to add it like this

PHP Code:
 ' . AdServe("LeaderBoard") . ' 
instead of this

PHP Code:
 <?php AdServe("LeaderBoard"?>
  #3  
Old Apr 19, 2009, 09:03 PM
dahljh
 
2 posts · Apr 2009
Thank you for the fast response. It works, the ads now show. One problem, I added the AdServe code to the middle (2nd) spot, but it puts it in a separate row on top of the others.

Code:
// Ad Banner Area
$logo_area .='
<td rowspan="2" valign="middle" class="header-banner">
<a href="http://www.mywebsite.com/?page_id=38" target="_self"><img src="../wp-content/ads/yourbannerhere.jpg" width="234" height="60" border="0"></a>
</td> 
<td rowspan="2" valign="middle" class="header-banner">
' . AdServe("TopBanner") . '
<td rowspan="2" valign="middle" class="header-banner">
<a href="http://www.mywebsite.com/?page_id=38" target="_self"><img src="../wp-content/ads/yourbannerhere.jpg" width="234" height="60" border="0"></a>
</td> 
';
// END Ad Banner Area
Before, the ads were displayed all in one row, 1st, 2nd, and 3rd. Any ideas?
  #4  
Old Apr 20, 2009, 09:44 PM
Flynn's Avatar
Flynn
 
3,768 posts · Oct 2008
Munich, Germany
You have not closed the second TD with </td>

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Adding header image ZHowl Header configuration & styling 27 Jul 31, 2009 07:30 PM
adding more than one pic/logo to the header area PJK Header configuration & styling 1 May 31, 2009 07:50 PM
adding space between rotating header and category dropdown menu smkpbk Header configuration & styling 1 Feb 24, 2009 08:24 AM


All times are GMT -6. The time now is 01:52 AM.


Powered by vBulletin® Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.