Skip to content

Allow the description to be filtered by themes or plugins #1761

Open

Description

Hi,
using the plugin I noticed a problem in sending title, content and excerpt of products to Facebook.
In the file include/fbproduct.php it seems that are used directly $post->content , $post->title etc… which is almost fine, but it doesn’t apply all the filters that are needed and that are set by theme and plugins.
In a context where plugins like wpglobus are used for translations, incorrect data are sent, (will be sent also all amount of its placeholders for example, obviously).
I have therefore corrected it using the corresponding functions (get_the_title, get_the_excerpt) and applied the corresponding content filter, removing the wptexturize to avoid problems of incorrect rendering of some characters that are not then reconverted on Facebook.
Here the diff so you can push in next release if you want.
Thanks,
Simone.

patch.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    feature: product syncRelating to syncing product data to Facebook.priority: lowThe issue/PR is low priority—not many people are affected or there’s a workaround, etc.type: bugThe issue is a confirmed bug.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions