• Resolved baytonorg

    (@baytonorg)


    Good Day,

    I’ve been trying to google this for some time with no resolution.
    When I use the italics tag, it will display in the editor correctly, however once clicking publish, on the published page will display as bold-italic.

    EG:

    I create an italic sentence (<e m> is used in this editor also..)

    But when I publish it, it comes out bold-italic

    This is very frustrating, as it messes up my posts/pages.

    If I correct this in the HTML (replace all <e m> with < i >) the page will display correctly. However as soon as I edit in visual mode again, and publish, it will revert.

    My website: https://www.bayton.org
    An example: https://www.bayton.org/hire/musician (note the bold italic under the pictures)

    How do I fix this please?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Line 510 of style.css in your theme’s folder:

    strong, em, b, h1, h2, h3, h4, h5, h6 {
        font-weight: bold;
    }

    The “i” tag is only working because your theme doesn’t change it’s style. I think the “i” (italic) tag is deprecated and has been replaced with the “em” (emphasis) tag, so I guess that’s why WP switches it out.

    Thread Starter baytonorg

    (@baytonorg)

    Ok, so what must I do to rectify this? Remove ’em’ from the style.css or..?

    I’m afraid to a novice such as me, you’ve only provided half an answer ??

    Sorry, if you can find that section of the code delete “em,” so that you’re left with:

    strong, b, h1, h2, h3, h4, h5, h6 {
        font-weight: bold;
    }

    I hope that’s clearer.

    Thread Starter baytonorg

    (@baytonorg)

    That is much clearer, thankyou.

    I hsve done this and it seems to have corrected itself!
    How were you aware of which line of code in my CSS was causing this? Is this common or did you have access to it?

    In a related issue, if I perform a quick edit and save, everywhere a ‘ is present, a \ will accompany it.

    EG

    Before the quick edit :

    Don’t
    ‘the cat sat on the mat’

    After the quick edit, regardless of whether I made changes to that word or not :

    Don\’t
    \’the cat sat on the mat\’
    This is also a little frustrating, as it means I have to continually load the full editor even for such simple things as a spelling correction.

    Any ideas?

    Thankyou for your help thus far!

    If you use the Firebug plugin for Firefox you can see what CSS styles are applied to it and where they are in the code. If you’re interested in web design check it out, it’s pretty neat.

    The other issue your having with the backslashes is a WordPress issue I believe. Those slashes are placed to prevent malicious code from messing with your database, so I think the problem is within the WordPress code somewhere. (aka: I don’t think you can do anything about it, except file a bug report)

    Thread Starter baytonorg

    (@baytonorg)

    That’s a very cool plugin ?? I’ll look for it!

    Damn, well I can live with them, I’ll just have to full edit. It only takes a moment more to do so I should be able to handle the wait ??

    Thanks very much for your help, I’ll class this issue as resolved now.

    Thanks again.
    Jason

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Editor replacing my <i> tags with <em>’ is closed to new replies.