Skip to:

Opened 6 years ago

Closed 6 years ago

#1859 closed defect (bug) (invalid)

undefined functions when hooking a function returned by ajax.

Reported by: windhamdavid Owned by:
Milestone: 1.2 Priority: major
Severity: Version:
Component: Keywords:


functions return undefined when hooking into a function returned by ajax

Change History (2)

#1 @johnjamesjacoby
6 years ago

I have a feeling we will need a do_action( 'bp_ajax_init' ); somewhere...

#2 @apeatling
6 years ago

  • Resolution set to invalid
  • Status changed from new to closed

You should be using the wp_ajax_ hook to run your AJAX functions and using the ajaxurl parameter in JS as the request URL. If you do that then the WP environment should be loaded as well as BuddyPress. Basically exactly how all ajax is done in bp-default.

Note: See TracTickets for help on using tickets.