white space below image

images php coding issues or problems here.

Moderators: macek, egami, gesf

New php-forum User
New php-forum User
Posts: 3
Joined: Sat Oct 29, 2011 10:05 am

white space below image

Postby naturepoonam » Mon Oct 31, 2011 4:17 am


On my page I have this class="col-2" on certain pages I display flash and in other pages I display a image as header

The flash is 265px in height and the image is 104px in height.

when i display the page where the image is the header its giving me white space below the image before the content appears

can someone tell me how to get rid of the white space.

Attached is my code

thanks for the help


Code: Select all

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/11001/xhtml" <?php language_attributes(); ?>>
<head profile="http://gmpg.org/xfn/11">
<meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<title><?php wp_title('«', true, 'right'); ?> <?php bloginfo('name'); ?></title>
<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />
<link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> RSS Feed" href="<?php bloginfo('rss2_url'); ?>" />
<link rel="alternate" type="application/atom+xml" title="<?php bloginfo('name'); ?> Atom Feed" href="<?php bloginfo('atom_url'); ?>" />
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />

<?php if ( is_singular() ) wp_enqueue_script( 'comment-reply' ); ?>
<?php //comments_popup_script(600, 600); ?>
<?php wp_head(); ?>

<script type="text/javascript" src="<?php bloginfo('stylesheet_directory'); ?>/js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="http://info.template-help.com/files/ie6_warning/ie6_script.js"></script>
<script type="text/javascript" src="<?php bloginfo('stylesheet_directory'); ?>/js/cufon-yui.js"></script>
<script type="text/javascript" src="<?php bloginfo('stylesheet_directory'); ?>/js/cufon-replace.js"></script>
<script type="text/javascript" src="<?php bloginfo('stylesheet_directory'); ?>/js/Myriad_Pro_400.font.js"></script>
<script type="text/javascript" src="<?php bloginfo('stylesheet_directory'); ?>/js/Myriad_Pro_italic_400.font.js"></script>
<script type="text/javascript" src="<?php bloginfo('stylesheet_directory'); ?>/js/drop-down-menu.js"></script>

</head><body class="<?php echo "page-".$page_id; ?>">
<div class="main">
<div id="header">
<div class="indent1">
<div class="indent">
<div id="dropmenu">
//wp_page_menu('show_home=0&sort_column=menu_order, post_title&link_before=&link_after=');

<!-- End static itemd -->

<div class="logo"><h1 onclick="location.href='<?php echo get_option('home'); ?>/'"><?php bloginfo('name'); ?></h1></div>
<div class="indent2">
<div class="container">
<div class="col-1">
<div class="indent3">
<div class="txt">With over 10 years of experience
in the water filter market. </div>
Water filters are an international
supplier of quality water filters, offering
under sink or whole house filtration
<div class="col-2">
if($page_id==16 or $page_id==18 or $page_id==20 or $page_id==23 or $page_id==25 )
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,24"
width="584" height="265">
<param name="movie" value="<?php bloginfo('stylesheet_directory'); ?>/flash/header_v8.swf" />
<param name="quality" value="high" />
<param name="menu" value="false" />
<param name="wmode" value="transparent" />
<!--[if !IE]><-->
<object data="<?php bloginfo('stylesheet_directory'); ?>/flash/header_v8.swf"
width="584" height="265" type="application/x-shockwave-flash">
<param name="quality" value="high" />
<param name="menu" value="false" />
<param name="pluginurl" value="http://www.macromedia.com/go/getflashplayer" />
<param name="wmode" value="transparent" />
FAIL (the browser should render some flash content, not this).

print '<img src="" height="104">';


print '<img src="" height="104">';

<div id="content">
<div class="indent-main">
<div class="container">

<?php get_sidebar(); ?>

User avatar
New php-forum User
New php-forum User
Posts: 27
Joined: Sun Oct 30, 2011 10:48 pm
Location: Coimbatore

Re: white space below image

Postby shnkrsv » Mon Oct 31, 2011 11:11 pm

What's the height set to "Col-2" class? give me exact style code for "Col-2"

Return to “PHP coding => Images”

Who is online

Users browsing this forum: No registered users and 2 guests