William
William

Reputation: 8808

Whats wrong with my CSS?

I'm trying to get my name and trip input fields to line, but they're all over the place. http://prime.programming-designs.com/test_forum/viewboard.php?board=0

#formdiv{
    margin: auto;
    text-align: left;
    width: 30%;
}

.fielddiv1{

    background-color: #222222;
    border: 2px solid #333333;
    vertical-align: middle;
    width: 45%;
    float: left;
}

.fielddiv2{

    background-color: #222222;
    border: 2px solid #333333;
    vertical-align: middle;
    width: 100%;
}

.fieldtext{
    width: 100%;
    background-color: #333333;
}

Upvotes: 3

Views: 100

Answers (3)

Kangkan
Kangkan

Reputation: 15571

Wrap both of them (the two divs with fielddiv1 class) into a single div. And also delete the line break in between them.

Upvotes: 1

poke
poke

Reputation: 387745

Remove the <br /> that's between those two fielddiv1 div's

Upvotes: 4

Vasily Korolev
Vasily Korolev

Reputation: 1831

You have a <br> between the divs that contain them.

Upvotes: 3

Related Questions