Skip to:
Content

BuddyPress.org

Opened 10 years ago

Closed 10 years ago

#5990 closed defect (bug) (fixed)

bp_use_embed_in_private_messages() does nothing

Reported by: slaffik's profile slaFFik Owned by:
Milestone: 2.2 Priority: normal
Severity: normal Version:
Component: Messages Keywords: has-patch
Cc:

Description

In general what I tried to achieve: give users ability to use oEmbed in personal messages.

There is a filter for this in bp_use_embed_in_private_messages().
Changing its value to true doesn't convert youtube links to embeds in private messages just like in activity stream updates. Which is a bit annoying.

Possible reason: bp_get_the_thread_message_content() (which has the filter oEmbed uses) is not called when ajax posting is submitted. But the old messages with the youtube links are not converted as well, so the problem is somewhere deeper.

Attachments (1)

5990.01.patch (1006 bytes) - added by r-a-y 10 years ago.

Download all attachments as: .zip

Change History (9)

This ticket was mentioned in Slack in #buddypress by slaffik. View the logs.


10 years ago

#2 @r-a-y
10 years ago

  • Keywords has-patch added
  • Milestone changed from Awaiting Review to 2.2

Good catch, slaFFik. I don't think this ever worked correctly.

I've attached a patch that should fix this. Note that there isn't any oEmbed caching because there isn't a messages meta table.

@r-a-y
10 years ago

#3 @slaFFik
10 years ago

Tested on WordPress 4.0, BuddyPress 2.1.1, 2012 theme and BP Default - it works.

Last edited 10 years ago by slaFFik (previous) (diff)

#4 @DJPaul
10 years ago

So let's add a messages meta table, too.

#5 @slaFFik
10 years ago

That will be huge! Especially with ability to add "labels" or other types of inboxes! I'm talking about #5194

#6 @r-a-y
10 years ago

In 9187:

Fix oEmbed in private messages.

oEmbed caching for private messages will be in the next commit.

See #5990.

#7 @r-a-y
10 years ago

In 9188:

Messages: Add oEmbed caching.

With the introduction of the messages meta table (#3083), we are now able
to cache oEmbed responses. On subsequent fetches, we will now reference
the message cache instead of pinging the oEmbed provider.

This mirrors our functionality with BP's activity implementation of oEmbed.

See #5990.

#8 @r-a-y
10 years ago

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.