I'm trying to create a PHP 'if' statement that tells an image to display on certain pages in Wordpress. What I'm trying to do is shown below, but I think the syntax is incorrect.
I'm trying to say "If the page displayed equals 'about' or 'gallery' and that page is not 'services', go ahead and display the image.
Here's the section of code that you should be able to analyze and see where I went wrong:
<?php if(is_page('about' || 'gallery') && (is_page != 'services')) { ?>
<li><img id="profile_pic" alt="DermaKare (Official Fan Page)" src="http://profile.ak.fbcdn.net/hprofile-ak-snc4/50556_123510051042639_3343345_n.jpg" class="photo img" /></li>
<?php } ?>
<?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar("Banner") ) : ?>
<?php /*?><p><a href='<?php bloginfo('siteurl')?>/wp-admin/widgets.php'>Widgetize this sidebar</a></p><?php */?>
<?php endif; ?>
Thanks in advance for any help on this.....