Giter Site home page Giter Site logo

Comments (3)

garretthyder avatar garretthyder commented on July 20, 2024

Reference to Buddypress Support Ticket;
https://buddypress.org/support/topic/bp-2-2-update-broke-auto-embeds-on-bp-groups-extras-pages/

from buddypress-groups-extras.

garretthyder avatar garretthyder commented on July 20, 2024

Hi @slaFFik was wondering if you'd had a chance to reproduce this issue.
An update, I did notice if you go to view the gpage from wp-admin and you go to it outside a group that the autoembed is working.
Example Path - ?gpages=2015-connecttherapy-series-course-prep/thoracic-ring-taping
Whereas if you go to the gpage through the group this is where the autoembed is broken.
Example Path - /groups/2015-connecttherapy-series-course-prep/gpages/thoracic-ring-taping/
So it's specific to Buddypress fairly frustrating as I can't update Buddypress due to this, but the Buddypress update fixes a completely unrelated issue which is why I want to move forward with it.
I tried to see what differences are there between the buddypress versions with no luck.
I'm hoping you'll have better luck with investigation.
The diff I'm looking at - buddypress/buddypress@2.1.1...2.2.1#files_bucket
Appreciate any insight you can shed.
Thank you

from buddypress-groups-extras.

garretthyder avatar garretthyder commented on July 20, 2024

Hi @slaFFik I wanted to share my findings with you.

I created a support post for BP;
https://buddypress.org/support/topic/does-buddypress-disable-autoembed-and-other-the_content-filter-actions/#post-253953

It holds my solution. Seems the wp_embed only works on posts which is why it functions when you view the post outside the group. I tried the buddypress()->embed->autoembed and buddypress()->embed->run_shortcode without success.

Finally with help from @r-a-y I found all embeds and shortcodes with BP_Media_Extractor, looped through them to run wp_oembed_get and do_shortcode, storing rendering in groupmeta to cache and replaced into the contents and finally ran wpautop on the results.

Hopefully this helps with implementing on Group Pages.

One note from @r-a-y was his bp_core_extract_media_from_content function will be implemented into Buddypress 2.6 so may want to wait for that release to take advantage of it, although I don't believe it will return shortcodes.

Let me know if you need any assistance.

Cheers

from buddypress-groups-extras.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.