Support » Requests and Feedback » WP adding tags no matter what the settings are

  • Resolved retrib

    (@retrib)


    Hi guys! I’ve got latest WP installation and found strange bug in posts parser.

    Create article with following HTML:
    <div class="wassup"><a href="#">WP IZ ASSUM</a></div>
    Browser will get: <div class="wassup"><a href="#">WP IZ ASSUM</a></div>
    All seems to be fine! Now get rid of unnecessary div.

    Create article with following HTML:
    <a href="#">WP IZ ASSUM</a>
    Browser will get: <p><a href="#">WP IZ ASSUM</a></p>
    Dunno why there is extra <p> but who cares. all seems to be OK.

    Create article with following HTML:

    <figure><a href="#">WP IZ ASSUM</a>
    </figure>

    Browser will get:

    <figure><a href="#">WP IZ ASSUM</a><br />
    </figure>

    Now isn’t that cool? But check what is even cooler!

    Create article with following HTML:

    <figure><a href="#">WP IZ ASSUM</a>
    <figcaption>NO IT'S BUGGY AS HELL</figcaption>
    </figure>

    Browser will get:

    <figure><a href="#">WP IZ ASSUM</a></p>
    <figcaption>NO IT’S BUGGY AS HELL</figcaption>
    </figure>

    Wow! Say hello to invalid markup and rendering problems! Auto-closing of tags turned off. No matter of the settings I still get this nice f-d up html.

    Guys can I somehow just get rid of this unnecessary thank-you-wp shitty-functions?

Viewing 6 replies - 1 through 6 (of 6 total)
  • GYEZ!

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    πŸ³οΈβ€πŸŒˆ Halfelf Rogue & Plugin Review Team Rep

    Please don’t bump your posts.

    Are you using the HTML editor or the TinyMCE one?

    HTML editor. But just to be sure i turned off the WYSIWYG.

    This article is stored properly in the DB. It’s the post rendering function that screw this up. You can try it yourself in your blog and see what happens.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    πŸ³οΈβ€πŸŒˆ Halfelf Rogue & Plugin Review Team Rep

    Just wanted to be sure πŸ™‚ The auto-p thing is … yeah, it can be a bit techy. I think it grabs things when it can’t recognize that it’s a tag. You may want to raise a trac on this.

    You can turn it off, at least. Slap this in your functions.php:
    remove_filter('the_content', 'wpautop');

    or grab a plugin for it πŸ™‚ There are a lot.

    Thanks! That helped. I suppose this is a must for every HTML5 template.

    I would report for a bug, but I cannot find bugtracker on this site.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    πŸ³οΈβ€πŸŒˆ Halfelf Rogue & Plugin Review Team Rep

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘WP adding tags no matter what the settings are’ is closed to new replies.