Jump to content
Sign in to follow this  
renadelp

468x60 banner in header, at right of logo image: how to?

Recommended Posts

renadelp

Hello people, I do thank you in advance for any help. # 1) The problem I'm facing is this: in header, how to move the 468x60 adsense banner to the right of the logo image (and under social icons / search box)? Here is the code I'm using, in PlatformBase (function.php): add_action('pagelines_inside_top_branding','google_leaderboard_ad'); // function name function google_leaderboard_ad(){?> <div class="google_leaderboard_ad"> <script type="text/javascript"><!-- google_ad_client = "pub-2664743480984880"; /* Purse, 468x60, text home1, creato 10/06/11 */ google_ad_slot = "2173882038"; google_ad_width = 468; google_ad_height = 60; //--> </script> </div> <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> <?php } In custom code / CSS Rules : div.google_leaderboard_ad { float: right; } I always get the adSense banner in same position, all the time. I've changed different values in CSS rules, like top margin etc, but no results. For sure I'm doing something wrong, since I've very very very little php knowledge. # 2) Second problem (less urgent): once i click on "previous entries" (Pagine Precedenti) the 468x60 banner disappears. Here is the site: Purse&Co I'm using PlatformPro with child base for custom code. Thank you very, very much for help!

Share this post


Link to post
Share on other sites
catrina

For the first problem, I think you're going to need a different hook instead of changing the CSS. Instead of using pagelines_inside_top_branding, try pagelines_branding_icons_end. As for the second problem, is the banner enabled in Template Setup under the Posts Pages template?


Please read the docs before posting. Please do not private message me unless I ask you to.

Designer | Catrina Dulay

Founder | Catrina and Mouse

Share this post


Link to post
Share on other sites
renadelp

Hello Catrina and all, thanks for the answer, really. Here is the new code with a little improvement, but no good results still :( In platformbase: add_action('pagelines_inside_bottom_branding', 'new_search'); function new_search(){ get_search_form(); } add_action('pagelines_branding_icons_end','google_leaderboard_ad'); // function name function google_leaderboard_ad(){?> <div class="google_leaderboard_ad"> <script type="text/javascript"><!-- google_ad_client = "pub-2664743480984880"; /* Purse, 468x60, text home1, creato 10/06/11 */ google_ad_slot = "2173882038"; google_ad_width = 468; google_ad_height = 60; //--> </script> </div> <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> <?php } In custom section CSS Rules: div.google_leaderboard_ad { top: 99px; right: 25px; } .icons{top:6px !important;right:1px !important;} # 1) What i would like to see is the adsense adv more under the social icons, and more space from the right border. And the search box at right (or at left, if not possible) of social icons as well (on same line). All the changements i've done, get nothing: always in same position. Here an example of what i'm looking for (done by photoedit) BnZgD.jpg# 2) I see no banner in "Posts Pages" under Template Setup. Here is a picture of what i get. Please note that i've written "adsense" as banner, but i haven't used the banner function at all, i suppose. FjgeG.jpg Thanks for helping me!

Share this post


Link to post
Share on other sites
cmunns

If you wrap the google code in a div you could more easily style it's position with CSS

Share this post


Link to post
Share on other sites
renadelp

Hello Adam, thanks for reply. I've wrapped google code in a div, as seen in first comment, but probably i've done it wrongly. I can't move it to desired position using CSS instructions at all :( <div class="google_leaderboard_ad"> and in CSS div.google_leaderboard_ad Thanks for helping, i'm going crazy :) (sorry for my terrible english)

Share this post


Link to post
Share on other sites
renadelp

Hi Catrina, tanks for reply and sorry for being late in mine, but i almost got crazy. Now as you see here i've finally moved the asdense adv under the social incons but it seems that i cannot move the search box correctly. If i put it with the hook "pagelines_branding_icons_start" it appears right before RSS icons and facebook/twitter are at its left. No results either if i'm using the hook "pagelines_inside_top_branding". How to incapsulate the search box in a <div> as done for google code in function.php (child theme) and style it in CSS custom code area? If i'm bothering you all, just tell me :) Thanks in advance.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  

×