• as above, I’m wondering what specific code I need to change to get a banner into that location.

    I’ve managed to replace the site title but can’t see where to insert code to replace the description

    site is https://www.digital-reefs.com

    Basically I want another 468×60 banner on the right, in line with the current one at the top.

    Any ideas anyone?

Viewing 6 replies - 1 through 6 (of 6 total)
  • When I did this with adrotate I created a div in my header.php file, put the ad in there, and then moved it with css. You should create a child theme before doing all of this rather than editing twenty ten directly.

    So, in header.php, just below:
    <div id="site-description"><?php bloginfo( 'description' ); ?></div>
    which is line 66 in the stock twenty-ten header.php, put:

    <div id="top_banner_ad">
    <?php echo ad_rotate_whatever(); ?>
    </div>

    Then, in your style.css:

    #top_banner_ad {
    	position: relative;
    	margin-left: 270px;
    	z-index: 100;
    	padding-top: 8px;
    }

    You may have to monkey around a bit with the left margin. Let me know if it doesn’t work.

    Thread Starter clippo

    (@clippo)

    Hi Andrew

    Thank you for the reply!

    That is what I’ve got int here at the moment actually.

    I assumed that this was replacing the ‘site title’ but looking at the code, it does suggest it is the ‘site description’ that is being replaced.

    <body <?php body_class(); ?>>
    <div id="wrapper" class="hfeed">
    	<div id="header">
    		<div id="masthead">
    			<div id="branding" role="banner">
    				<?php $heading_tag = ( is_home() || is_front_page() ) ? 'h1' : 'div'; ?>
    				<<?php echo $heading_tag; ?> id="site-title">
    					<span>
    						<a href="<?php echo home_url( '/' ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a>
    					</span>
    				</<?php echo $heading_tag; ?>>
    				<div id="site-description"><?php bloginfo( 'description' ); ?></div><?php echo adrotate_group(1); ?>
    
    				<?php
    					// Check if this is a post or page, if it has a thumbnail, and if it's a big one
    					if ( is_singular() && current_theme_supports( 'post-thumbnails' ) &&
    							has_post_thumbnail( $post->ID ) &&
    							( /* $src, $width, $height */ $image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'post-thumbnail' ) ) &&
    Thread Starter clippo

    (@clippo)

    Andrew?… anyone?

    Thread Starter clippo

    (@clippo)

    bump

    Thread Starter clippo

    (@clippo)

    last bump – help someone please!

    Try placing the code in the wrapper area by creating a simple two column one row table and filling the fields with your banners.. Ad some css directly to the table, see how will that look like. ??

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Inserting adrotate banner into site description area’ is closed to new replies.