Skip to:
Content

BuddyPress.org

Opened 9 years ago

Closed 9 years ago

Last modified 8 years ago

#6790 closed defect (bug) (no action required)

Backslashes get lost in activity stream

Reported by: antonv's profile antonv Owned by:
Milestone: Priority: normal
Severity: normal Version: 2.4.0
Component: Core Keywords: reporter-feedback
Cc: dcavins

Description

Hi

  1. in the bbpress forum I wrote following text:
    a new bbPress test $a=b\cos\alpha$
    
  1. but this gets displayed in the activity log as
    a new bbPress test $a=bcosalpha$
    
  1. However when I post the same (1.) in buddypress activity log, it is displayed correctly.

Looking into the the databases it becomes clear why
Text from bbPress Forum is stored in wp_bp_activity as

a new bbPress test $a=b\cos\alpha$

whereas text entered on the activity log is stored in wp_bp_activity as

a new ActivityLog test $a=b\\cos\\alpha$

although typed with only one \ and subsequently also rendered with a single backslash

Can you please issue an update, or tell me what file to modify and what, that correctly inserts the extra slashes to forums and comment activity so that the text copied from forum to the activity is rendered correctly in the buddyPress activity log.

(buddyPress version is 2.4.3)

Change History (5)

#1 @dcavins
9 years ago

  • Cc dcavins added

Hi @antonv-

Backslashes are used in MySQL as an escape character. (See the section starting "Within a string, certain sequences have special meaning..." here for more information http://dev.mysql.com/doc/refman/5.7/en/string-literals.html)

It sounds like the updates from the bbPress forums added to the activity stream are not being escaped before being saved to the database. Which version of bbPress are you using?

#2 @henry.wright
9 years ago

It sounds like the updates from the bbPress forums added to the activity stream are not being escaped before being saved to the database

If that's the case, it is worth pulling this ticket and discussing the rest in private?

#3 @DJPaul
9 years ago

  • Keywords reporter-feedback added

@antonv Which version of bbPress are you using?

#4 @DJPaul
9 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to invalid
  • Status changed from new to closed

Closing due to no reporter feedback that we need to proceed.

#5 @DJPaul
8 years ago

  • Component changed from API to Core
Note: See TracTickets for help on using tickets.