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 8747633
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T12:23:20+00:00 2026-06-13T12:23:20+00:00

for some reason the text in my div doesn’t go to the next line,

  • 0

for some reason the text in my div doesn’t go to the next line, i’ve tried several different css elements which don’t seem to work…. word-wrap:break word, just jumbles the letters…

what i want is for one there is an extra word it goes down to the next line like it’s supposed to

this is the div it’s in

    #top7 {
        width: 150px;
        height:auto;
        margin: 5px;
        display: block;
        float: left;
        word-wrap:break-word;
     }

text that it’s in

#p6 {
   font-family: Myriad Pro;
   margin: 1px;  
   font-size: 22px;
   background-color:#540f45;
   padding: 5px 5px 3px 4px;
   margin:4px;
}

a {
  text-decoration: none;
  color: white;
  text-align: right;
  font-family: Myriad Pro;
}

here is the php function that retrieves the data from the database

<p id='p6'><?php echo "<a href='' "</a>"; ?></p>

this is all wrapped in these two id’s

body {
   background:#603e4f;
   display: block;

}

#foursquare {
    background-color:#603e4f;    width: 290px;
    display: block;
    position: absolute;
}
  • 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-13T12:23:21+00:00Added an answer on June 13, 2026 at 12:23 pm

    Create a proper class and get rid of the p6 element. Obviously you’d use your database generated HTML. I just used your values as an example for the fiddle. Also since you’re wrapping the elements in a p tag anyway the word break is pointless unless you expect data to be too long for a single tag. Paragraphs break to a new line automatically.

    <div id="top7">
    <p class="six"><a href="#">CSC110</a></p>
    <p class="six"><a href="#">MATH100</a></p>
    <p class="six"><a href="#">HINF130</a></p>
    <p class="six"><a href="#">CSC110</a></p>
    <p class="six"><a href="#">HINF200</a></p>
    
    </div>​
    
    .six {
      font-family: Myriad Pro;
      margin: 1px;  
      font-size: 22px;
      background-color:#540f45;
      padding: 5px 5px 3px 4px;
      margin:4px;
    }
    

    http://jsfiddle.net/calder12/5crqT/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

preg_match(/\b(word1|word2)\b/iu, 'text text text word1 text text'); For some reason the above code doesn't
I tried to integrate the twitter bootstrap modal but for some reason it doesn't
For some reason, my #gallery div doesn't show up. Here's a jsFiddle link ,
For some reason this text isn't being centered. #highlightheader { background-color:#006600; color:white; font-size:30px; text-align:center;
I have a text box for searching. For some reason, .blur() will not work
I am trying to encrypt and decrypt some simple text. But for some reason
I have some text like this: এর জন্য বুদ্ধির (Reason) প্রয়োজন নেই, প্রয়োজন নিজের
For some reason, this line of code is returning undefined for $(this).attr(href) $(a).attr(href, javascript:page('
For some reason the alink doesn't go to the link when clicked on. It
For some reason jquery's .hide() won't hide a div that contains a file input

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.