[wp-trac] [WordPress Trac] #9585: wp-ajax-response not loaded !

WordPress Trac wp-trac at lists.automattic.com
Sun Apr 19 14:49:03 GMT 2009


#9585: wp-ajax-response not loaded !
----------------------------+-----------------------------------------------
 Reporter:  arena           |       Owner:  anonymous
     Type:  defect (bug)    |      Status:  new      
 Priority:  normal          |   Milestone:  2.8      
Component:  Administration  |     Version:           
 Severity:  normal          |    Keywords:           
----------------------------+-----------------------------------------------
 Well, i do not know if it is a wp bug but i am asking for an external eye
 !

 One of the main changes in 2.8 admin is that javascript can be inserted in
 the footer.

 In order to comply with the current wp admin screen, i intended to do so
 for my plugin (MailPress)

 I have been comparing the 'new post' html source with the 'new mail' html
 source and for the javascript the result looks very similar,[[BR]]
 except that in my plugin, i am loading a specific "handle"
 for wp-ajax-response called mp-ajax-response :

 {{{
 $suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '.dev' : '';
 wp_register_script( 'mp-ajax-response', "/wp-includes/js/wp-ajax-
 response$suffix.js", array('jquery'), false, 1);
 wp_localize_script( 'mp-ajax-response', 'wpAjax', array( 'noPerm' =>
 __('Email was not sent AND/OR Update database failed','MailPress'),
                                                          'broken' =>
 __('An unidentified error has occurred.'),
 'l10n_print_after' => 'try{convertEntities(wpAjax);}catch(e){};' ) );
 }}}

 I have the following in the html source :

 {{{
 <script type='text/javascript' src='http://127.0.0.1/wp28/wp-admin/load-
 scripts.php?c=0&amp;load=hoverIntent,common,jquery-color,schedule,mp-ajax-
 response,jquery-ui-core,jquery-ui-
 sortable,postbox,thickbox&amp;ver=3a76a22d74c994ad03412a0aa610805d'></script>
 }}}

 So mp-ajax-response is appearing in the list of handles loaded except that
 when i look at the js file generated,[[BR]]
  i can see schedule js code, jquery-ui-core js code and no wp-ajax-
 response js code !

 The result is things like :
 {{{
 wpAjax.parseAjaxResponse is not a function
 }}}

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/9585>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list