Question:
HTML/CSS question. HELP?
?
2013-01-08 23:24:20 UTC
I have a problem doing a HTML/CSS form...
It should look like this: http://i.imgur.com/p4JgB.jpg
But it looks like this: http://i.imgur.com/WyKRa.jpg

I don't know what I've done wrong, I didn't write anything in css to counter checkboxes being in the same row, I haven't inserted any
's or anything that would hint the program to skip into new line. The rest of the form is okay, but such checkboxes are giving me trouble in two parts of it.
Four answers:
BlueTyphoid
2013-01-09 00:09:18 UTC
Just use a table.
Meghashyam Bhandary
2013-01-09 12:21:34 UTC
I Suggest you to Add the Html codes and the CSS codes you have used here, then i can help you..
Matt
2013-01-09 13:19:04 UTC
I'm assuming you're using ul/li elements, like so:



Type

































In your, css add



ul li label{

display: inline-block;

margin-right: 10px;

}



ul li checkbox{

border: 1px solid #000;

}



ul li{

float: left;

margin-left: 10px;

}



Enjoy!
xzykho
2013-01-09 10:13:37 UTC
are you using
then your css should be



.class-name ul {

display: block; }



. class-name li {

display: inline-block; }



I hope this helps...


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...