Skip to:
Content

bbPress.org

Opened 7 years ago

Closed 7 years ago

#3115 closed defect (bug) (fixed)

`BBP_Default` sets `bbp_enqueue_script()` calls to`$in_footer = true` but script is printed in `<head>`

Reported by: r-a-y's profile r-a-y Owned by: johnjamesjacoby's profile johnjamesjacoby
Milestone: 2.6 Priority: normal
Severity: normal Version:
Component: Appearance - Included Themes Keywords: has-patch
Cc:

Description

While looking into #3114, I noticed that BBP_Default sets bbp_enqueue_script() to load its scripts in the footer:
https://bbpress.trac.wordpress.org/browser/tags/2.6-rc-1/src/templates/default/bbpress-functions.php?marks=214#L212

However, JS scripts are printed in <head>.

The issue is bbp_enqueue_script() is enqueuing assets instead of registering and then enqueuing.

Attached patch fixes this up.

Attachments (1)

3115.01.patch (585 bytes) - added by r-a-y 7 years ago.

Download all attachments as: .zip

Change History (3)

@r-a-y
7 years ago

#1 @johnjamesjacoby
7 years ago

  • Milestone changed from Awaiting Review to 2.6

#2 @johnjamesjacoby
7 years ago

  • Owner set to johnjamesjacoby
  • Resolution set to fixed
  • Status changed from new to closed

In 6531:

Core: Register, then enqueue, both scripts and styles.

This commit makes sure that theme compatibility styles & scripts are properly registered & enqueued.

Props r-a-y. Fixes #3115.

Note: See TracTickets for help on using tickets.