There are two separate pages. These two pages have the same header graphic.
Both will be replaced with a new image.
image4.jpg is being used for both page headers but this won’t be the case as each page will now need to have its own header image. I really have no idea what I need to do to make this happen.
I’ll be making two new images to be named “sm.png” and “dyw.png”.
sm.png will replace image4.jpg Can I just upload sm.png to the images directory and change the above code to this?
echo ‘/images/sm.png”, “”];’;
Then what about the other page that will need the header dyw.png How do I make that happen?
This is the header.php code.
<!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo('charset'); ?>" />
<?php if (is_search()) { ?>
<meta name="robots" content="noindex, nofollow" />
<?php } ?>
<title>
<?php
if (function_exists('is_tag') && is_tag()) {
single_tag_title("Tag Archive for ""); echo '" - '; }
elseif (is_archive()) {
wp_title(''); echo ' Archive - '; }
elseif (is_search()) {
echo 'Search for "'.wp_specialchars($s).'" - '; }
elseif (!(is_404()) && (is_single()) || (is_page())) {
wp_title(''); echo ' - '; }
elseif (is_404()) {
echo 'Not Found - '; }
?>
</title>
<link rel="shortcut icon" href="/favicon.ico">
<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>">
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>">
<?php if ( is_singular() ) wp_enqueue_script('comment-reply'); ?>
<script type="text/javascript">
//If using image buttons as controls, Set image buttons' image preload here true
//(use false for no preloading and for when using no image buttons as controls):
var preload_ctrl_images=false;
var slides2=[]; //SECOND SLIDESHOW
//configure the below images and descriptions to your own.
<?php
switch(get_queried_object_id()){
case 14:
echo 'slides2[0] = ["';
bloginfo('template_directory');
echo '/images/banner-wtf.png", ""];';
break;
case 12:
echo 'slides2[0] = ["';
bloginfo('template_directory');
echo '/images/banner-wwtf.png", ""];';
break;
case 10:
echo 'slides2[0] = ["';
bloginfo('template_directory');
echo '/images/banner-wwtf2.png", ""];';
break;
case 8:
echo 'slides2[0] = ["';
bloginfo('template_directory');
echo '/images/banner-cwusr.png", ""];';
break;
case 6:
echo 'slides2[0] = ["';
bloginfo('template_directory');
echo '/images/banner-wtpusr.png", ""];';
break;
default:
echo 'slides2[0] = ["';
bloginfo('template_directory');
echo '/images/image4.jpg", ""];';
break;
}
?>
//optional properties for these images:
slides2.no_descriptions=1;
slides2.no_controls=1;
slides2.delay=6000;
slides2.random=1;
</script>
<script src="<?php bloginfo('template_directory'); ?>/js/swissarmy.js" type="text/javascript">
/***********************************************
* Swiss Army Image slide show script - ? John Davenport Scheuer: https://home.comcast.net/~jscheuer1/
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at https://www.dynamicdrive.com/ for full original source code
***********************************************/
</script>
<?php wp_head(); ?>
</head>
<body <?php body_class(); ?>>
<div id="wrapper">
<div id="container">
<div id="header">
<div id="logo"><a href="<?php echo get_permalink('16'); ?>"><img src="<?php bloginfo('template_directory'); ?>/images/logo.png" /></a></div>
<div id="phone"><a href="tel:+18004472366"><img src="<?php bloginfo('template_directory'); ?>/images/phone.png" /></a></div>
</div>
<div id="navbar">
<ul>
<?php wp_nav_menu(array('menu' => 'Main Navigation Menu')); ?>
</ul>
</div>
<table border="0" cellspacing="10" width="1024">
<tr>
<td valign="top" width="717">
<div id="flash">
<script type="text/javascript">
new inter_slide(slides2);
</script>
</div>