Hi Guys I am a total noob with programming and yet I wanted to design a website. I got everything done up now.. i have a problem.. here's an image ... As you can see the images are aligned to the top of the cell.. how can i make it aligned to the middle? here are some codes. } if ($display_counter) modBidsHelper::renderAuctionTiming($rows[$i]); ?> <tr class="<?php echo $alt_class;?>" onmouseover="this.className='<?php echo $alt_class;?>_hover'" onmouseout="this.className='<?php echo $alt_class;?>'"> <?php if ($display_image) { ?> <td nowrap width="<?php echo $image_width+30;?>" height="<?php echo $image_height+10;?>" align="center"> <?php /*<?php echo $i+1;??>. */?> <img src="<?php echo $image;?>" border="0" width="<?php echo $image_width;?>" height="<?php echo $image_height;?>" > </td> <?php } ?> <td> <?php if (!$display_image) echo $i+1,'. ';?><a href="<?php echo $link_to_auction;?>" title="<?php echo $overlib_str;?>" ><?php echo $rows[$i]->title;?></a> </td> <?php if ($display_counter) { ?> <td> <span id="modulebidstime<?php echo $mid;?>_<?php echo $i+1;?>"><?php echo $rows[$i]->countdown;?></span> </td> <?php } PHP:
Either use float:left on the image, or display: inline on both elements. If it is a table and you really want to align it to the middle of the cell (as you said in the first phrase below your image), you can use vertical-align: middle, but I doubt this is going to give you the result that you actually want. Good luck, though. If you give us the link to your live site it would be easier for us to help.
personally I'd edit your $alt_class; as it seems that it controls your image layout. So check your CSS file which contains whatever "<?phpecho$alt_class;?>" points to, then edit that with something like: "vertical-align:middle" So in my view you must edit the image-container attribute, not the image itself, as that won't have any effect...