Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9272451
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T15:52:53+00:00 2026-06-18T15:52:53+00:00

When the text is long the checkbox goes above the text. How can I

  • 0

enter image description here

When the text is long the checkbox goes above the text. How can I make it stay on the same line as the text but break the text if its long? ie give the text white-space:normal but keep the checkbox and the first bit of the text on the same line.

 <input style="float: left" type="checkbox" ...etc..> <a href="...">my text</a>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T15:52:54+00:00Added an answer on June 18, 2026 at 3:52 pm

    I’ve amended the markup to use a label and input, but that’s not necessary (you’ll just need something to contain your checkbox. Take a look at this jsFiddle for an example.

    HTML:

    <div class="container">
         <label><input type="checkbox"> My text - this label can be as long as you want it to be, see?</label>
    </div>
    

    CSS:

    .container {
        width: 150px;
        background: red;
    }
    
    label {
        display: block;
        padding-left: 1em;
    }
    
    input {
        display: inline-block;
        margin-left: -1em;
    }
    

    The width on the .container is just there to show that this will work when the text wraps: it will work at any width and for responsive designs without anything fixed. It’ll look like this:

    Checkbox with long form label example

    And here’s an example using your original markup (with an added span, I’m assuming you can include that):

    <div class="container">
        <span><input type="checkbox"> <a href="#">My text - this label can be as long as you want it to be, see?</a></span>
    </div>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

When I make the spinner with very long text, the spinner button (not drop
I have a long checkbox list (with same name). I want create a filtering
I have a long text and I'd like to offer the user a reading
I need to simply wrap long text to display it in a few lines.
How do I wrap very long text in jGrowl? Right now, if the text
There are strings in a long text as: <fn id=T1FN1> anytext <p> sometext </p>
I have a very long text and I need to hide everything except the
In my application,i have text view with long text. i need text wrapping like
I have a ScrollView and a very long text on TextView and I want
I Have a program written in VB6 that reads a long text file and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.