WordPress.org

Ready to get started?Download WordPress

Forums

Text Editor: Changing Format to Heading Changes All Text Size (6 posts)

  1. Pete White
    Member
    Posted 3 years ago #

    Hello,
    I'm using the Twenty Ten theme (though I have encountered this in many other themes) and when I highlight a word (on it's own line) and change the format to a "heading" (h1, h2, h3, etc.), all of the text below it changes to the same size. I'm using the editor in visual mode and all text has been entered by hand, not copy and pasted.

    Has anyone else experienced this issue and found a solution?

  2. Pete White
    Member
    Posted 3 years ago #

    Anyone? This happens to me in every theme that I have ever used. Certainly, someone else has had to experience this issue before. Anyone?

  3. This sounds like your headings are not being closed properly. In other words, that you're missing the closing </h1> (or whatever) tag. Flip to code view and see if this is the case and if you want more assistance, please provide a link to your site.

  4. Pete White
    Member
    Posted 3 years ago #

    Zoonini,
    Thanks for the quick reply. I was starting to think that I was alone in this world! It looks like it's only happening when I use a "shift+enter" to create a "br" to go to the next line. If I use a standard "enter", I can format the heading and paragraph text separate from one another.

    I'm sure this is probably something that has to be resolved by changing the margin/padding for the heading tags in the CSS. Though, I am curious to know the technical reasons as to why text placed after a line break cannot be formatted individually from a heading tag placed above the line break.

    I'm interested in hearing your thoughts.

  5. Heading tags are "block-level" elements in HTML, meaning that anything added after them automatically is placed on a new line.

    I'm sure this is probably something that has to be resolved by changing the margin/padding for the heading tags in the CSS.

    Yes, if you are trying to adjust the default spacing below headings, the best way to do that is not to add in a line break, but instead to edit your CSS for that heading.

    Example:

    h2 {
    margin: 0 0 10px 0;
    }

    Though, I am curious to know the technical reasons as to why text placed after a line break cannot be formatted individually from a heading tag placed above the line break.

    Just a quirk of the WYSIWYG editor that causes the closing heading tag not to be inserted properly. I wouldn't worry too much about it - just don't add manual line breaks after headings. ;-)

  6. cstewart582
    Member
    Posted 2 years ago #

    YES!

    I have exactly the same problem.
    Basically, You highlight a section of text - a line, or a single word, and choose H1 from the drop down menu.

    Then the whole paragraph, or line gets h1. Not the bit that is selected.

    EG.
    <h1>THIS IS ALL H1 WHEN I ONLY SELECTED THESE TWO WORDS TO HAVE H1 APPLIED</h1>

    When the selected area should have produced:
    This is all h1 when I only selected these <h1>TWO WORDS</h1> to have h1 applied.

    I can of course just use html but many people can't.
    Could anyone with experience in these matters shed some light on why the visual editor doesn't work as you would expect it to?

    Thanks,

    Chris

Topic Closed

This topic has been closed to new replies.

About this Topic