Version Description
- Code cleaning.
Download this release
Release Info
Developer | Hiroaki Miyashita |
Plugin | Lightbox Gallery |
Version | 0.8.3 |
Comparing to | |
See all releases |
Code changes from version 0.8.2 to 0.8.3
- lightbox-gallery.php +21 -15
- readme.txt +5 -2
lightbox-gallery.php
CHANGED
@@ -4,11 +4,13 @@ Plugin Name: Lightbox Gallery
|
|
4 |
Plugin URI: http://wpgogo.com/development/lightbox-gallery.html
|
5 |
Description: The Lightbox Gallery plugin changes the view of galleries to the lightbox.
|
6 |
Author: Hiroaki Miyashita
|
7 |
-
Version: 0.8.2
|
8 |
Author URI: http://wpgogo.com/
|
|
|
|
|
|
|
9 |
*/
|
10 |
|
11 |
-
/* Copyright 2009 -
|
12 |
|
13 |
This program is free software; you can redistribute it and/or modify
|
14 |
it under the terms of the GNU General Public License as published by
|
@@ -25,6 +27,7 @@ Author URI: http://wpgogo.com/
|
|
25 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
26 |
*/
|
27 |
|
|
|
28 |
add_action( 'init', 'lightbox_gallery_init' );
|
29 |
add_action( 'wp_head', 'lightbox_gallery_wp_head' );
|
30 |
add_action( 'wp_print_scripts', 'lightbox_gallery_wp_print_scripts' );
|
@@ -35,15 +38,11 @@ add_action( 'admin_menu', 'lightbox_gallery_admin_menu' );
|
|
35 |
add_filter( 'media_send_to_editor', 'lightbox_gallery_media_send_to_editor', 11 );
|
36 |
add_shortcode( 'gallery', 'lightbox_gallery' );
|
37 |
|
38 |
-
function
|
39 |
-
|
40 |
-
|
41 |
-
load_plugin_textdomain('lightbox-gallery', str_replace( ABSPATH, '', dirname(__FILE__) ) );
|
42 |
-
} else {
|
43 |
-
load_plugin_textdomain('lightbox-gallery', false, dirname( plugin_basename(__FILE__) ) );
|
44 |
-
}
|
45 |
-
}
|
46 |
|
|
|
47 |
if ( !defined('WP_PLUGIN_DIR') )
|
48 |
$plugin_dir = str_replace( ABSPATH, '', dirname(__FILE__) );
|
49 |
else
|
@@ -116,7 +115,7 @@ function lightbox_gallery_wp_print_scripts() {
|
|
116 |
global $wp_query;
|
117 |
$options = get_option('lightbox_gallery_data');
|
118 |
|
119 |
-
if ( $options['global_settings']['lightbox_gallery_script_loading_point'] == 'footer' ) $in_footer = true;
|
120 |
else $in_footer = false;
|
121 |
|
122 |
if ( !defined('WP_PLUGIN_DIR') )
|
@@ -191,7 +190,7 @@ function lightbox_gallery_wp_print_scripts() {
|
|
191 |
|
192 |
function lightbox_gallery_print_path_header() {
|
193 |
$options = get_option('lightbox_gallery_data');
|
194 |
-
if ( $options['global_settings']['lightbox_gallery_script_loading_point'] == 'footer' ) return;
|
195 |
$path = parse_url(get_option('siteurl'));
|
196 |
$url = $path['scheme'].'://'.$path['host'];
|
197 |
if ( get_option('home') != get_option('siteurl') || ($url != get_option('siteurl') && !is_multisite()) ) :
|
@@ -251,6 +250,7 @@ function lightbox_gallery_admin_menu() {
|
|
251 |
|
252 |
function lightbox_gallery_admin() {
|
253 |
global $wp_version;
|
|
|
254 |
|
255 |
$options = get_option('lightbox_gallery_data');
|
256 |
if( !empty($_POST["lightbox_gallery_global_settings_submit"]) ) :
|
@@ -287,6 +287,12 @@ function lightbox_gallery_admin() {
|
|
287 |
else
|
288 |
$plugin_dir = dirname( plugin_basename(__FILE__) );
|
289 |
?>
|
|
|
|
|
|
|
|
|
|
|
|
|
290 |
<?php if ( !empty($message) ) : ?>
|
291 |
<div id="message" class="updated"><p><?php echo $message; ?></p></div>
|
292 |
<?php endif; ?>
|
@@ -381,8 +387,8 @@ function lightbox_gallery_admin() {
|
|
381 |
if ( !isset($options['global_settings']['lightbox_gallery_script_loading_point']) ) $options['global_settings']['lightbox_gallery_script_loading_point'] = 'header';
|
382 |
?>
|
383 |
<p><label for="lightbox_gallery_script_loading_point"><?php _e('Choose the script loading point', 'lightbox-gallery'); ?></label>:<br />
|
384 |
-
<input type="radio" name="lightbox_gallery_script_loading_point" id="lightbox_gallery_script_loading_point" value="header"<?php checked('header', $options['global_settings']['lightbox_gallery_script_loading_point']); ?> /> <?php _e('Header', 'lightbox-gallery');
|
385 |
-
<input type="radio" name="lightbox_gallery_script_loading_point" id="lightbox_gallery_script_loading_point" value="footer"<?php checked('footer', $options['global_settings']['lightbox_gallery_script_loading_point']); ?> /> <?php _e('Footer', 'lightbox-gallery'); ?></p>
|
386 |
</td></tr>
|
387 |
<tr><td>
|
388 |
<p><input type="submit" name="lightbox_gallery_global_settings_submit" value="<?php _e('Update Options »', 'lightbox-gallery'); ?>" class="button-primary" /></p>
|
@@ -441,7 +447,7 @@ function lightbox_gallery_admin() {
|
|
441 |
</div>
|
442 |
|
443 |
<?php
|
444 |
-
if (
|
445 |
?>
|
446 |
<div class="postbox" style="min-width:200px;">
|
447 |
<div class="handlediv" title="<?php _e('Click to toggle', 'lightbox-gallery'); ?>"><br /></div>
|
4 |
Plugin URI: http://wpgogo.com/development/lightbox-gallery.html
|
5 |
Description: The Lightbox Gallery plugin changes the view of galleries to the lightbox.
|
6 |
Author: Hiroaki Miyashita
|
|
|
7 |
Author URI: http://wpgogo.com/
|
8 |
+
Version: 0.8.3
|
9 |
+
Text Domain: lightbox-gallery
|
10 |
+
Domain Path: /
|
11 |
*/
|
12 |
|
13 |
+
/* Copyright 2009 -2016 Hiroaki Miyashita
|
14 |
|
15 |
This program is free software; you can redistribute it and/or modify
|
16 |
it under the terms of the GNU General Public License as published by
|
27 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
28 |
*/
|
29 |
|
30 |
+
add_action( 'plugins_loaded', 'lightbox_gallery_plugins_loaded' );
|
31 |
add_action( 'init', 'lightbox_gallery_init' );
|
32 |
add_action( 'wp_head', 'lightbox_gallery_wp_head' );
|
33 |
add_action( 'wp_print_scripts', 'lightbox_gallery_wp_print_scripts' );
|
38 |
add_filter( 'media_send_to_editor', 'lightbox_gallery_media_send_to_editor', 11 );
|
39 |
add_shortcode( 'gallery', 'lightbox_gallery' );
|
40 |
|
41 |
+
function lightbox_gallery_plugins_loaded() {
|
42 |
+
load_plugin_textdomain('lightbox-gallery', false, plugin_basename( dirname( __FILE__ ) ) );
|
43 |
+
}
|
|
|
|
|
|
|
|
|
|
|
44 |
|
45 |
+
function lightbox_gallery_init() {
|
46 |
if ( !defined('WP_PLUGIN_DIR') )
|
47 |
$plugin_dir = str_replace( ABSPATH, '', dirname(__FILE__) );
|
48 |
else
|
115 |
global $wp_query;
|
116 |
$options = get_option('lightbox_gallery_data');
|
117 |
|
118 |
+
if ( isset($options['global_settings']['lightbox_gallery_script_loading_point']) && $options['global_settings']['lightbox_gallery_script_loading_point'] == 'footer' ) $in_footer = true;
|
119 |
else $in_footer = false;
|
120 |
|
121 |
if ( !defined('WP_PLUGIN_DIR') )
|
190 |
|
191 |
function lightbox_gallery_print_path_header() {
|
192 |
$options = get_option('lightbox_gallery_data');
|
193 |
+
if ( isset($options['global_settings']['lightbox_gallery_script_loading_point']) && $options['global_settings']['lightbox_gallery_script_loading_point'] == 'footer' ) return;
|
194 |
$path = parse_url(get_option('siteurl'));
|
195 |
$url = $path['scheme'].'://'.$path['host'];
|
196 |
if ( get_option('home') != get_option('siteurl') || ($url != get_option('siteurl') && !is_multisite()) ) :
|
250 |
|
251 |
function lightbox_gallery_admin() {
|
252 |
global $wp_version;
|
253 |
+
$locale = get_locale();
|
254 |
|
255 |
$options = get_option('lightbox_gallery_data');
|
256 |
if( !empty($_POST["lightbox_gallery_global_settings_submit"]) ) :
|
287 |
else
|
288 |
$plugin_dir = dirname( plugin_basename(__FILE__) );
|
289 |
?>
|
290 |
+
<style type="text/css">
|
291 |
+
.js .meta-box-sortables .postbox .handlediv:before { font: normal 20px/1 'dashicons'; display: inline-block; padding: 8px 10px; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-decoration: none !important; }
|
292 |
+
.js .meta-box-sortables .postbox .handlediv:before { content: '\f142'; }
|
293 |
+
.js .meta-box-sortables .postbox.closed .handlediv:before { content: '\f140'; }
|
294 |
+
#poststuff h3 { font-size: 14px; line-height: 1.4; margin: 0; padding: 8px 12px; }
|
295 |
+
</style>
|
296 |
<?php if ( !empty($message) ) : ?>
|
297 |
<div id="message" class="updated"><p><?php echo $message; ?></p></div>
|
298 |
<?php endif; ?>
|
387 |
if ( !isset($options['global_settings']['lightbox_gallery_script_loading_point']) ) $options['global_settings']['lightbox_gallery_script_loading_point'] = 'header';
|
388 |
?>
|
389 |
<p><label for="lightbox_gallery_script_loading_point"><?php _e('Choose the script loading point', 'lightbox-gallery'); ?></label>:<br />
|
390 |
+
<label><input type="radio" name="lightbox_gallery_script_loading_point" id="lightbox_gallery_script_loading_point" value="header"<?php checked('header', $options['global_settings']['lightbox_gallery_script_loading_point']); ?> /> <?php _e('Header', 'lightbox-gallery'); ?></label><br />
|
391 |
+
<label><input type="radio" name="lightbox_gallery_script_loading_point" id="lightbox_gallery_script_loading_point" value="footer"<?php checked('footer', $options['global_settings']['lightbox_gallery_script_loading_point']); ?> /> <?php _e('Footer', 'lightbox-gallery'); ?></label></p>
|
392 |
</td></tr>
|
393 |
<tr><td>
|
394 |
<p><input type="submit" name="lightbox_gallery_global_settings_submit" value="<?php _e('Update Options »', 'lightbox-gallery'); ?>" class="button-primary" /></p>
|
447 |
</div>
|
448 |
|
449 |
<?php
|
450 |
+
if ( $locale == 'ja' ) :
|
451 |
?>
|
452 |
<div class="postbox" style="min-width:200px;">
|
453 |
<div class="handlediv" title="<?php _e('Click to toggle', 'lightbox-gallery'); ?>"><br /></div>
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: Hiroaki Miyashita
|
|
3 |
Donate link: http://wpgogo.com/development/lightbox-gallery.html
|
4 |
Tags: lightbox, gallery, galleries, image, images, album, photo, photos, picture, pictures, jQuery, Highslide, Colorbox
|
5 |
Requires at least: 2.5
|
6 |
-
Tested up to: 4.
|
7 |
-
Stable tag: 0.8.
|
8 |
License: GPLv2 or later
|
9 |
|
10 |
The Lightbox Gallery plugin changes the view of galleries to the lightbox.
|
@@ -138,6 +138,9 @@ If you would like not to show the navigation, set `0`. The default is `1`.
|
|
138 |
|
139 |
== Changelog ==
|
140 |
|
|
|
|
|
|
|
141 |
= 0.8.2 =
|
142 |
* CSS loading in a child theme.
|
143 |
|
3 |
Donate link: http://wpgogo.com/development/lightbox-gallery.html
|
4 |
Tags: lightbox, gallery, galleries, image, images, album, photo, photos, picture, pictures, jQuery, Highslide, Colorbox
|
5 |
Requires at least: 2.5
|
6 |
+
Tested up to: 4.5.1
|
7 |
+
Stable tag: 0.8.3
|
8 |
License: GPLv2 or later
|
9 |
|
10 |
The Lightbox Gallery plugin changes the view of galleries to the lightbox.
|
138 |
|
139 |
== Changelog ==
|
140 |
|
141 |
+
= 0.8.3 =
|
142 |
+
* Code cleaning.
|
143 |
+
|
144 |
= 0.8.2 =
|
145 |
* CSS loading in a child theme.
|
146 |
|