Support » Plugin: Raw HTML » WP is eating my code

  • Hi,
    I’m working on some pages with two columns of buttons at thee bottom of the page. The code for the buttons looks like this (abbreviated):

    
    <div class="chapter_container">
    
          <a href="https://speakbusinesscomm.com/content-marketing/">
              <p>Chapter 01</p>
              <h4>What Is Content Marketing? Is It Right for My Business?</h4>
          </a>
    

    But WordPress is stripping out the <a> element.

    What is the cause of this behavior, please? Better yet, what is the cure?

    I’m using WP 5.1 with the Classic Editor and Genesis Framework Parallax Pro theme.

    I’ve used the Raw HTML plugin (free version), but it’s not helping. I’d upgrade to the Pro, but it’s only guaranteed up to WP 4.8.9.

    I’d prefer not to use a plugin at all.

    Can anyone help?

    Thanks.

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Janis Elsts

    (@whiteshadow)

    Here are a couple of ideas:

    • Go to “Settings -> Writing” and make sure that this box is unchecked: “WordPress should correct invalidly nested XHTML automatically”.
    • When you’re working on the page, make sure you’re logged in as a user that has the unfiltered_html capability. In most cases, Administrator and Editor roles have this capability. However, in Multisite only the Super Admin has it.
    • This one is a long shot, but if you have any plugins that add new features to the editor – like buttons, toolbars, etc – you could try temporarily deactivating them and see if that helps.

    Hi Janis,
    In my dashboard, Settings -> Writing does not have an option for “WordPress should correct invalidly nested XHTML automatically.” In fact, I can’t find this option anywhere. (I’m on WP 5.1.)
    I always log in as an Administrator. It’s not a multisite situation.
    I have plugins like SiteOrigin, but I need them, so I can’t deactivate them permanently. This step might help in troubleshooting, however.
    Will the Raw Pro plugin work with WP 5.1 and future WP versions?
    Thanks.
    Andy

    Plugin Author Janis Elsts

    (@whiteshadow)

    That’s odd, all of my WP 5.1 sites seem to have that option. It’s part of WP core. Here’s a screenshot:
    https://w-shadow.com/files/screenshots/settings-writing-correct-html.png

    Could it be that the option was hidden by one of the active plugins?

    Will the Raw Pro plugin work with WP 5.1 and future WP versions?

    I think the current version of Raw HTML Pro should already work with WP 5.1 if you’re using the Classic Editor. I plan to maintain compatibility with this editor for the foreseeable future. I’m still not sure if/how I’ll be able to support Gutenberg.

    I systematically deactivated _all_ of my plugins one by one, and I still can’t find that option. Also tried logging in and out of WP while they were deactivated, and it still didn’t appear.

    I can’t find that option anywhere. I’ve tried using both Chrome and Safari to look at my dashboard, and it’s just not there.

    Isn’t that strange.

    Going to query some of the other forums.

    Plugin Author Janis Elsts

    (@whiteshadow)

    That’s very strange, yes. Do you have any sites on other hosting or local sites that you could check?

    In case it helps, I don’t think it could be a browser issue.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘WP is eating my code’ is closed to new replies.