Solved

CSS layout

Posted on 2010-08-26
9
187 Views
Last Modified: 2012-05-10
I would like to create a div tags horizontally without the tables  , but i find that if i create a table first and put the div tag in it,it allows me to place the image or text neatly,  what do any one suggest?

0
Comment
Question by:imagekrazy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
9 Comments
 
LVL 9

Accepted Solution

by:
Snarfles earned 500 total points
ID: 33533634
div is a block element which means that it expands across the entire page. In lay mans terms that means you can't have more than one in a row. What you can use instead is the span tag which is only slightly different but allows you to have more than one per row.
0
 
LVL 9

Expert Comment

by:Snarfles
ID: 33533655
You can make a div not block by using some css code.
#yourdivID {
display:inline;
}

Open in new window

0
 

Author Comment

by:imagekrazy
ID: 33534643
okay, but i created a gallery,I attached my code but everything is on the left, i want the left to be the same as the right side  and the whole thing being centered.



 
 
layout.html
0
Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

 
LVL 40

Expert Comment

by:gurvinder372
ID: 33534715
try using float property
eg
div.leftDiv
{
   float: left;
}

div.rightDiv
{
   float: right;
}

<div>
   <div class='leftDiv'>A left div</div>
   <div class='rightDiv'>A right div</div>
</div>
0
 

Author Comment

by:imagekrazy
ID: 33535911
thanks, final question, how do   i get the right side div  to move a little away from the the sidebar1 div tag that i made, i am attaching my code, i tried everything
thanks
layout2.html
0
 
LVL 9

Expert Comment

by:Snarfles
ID: 33537823
with

.thrColLiqHdr #sidebar1 {

add

margin-right:15px;
0
 

Author Comment

by:imagekrazy
ID: 33538201
I tried that , it didn't work, and i meant the left side , side bar1
0
 
LVL 9

Expert Comment

by:Snarfles
ID: 33538221
Not sure that I understand what you mean then. Could you explain further or provide an image mockup of what you are after?
0
 

Author Comment

by:imagekrazy
ID: 33538330
I am attaching a snap shot in my word doc, my problem is nothing is uniform, if i try to move something over it moves one of the div tags to the right or to the bottom of the page, and i tried to add another  div tag in the first row and that div box moves to the bottom
thank you for your help
layout.docx
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

CSS is a visual language used to classify objects and define rules about how they should be displayed. CSS skills aren’t restricted to developers anymore, there is a big benefit to having a basic understanding of the language, regardless of your occ…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

691 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