• Resolved billslis

    (@billslis)


    Hello. I have successfully commented out the banner on a theme I am dallying with and gotten jsbrotate to appear in its place, however it repeats itself five times down the screen at what looks like 1000px.

    My images are all 890×212 and I’ve tried to constrain them as such wherever possible in the css.

    I am no php ninja and I have seen this occur to people in the forums. None of their fixes worked for me, however.

    I am working offline in wamp, so no link.
    Here is my header.php if anyone is generous with an idea.

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html <?php language_attributes(); ?> xmlns="https://www.w3.org/1999/xhtml">
    
    <head>
    	<meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
    	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
    	<title><?php
    		global $page, $paged;
    
    		wp_title( '|', true, 'right' );
    
    		bloginfo( 'name' );
    
    		$site_description = get_bloginfo( 'description', 'display' );
    
    	if ( $site_description && ( is_home() || is_front_page() ) )
    			echo " | $site_description";
    
    		if ( $paged >= 2 || $page >= 2 )
    			echo ' | ' . sprintf( __( 'Page %s', 'picolight' ), max( $paged, $page ) );
    
    		?></title>
    
    	<?php global $picolight_options;
    	$picolight_settings = get_option( 'picolight_options', $picolight_options ); ?>		
    
    	<?php if( $picolight_settings['custom_favicon'] ) { ?>
    		<link rel="shortcut icon" href="<?php echo $picolight_settings['custom_favicon']; ?>" title="Favicon" />
    	<?php } ?>
    	<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />
    	<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />
    
    	<?php wp_head(); ?>
    </head>
    
    <body 
    
    <?php body_class(); ?>>
    
    <div id="wrapper">
    	<div id="header">
    
    <!--  HIDING THE TOP HEADER STUFF
    
    	<h1><a>"><?php bloginfo('name'); ?></a></h1>
    		<p class="description"><?php bloginfo('description'); ?></p>
    -->
    
    <!-- MY NEW BANNER  -->
    
    <?php jsbrotate('images=images/banner1.jpg|images/banner2.jpg|images/banner4.jpg|images/banner5.jpg'); ?>
    
    <!-- THE OLD HEADER
    		<img id="headerimage" src="<?php header_image(); ?>" alt="" />
    
    -->
    
    		<div id="mainnav">
    				<?php wp_nav_menu(array('theme_location' => 'primary')); ?>
    		</div>
    	</div>
    	<div id="main">

    [Please post code or markup between backticks or use the code button. Or better still – use a pastebin. Your posted code may now have been permanently damaged/corrupted by the forum’s parser.]

    https://www.ads-software.com/extend/plugins/js-banner-rotate/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Eric Mann

    (@ericmann)

    You’re almost there. Your template tag parameters (the part inside jsbrotate() aren’t complete.

    To set the height/width of the banner, you need to set the height/width parameters in the template tag.

    jsbrotate( 'images=...&height=212&width=890' );

    I also normally recommend using the full, absolute path of images in the tag, but if your relative URLs are working stick with that.

    As for why the images are repeated 5 times, I’d have to see your site to know why.

    Thread Starter billslis

    (@billslis)

    That actually cured the repeat.
    Success. Thank you for your help and for creating this plugin.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘repeating banner image’ is closed to new replies.