Changes between Initial Version and Version 1 of Ticket #22037, comment 8
- Timestamp:
- 10/27/2012 07:37:04 PM (12 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #22037, comment 8
initial v1 7 7 add_action( 'wp_footer', array( $this, 'customize_preview_signature' ), 1000 ); 8 8 }}} 9 and similarly changed it on the remove_action hook on line 417. Now the signature variable is added to the footer of the response and lastIndexOf build correctly. But now it's added earlier than '</html>', so of course lastIndexOf smaller. I'm not sure, what the condition "index < response.lastIndexOf('</html>')" is for exactly, but I suggest to change it to 9 and similarly changed it on the remove_action hook on line 417. Now the signature variable is added to the footer of the response and lastIndexOf build correctly. But now it's added earlier than '</html>', so of course lastIndexOf smaller. I'm not sure, what the condition "index < response.lastIndexOf('</html>')" is for exactly, but I suggest to change it to <body> 10 10 {{{ 11 11 // Check for a signature in the request. … … 13 13 if ( -1 === index || index < response.lastIndexOf('<body>') ) { 14 14 deferred.rejectWith( self, [ 'unsigned' ] ); 15 //return;15 return; 16 16 } 17 17 … … 22 22 self.iframe = $('<iframe />').appendTo( self.container ); 23 23 }}} 24 24 return then doesn't need commenting out anymore.