layout where uploaded images are always on the right side of the content

2 posts by 2 authors in: Forums > CMS Builder
Last Post: July 20, 2012   (RSS)

Re: [cmsb] layout where uploaded images are always on the right side of the content

By Jason - July 20, 2012

Hi,

I'm not sure about what other CSS rules you have on your page, but one thing you could try is to wrap your uploads in a div that you float to the right:

For example:
<div style = "float:right;">
<?php foreach ($aboutRecord['images'] as $upload): ?>


<?php if ($upload['hasThumbnail']): ?>
<a class="fancybox" rel="group" title="" id="#single_1" href="<?php echo $upload['urlPath'];?>"><img src="<?php echo $upload['thumbUrlPath'] ?>" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>"
title="<?php echo htmlencode($upload['info1']) ?>" alt="" /></a><br/>
<?php echo htmlencode($upload['info1']) ?>
<br/>
<br/>

<?php elseif ($upload['isImage']): ?>
<a class="fancybox" rel="group" title="" id="#single_1" href="<?php echo $upload['urlPath'];?>"><img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" title="<?php echo htmlencode($upload['info1']) ?>" alt="" />
<br/> </a><br/>
<?php echo htmlencode($upload['info1']) ?>
<?php else: ?>
<a href="<?php echo $upload['urlPath'] ?>">Download <?php echo $upload['filename'] ?></a><br/>
<?php endif ?>

<?php endforeach ?>
</div>


Hope this helps
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/