Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
11/01/2024 06:07:04 AM (4 days ago)
Author:
imath
Message:

Improve BuddyPress compatibility with WP Playground previews

  • Avoid using SIGNED casting into the SQL query retrieving the signup field IDs as it's generating an error with WP Playground SQLite db.
  • Make sure BP URI globals are set during Ajax requests passing the current displayed page canonical URL into these requests.
  • Ignore the bp-message cookie when its value is set to deleted to prevent the wrong display of a template notice when BP Legacy is the active template pack.
  • Update JSON blueprints to latest WP Playground's blueprint schema.

Props espellcaste

Fixes #9207
Closes https://github.com/buddypress/buddypress/pull/389

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/bp-core-functions.php

    r14029 r14068  
    16671667    $bp = buddypress();
    16681668
    1669     if ( empty( $bp->template_message ) && isset( $_COOKIE['bp-message'] ) ) {
     1669    // For a mysterious reason WP Playground seems to add a 'deleted' value to `$_COOKIE['bp-message']` when not set.
     1670    if ( empty( $bp->template_message ) && isset( $_COOKIE['bp-message'] ) && 'deleted' !== $_COOKIE['bp-message'] ) {
    16701671        $bp->template_message = stripslashes( $_COOKIE['bp-message'] );
    16711672    }
Note: See TracChangeset for help on using the changeset viewer.