WordPress.org

Ideas

Keep shortcodes in the RSS summary feed

  1. John-Pierre Cornelissen
    Member

    12345

    True, if you take 55 words from the raw html content, then you end up with a broken feed.

    That's why I said before it first needs to process the post and then take 55 words. I don't think a system needs to work too hard to do that, it is already capable of doing that for the full feed where it already 'magically knows what a shortcode is meant to do'.

    How is this 100% consistent behaviour if the full feed processes shortcodes and the summary doesn't?

    Not all theme developers know they are expected to do this. The Divi theme developers (from Elegant theme who have more then 80 themes in their store) even told me:

    Shortcodes are a part of WordPress and not something Divi-related, it's WordPress that doesn't support them. And it also doesn't work with the 2017 theme.

    Anyway, that this has always be done like this doesn't necesarily mean there isn't room for improvement. So can you please consider this suggestion for improving this part of WordPress. Or is this the wrong place to ask?

    Thank you
    JP

    Posted: 8 months ago #
  2. Ipstenu (Mika Epstein)
    Administrator

    Processing the whole post, parsing it correctly, and making sure what it includes or excludes, is

    1) Computationally expensive: It's akin to reading a whole book to determine what paragraph you need. It may not impact YOU with short 200 word posts, but someone else with 20,000 word ones has another story.

    2) Imprecise: And this is big on divi's shoulders. See... Shortcodes are something WP does, yes, but the way Divi is using them is specific to Divi themes. This is true of ALL shortcodes. Unless they want to write in a way to tell WP what's important to include (or not) in an excerpt, WP cannot reasonably know.

    I mean, if you have a table with a header and then the content, your feed would look pretty silly to have just the headers and no content right?

    And this is why WP takes the faster, reliable, route to remove shortcodes (and html!) from the auto-excerpt. It's maximum speed, maximum supportability, AND its something Divi can (easily) overcome if they chose.

    It's not going to be 'fixed' in WP because there's no practical way WP can be aware of how every single shortcode needs to be processed for content in feeds. The only way to do that would be to require all the shortcodes to be rewritten in a way that provides more context for WP to process. The horse is well out of that barn. It would break more people than it would fix, even if you just said "IF this code is there, do X."

    And at that point... why not do what https://wordpress.org/plugins/feed-excerpts-for-divi/ does?

    Seriously, this isn't a large amount of code:

    https://plugins.svn.wordpress.org/feed-excerpts-for-divi/trunk/feed-excerpts-for-divi.php

    That plugin brilliantly solves the issue specific to Divi, and demonstrated exactly WHY it cannot be a one-size-fits-all fix for all page builders :(

    Posted: 8 months ago #
  3. John-Pierre Cornelissen
    Member

    12345

    Thank you for explaining. Let's agree to disagree.

    Thanks for your time
    JP

    Posted: 8 months ago #

RSS feed for this topic

Reply

You must log in to post.

  • Rating

    12345
    1 Vote
  • Status

    This is plugin territory