WordPress.org

Ready to get started?Download WordPress

Forums

Modification of specialty (ie alert) boxes. (6 posts)

  1. ohi
    Member
    Posted 5 years ago #

    Here's my issue. I'd like to use alert type boxes in my blog. They're coded properly with one exception. I'm not sure if it's even possible, or it's something I'm missing.

    It seems as if you hit return in the box it ends it. I need to have hard returns in the boxes so that there's several paragraphs, bulletted lists, etc in the "box".

    Here's the current code I'm using. If you can provide any help it'd be greatly appreciated.

    .blitz
    {
    	background: #010101 url(images/ico_blitz.gif) no-repeat right center;
    	background-position: 15px 50%; /*[e]15px 50%; /* x-pos y-pos*/
    	font: small Candara;
    	text-align: left;
    	padding: 5px 20px 5px 55px;
    	border-top: 3px solid #4D4B5B;
    	border-bottom: 3px solid #4D4B5B;

    Thanks!

  2. esmi
    Forum Moderator
    Posted 5 years ago #

    What you've posted is the CSS which simply defines how the content is displayed. It can't insert hard line breaks. Whatever you're using to enter content for these boxes would have to do that.

  3. ohi
    Member
    Posted 5 years ago #

    Well, I know the CSS just handles the design and display, which lead me to believe maybe there was something wrong with the code, and not the entry of the content of the post, since they were visually correct. When displayed however, it would show everything in the first paragraph blocked, then everything after that paragraph not in the block.

    This is the code I'm using for my entry.

    <p class="blitz">My content would obviously go here.</p>

    This even worked fine:

    <p class="blitz">Single line then entered
    into a second line with no space between.</p>

    The problem is when I would try this:

    <p class="blitz">First line or paragraph
    
    Second paragraph
    
    Third paragraph</p>

    That's when it would stop after the first paragraph. I hope this makes more sense than my first post.

  4. blazzinmatt
    Member
    Posted 5 years ago #

    Why don't you try something like this:

    <p class="blitz">First paragraph goes here.</p>
    
    <p class="blitz">Second paragraph goes here.</p>
    
    <p class="blitz">Third paragraph goes here.</p>
  5. ohi
    Member
    Posted 5 years ago #

    That won't work for what I need. I need it to be in one block, not several broken up boxes since it's one subject. If they were in multiple boxes it would just be confusing.

  6. esmi
    Forum Moderator
    Posted 5 years ago #

    Use:

    <div class="blitz">
    <p>First line or paragraph</p>
    <p>Second paragraph</p>
    <p>Third paragraph</p>
    </div>

Topic Closed

This topic has been closed to new replies.

About this Topic