Radio buttons ain't on the same line as their labels

I’m trying to get the radio buttons (and checkboxes) to stay on the same line as their labels. It doesn’t seem to work

link to code
Thank you

I’m not seeing any radio buttons or check boxes in the code you linked

Sorry, I forgot to save. It’s there now

Hi @glonimi0

Welcome to FCC.

You will have to wrap the input elements in their corresponding labels. Something like:

<label> <input>Label 1 </label>
<label> <input>Label 2 </label>
<label> <input>Label 3 </label>

Alternatively, you can keep them as separate elements but wrap them in a parent div and use CSS to align them.

<div><input><label>Label 1</label></div>
<div><input><label>Label 2</label></div>
<div><input><label>Label 3</label></div>
1 Like

The first block of code didn’t work. I tried the second as well, and styled the label as inline-block and it worked!!!
Thanks :wink:


This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.