Solved

Create and align image box with logos on home page

Posted on 2008-10-28
16
240 Views
Last Modified: 2013-11-19
I work for a company that wanted me to add some logos to their website. Here's the corrent site:
www.globalsourcingintl.com
Here's what they want done:
www.novanetsolutions.com/GSI.jpg
I'm having trouble getting the box created that will fit exactly like that so the images can go in it. When I create the box it doesn't align exactly along the side of the web page. I created the box in my main screen.css file. Here's the code

.logos {
        float: right;
        width: 200px;
        margin-right: -225px;
        margin-top: -205px;
}

I'm not much of a web site designer so I've been adjusting the margins manually and refreshing the page to get it aligned but it never aligns exact and it shows up different in firefox than it does in IE. Thanks in advance.
0
Comment
Question by:bbrunning
  • 9
  • 7
16 Comments
 
LVL 30

Expert Comment

by:Steggs
Comment Utility
Hello,

IE6 'Double margin on float bug'

Fix by adding display:inline to #searchform

Thanks
0
 
LVL 10

Author Comment

by:bbrunning
Comment Utility
I'm using IE7, and it actually looks worse in Firefox than in IE so I don't believe that's the problem.

Thanks
0
 
LVL 10

Author Comment

by:bbrunning
Comment Utility
Oh I read that wrong. I understand what you mean now. I'll give it a try.

Thanks
0
 
LVL 30

Expert Comment

by:Steggs
Comment Utility
Your talking about the orange box on the right, correct?
0
 
LVL 30

Expert Comment

by:Steggs
Comment Utility
Where are the logos... I dont see them at all
0
 
LVL 10

Author Comment

by:bbrunning
Comment Utility
No, the Orange box is floating properly. I want to make a new box (or add the logos in the jpg) under the orange box.
0
 
LVL 10

Author Comment

by:bbrunning
Comment Utility
I haven't added the logos back in or the box due to problems. Refer to my link to the jpg for an example of what it needs to look like.
www.novanetsolutions.com/GSI.jpg
0
 
LVL 30

Expert Comment

by:Steggs
Comment Utility
First of all:

add logos div underneath div#searchform

<div id="searchform"></div>
<div class="logos"></div>

.logos {
background:;
float:right;
margin:0px 10px 10px 0;
width:215px
}
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 
LVL 10

Author Comment

by:bbrunning
Comment Utility
I made adjustments to .logos as you said and edited my searchform.php adding div class logos but it puts it in the center of the page instead of underneath it.
I added 2 periods, you'll notice them in the center top of the page below the header.
0
 
LVL 10

Author Comment

by:bbrunning
Comment Utility
Another note I should probably add. This website is designed with Ruby on Rails. I'm editing the individual pages through the admin control panel and I'm editing the css files and php files through ssl.
0
 
LVL 10

Author Comment

by:bbrunning
Comment Utility
I worked with the sizing and got it aligned under the search box but there is a slight problem. I think the owner only wanted those logos to show up on the home page only. When added to searchform.php it adds whatever I do to the entire set of pages. I'm going to speak with him tomorrow and see if that's okay but if not, do you know how to do that?
0
 
LVL 30

Expert Comment

by:Steggs
Comment Utility
Can you work out how its done by seeing how its done on this page http://www.globalsourcingintl.com/about_us/... that has content in the right column
0
 
LVL 30

Accepted Solution

by:
Steggs earned 500 total points
Comment Utility
Sorry, Ive just realised that my css was wrong for the .logos. What needs to be done is set up a right column on each page. Something like:

#rightCol {
float:right;
width:225px
}

<div id="rightCol">
<div id="searchform"></div>
<div class="logos"></div>
</div>

0
 
LVL 10

Author Comment

by:bbrunning
Comment Utility
I changed the code a bit that you gave me and it matches up properly under the searchbox, but I need to know if there is a way to hide the logos box on every page but the home (about_us) page. check out the site and you'll see why I need to hide it on some of the other pages:
www.globalsourcingintl.com

.logos {
        background:;
        float:right;
        margin:0px 10px 10px 0;
        width:215px;
        margin-right: 0px;
        margin-top: 65px;
0
 
LVL 30

Assisted Solution

by:Steggs
Steggs earned 500 total points
Comment Utility
Well, if you want to it in css then you can. What you need is a 'hook' on each page. What I mean is, something unique to each page that you can use with css to hide the logos on certain pages. For example,

on all the pages on your site is an id in each body tag... like the 'Terms of sale' page has <body id="page_tos">. So, if you didnt want the logos to appear on that page, you would do this:

body#page_tos div.logos {
    display: none
}

Hope this helps
Steggs
0
 
LVL 10

Author Closing Comment

by:bbrunning
Comment Utility
Thanks for all the help!
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Browsers only know CSS so your awesome SASS code needs to be translated into normal CSS. Here I'll try to explain what you should aim for in order to take full advantage of SASS.
Read about why website design really matters in today's demanding market.
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now