Changeset 472089
- Timestamp:
- 12/07/2011 04:48:04 PM (14 years ago)
- Location:
- shadowbox-js/trunk
- Files:
-
- 3 edited
-
inc/frontend.php (modified) (7 diffs)
-
shadowbox-js.php (modified) (3 diffs)
-
shadowbox-title-push.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
shadowbox-js/trunk/inc/frontend.php
r394417 r472089 33 33 // This allows for selecting to delete options from the admin page 34 34 if ( ! empty ( $this->options ) ) { 35 add_action ( ' plugins_loaded' , array ( &$this , 'styles' ) , 7 );36 add_action ( ' plugins_loaded' , array ( &$this , 'scripts' ) , 8 );35 add_action ( 'init' , array ( &$this , 'styles' ) , 7 ); 36 add_action ( 'init' , array ( &$this , 'scripts' ) , 8 ); 37 37 if ( $this->get_option ( 'smartLoad' ) == 'false' ) 38 add_action ( 'wp_footer' , array ( &$this , 'configure' ) , 11 );38 add_action ( 'wp_footer' , array ( &$this , 'configure' ) , 21 ); 39 39 40 40 // Automatically add Shadowbox to links … … 72 72 $posts[$i]->post_content = $this->add_attr_to_link ( $posts[$i]->post_content , $posts[$i] ); 73 73 if ( preg_match ( '%(?<!\[)\[gallery[ \]]%i', $posts[$i]->post_content ) && $this->get_option ( 'smartLoad' ) == 'true' ) 74 $this->possibly_enqueue ( 'shadowbox');74 add_action( 'wp_enqueue_scripts', array( &$this, 'possibly_enqueue' ) ); 75 75 if ( ! empty ( $posts[$i]->post_excerpt ) ) { 76 76 $posts[$i]->post_excerpt = $this->add_attr_to_link ( $posts[$i]->post_excerpt , $posts[$i] ); 77 77 if ( preg_match ( '%(?<!\[)\[gallery[ \]]%i', $posts[$i]->post_excerpt ) && $this->get_option ( 'smartLoad' ) == 'true' ) 78 $this->possibly_enqueue ( 'shadowbox');78 add_action( 'wp_enqueue_scripts', array( &$this, 'possibly_enqueue' ) ); 79 79 } 80 80 } … … 150 150 $shadowbox = $shadowbox_url; 151 151 } else { 152 $shadowbox = add_query_arg ( array ( 'action' => 'shadowboxjs' , 'cache' => $md5 ) , admin_url ( 'admin-ajax.php' , $scheme ) );152 $shadowbox = add_query_arg ( array ( 'action' => 'shadowboxjs' , 'cache' => $md5 ) , admin_url ( 'admin-ajax.php' , $scheme ) ); 153 153 } 154 154 … … 170 170 * @since 3.0.0.0 171 171 */ 172 function possibly_enqueue ( $ script) {172 function possibly_enqueue ( $deprecated = '' ) { 173 173 if ( did_action ( 'wp_head' ) ) 174 174 return; … … 178 178 179 179 wp_enqueue_script ( $this->get_option ( 'library' ) ); 180 wp_enqueue_script ( $script);181 add_action ( 'wp_footer' , array ( &$this , 'configure' ) , 11 );180 wp_enqueue_script ( 'shadowbox' ); 181 add_action ( 'wp_footer' , array ( &$this , 'configure' ) , 21 ); 182 182 } 183 183 … … 189 189 */ 190 190 function configure () { 191 $plugin_url = $this->plugin_url ();191 $plugin_url = $this->plugin_url (); 192 192 $library = $this->get_option ( 'library' ); 193 193 $start = "\n<!-- Begin Shadowbox JS v{$this->version} -->\n"; … … 345 345 // Check to see if we need to try to load shadowbox and dependencies into the footer 346 346 if ( preg_match ( $slbox_rel_pattern , $content ) && $this->get_option ( 'smartLoad' ) == 'true' ) { 347 $this->possibly_enqueue ( 'shadowbox');347 $this->possibly_enqueue (); 348 348 } 349 349 -
shadowbox-js/trunk/shadowbox-js.php
r394417 r472089 8 8 * 9 9 * @author Matt Martz <matt@sivel.net> 10 * @version 3.0.3. 810 * @version 3.0.3.9 11 11 * @package shadowbox-js 12 12 */ … … 16 16 Plugin URI: http://sivel.net/wordpress/shadowbox-js/ 17 17 Description: A javascript media viewer similar to Lightbox and Thickbox. Supports all types of media, not just images. 18 Version: 3.0.3. 818 Version: 3.0.3.9 19 19 Author: Matt Martz 20 20 Author URI: http://sivel.net/ … … 56 56 * @var int 57 57 */ 58 var $version = '3.0.3. 8';58 var $version = '3.0.3.9'; 59 59 60 60 /** -
shadowbox-js/trunk/shadowbox-title-push.php
r394417 r472089 14 14 Plugin URI: http://sivel.net/wordpress/shadowbox-js/ 15 15 Description: Push the title attribute from the img tag to the anchor tag 16 Version: 3.0.3. 816 Version: 3.0.3.9 17 17 Author: Matt Martz 18 18 Author URI: http://sivel.net/
Note: See TracChangeset
for help on using the changeset viewer.