On May 9, 2008, at 2:05 PM, Mário Gamito wrote:
> Hi,
>
> I have this page with JavaScript to load a different image when we
> select a different radio button.
> The problem is that the images appear above the radio button group
> and I
> want them to appear at the right.
>
> I've been reading to some things and it seems that I have to use CSS
> to
> do this, but I didn't manage to do it.
>
> If you care to take a look at the page, it's very simple, I just want
> the radio buttons group and the photos to appear side by side, i. e.,
> the images being loaded at right and maintaining the radio buttons at
> the left.
>
> http://www.absinto.org/escolhe-zen.html
>
> Any help would be appreciated.
Hi Mario (Sorry couldn't find the right mark to put above your name)
Here's the basics of what you need to do:
take this line of code:
<img id="image1" src="javascript:GetImage('2');">
and change it to this:
<div class="image"><img id="image1" src="javascript:GetImage('2');"></
div>
and then add this in your <head> section:
<style>
.image {
float: right;
}
That will cause the pictures to float to the right side of the screen,
and the radio buttons will just sit to the left.
A fairly basic idea, but it works great. I'd highly recommend reading
all you can on CSS as it has made my life so much simpler with regards
to managing my site, and changing it. If I need to update the look of
my site, I just edit 1 file and my entire site could have different
colors, and even rearrange the content on it.
Really powerful stuff.
This list is also a great resource for learning! :)
--
Jason Pruim
Raoset Inc.
Technology Manager
MQC Specialist
3251 132nd ave
Holland, MI, 49424-9337
www.raoset.com
[EMAIL PROTECTED]
______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/