Version Description
- Option Added to Gather Data for Testing Purposes for Better Compatibility
Download this release
Release Info
Developer | Gallery-Bank |
Plugin | Gallery Bank: WordPress Photo Gallery Plugin |
Version | 2.0.22 |
Comparing to | |
See all releases |
Code changes from version 2.0.21 to 2.0.22
- gallery-bank.php +5 -2
- lib/class-tracking.php +2 -0
- lib/gallery-bank-class.php +75 -0
- readme.txt +5 -2
- views/dashboard.php +227 -83
gallery-bank.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
Plugin URI: http://gallery-bank.com
|
5 |
Description: Gallery Bank is an interactive WordPress photo gallery plugin, best fit for creative and corporate portfolio websites.
|
6 |
Author: Gallery-Bank
|
7 |
-
Version: 2.0.
|
8 |
Author URI: http://gallery-bank.com
|
9 |
*/
|
10 |
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
@@ -35,7 +35,8 @@ function plugin_install_script_for_gallery_bank()
|
|
35 |
/*************************************************************************************/
|
36 |
function plugin_uninstall_script_for_gallery_bank()
|
37 |
{
|
38 |
-
|
|
|
39 |
}
|
40 |
/*************************************************************************************/
|
41 |
function plugin_load_textdomain()
|
@@ -48,6 +49,8 @@ function plugin_load_textdomain()
|
|
48 |
/*************************************************************************************/
|
49 |
add_action('plugins_loaded', 'plugin_load_textdomain');
|
50 |
register_activation_hook(__FILE__,'plugin_install_script_for_gallery_bank');
|
|
|
|
|
51 |
|
52 |
function TrackingForGalleryBank()
|
53 |
{
|
4 |
Plugin URI: http://gallery-bank.com
|
5 |
Description: Gallery Bank is an interactive WordPress photo gallery plugin, best fit for creative and corporate portfolio websites.
|
6 |
Author: Gallery-Bank
|
7 |
+
Version: 2.0.22
|
8 |
Author URI: http://gallery-bank.com
|
9 |
*/
|
10 |
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
35 |
/*************************************************************************************/
|
36 |
function plugin_uninstall_script_for_gallery_bank()
|
37 |
{
|
38 |
+
delete_option('allow_tracking_gb');
|
39 |
+
//include_once GALLERY_BK_PLUGIN_DIR .'/uninstall-script.php';
|
40 |
}
|
41 |
/*************************************************************************************/
|
42 |
function plugin_load_textdomain()
|
49 |
/*************************************************************************************/
|
50 |
add_action('plugins_loaded', 'plugin_load_textdomain');
|
51 |
register_activation_hook(__FILE__,'plugin_install_script_for_gallery_bank');
|
52 |
+
register_uninstall_hook(__FILE__,'plugin_uninstall_script_for_gallery_bank');
|
53 |
+
register_deactivation_hook(__FILE__,'plugin_uninstall_script_for_gallery_bank');
|
54 |
|
55 |
function TrackingForGalleryBank()
|
56 |
{
|
lib/class-tracking.php
CHANGED
@@ -87,6 +87,8 @@ if ( !class_exists( 'TrackingForGalleryBank' ) ) {
|
|
87 |
),
|
88 |
'theme' => $theme,
|
89 |
'plugins' => $plugins,
|
|
|
|
|
90 |
);
|
91 |
|
92 |
$args = array(
|
87 |
),
|
88 |
'theme' => $theme,
|
89 |
'plugins' => $plugins,
|
90 |
+
'email' => get_option( 'admin_email' )
|
91 |
+
|
92 |
);
|
93 |
|
94 |
$args = array(
|
lib/gallery-bank-class.php
CHANGED
@@ -289,6 +289,81 @@ function extract_short_code_all_albums($con)
|
|
289 |
wp_reset_query();
|
290 |
return $gallerybank_output;
|
291 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
292 |
add_action('admin_init','backend_scripts_calls');
|
293 |
add_action('admin_init','backend_css_calls');
|
294 |
add_action('init','frontend_plugin_js_scripts_gallery_bank');
|
289 |
wp_reset_query();
|
290 |
return $gallerybank_output;
|
291 |
}
|
292 |
+
//--------------------------------------------------------------------------------------------------------------//
|
293 |
+
function gallery_bank_enqueue_pointer_script_style( $hook_suffix ) {
|
294 |
+
// Assume pointer shouldn't be shown
|
295 |
+
|
296 |
+
$enqueue_pointer_script_style = false;
|
297 |
+
|
298 |
+
// Get array list of dismissed pointers for current user and convert it to array
|
299 |
+
|
300 |
+
$dismissed_pointers = explode( ',', get_user_meta( get_current_user_id(), 'dismissed_wp_pointers', true ) );
|
301 |
+
|
302 |
+
// Check if our pointer is not among dismissed ones
|
303 |
+
if( !in_array( 'gallery_bank_pointer', $dismissed_pointers ) ) {
|
304 |
+
$enqueue_pointer_script_style = true;
|
305 |
+
|
306 |
+
// Add footer scripts using callback function
|
307 |
+
add_action( 'admin_print_footer_scripts', 'gallery_bank_pointer_print_scripts' );
|
308 |
+
}
|
309 |
+
|
310 |
+
// Enqueue pointer CSS and JS files, if needed
|
311 |
+
if( $enqueue_pointer_script_style ) {
|
312 |
+
wp_enqueue_style( 'wp-pointer' );
|
313 |
+
wp_enqueue_script( 'wp-pointer' );
|
314 |
+
}
|
315 |
+
}
|
316 |
+
$allow_tracking = get_option('allow_tracking_gb');
|
317 |
+
if($allow_tracking == "")
|
318 |
+
{
|
319 |
+
add_action( 'admin_enqueue_scripts', 'gallery_bank_enqueue_pointer_script_style' );
|
320 |
+
}
|
321 |
+
|
322 |
+
function gallery_bank_pointer_print_scripts() {
|
323 |
+
|
324 |
+
$pointer_content = "<h3>Help improve Gallery Bank</h3>";
|
325 |
+
$pointer_content .= "<p>You\'ve just installed Gallery Bank. Please helps us improve it by allowing us to gather anonymous usage stats so we know which configurations, plugins and themes to test with.</p>";
|
326 |
+
$pointer_content .= "<div class=\'wp-pointer-buttons\'><a id=\'pointer-close\' class=\'button-secondary\' style=\'margin-left:5px;\' >Do not allow tracking</a><a id=\'allow_tracking\' class=\'button-primary\'>Allow Tracking</a></div>";
|
327 |
+
?>
|
328 |
+
|
329 |
+
<script type="text/javascript">
|
330 |
+
jQuery(document).ready( function($) {
|
331 |
+
$('#wpadminbar').pointer({
|
332 |
+
content:'<?php echo $pointer_content; ?>',
|
333 |
+
position:{
|
334 |
+
edge: 'top', // arrow direction
|
335 |
+
align: 'center' // vertical alignment
|
336 |
+
},
|
337 |
+
pointerWidth: 350,
|
338 |
+
close:function() {
|
339 |
+
$.post( ajaxurl, {
|
340 |
+
pointer: 'gallery_bank_pointer', // pointer ID
|
341 |
+
action: 'dismiss-wp-pointer'
|
342 |
+
});
|
343 |
+
}
|
344 |
+
}).pointer('open');
|
345 |
+
});
|
346 |
+
jQuery('#pointer-close').live('click',function()
|
347 |
+
{
|
348 |
+
|
349 |
+
jQuery('#wp-pointer-0').remove();
|
350 |
+
<?php
|
351 |
+
update_option( 'allow_tracking_gb', 'no' );
|
352 |
+
?>
|
353 |
+
});
|
354 |
+
jQuery('#allow_tracking').live('click',function()
|
355 |
+
{
|
356 |
+
|
357 |
+
jQuery('#wp-pointer-0').remove();
|
358 |
+
<?php
|
359 |
+
update_option( 'allow_tracking_gb', 'yes' );
|
360 |
+
?>
|
361 |
+
});
|
362 |
+
</script>
|
363 |
+
|
364 |
+
<?php
|
365 |
+
}
|
366 |
+
/*****************************************************************************************************************/
|
367 |
add_action('admin_init','backend_scripts_calls');
|
368 |
add_action('admin_init','backend_css_calls');
|
369 |
add_action('init','frontend_plugin_js_scripts_gallery_bank');
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: Gallery-Bank
|
|
3 |
Tags: gallery, images, album, pictures, photos, photo album, photo gallery, media, photo albums, picture, pictures, thumbnails, slideshow, admin, best gallery plugin, filterable gallery, filterable portfolio, gallery, gallery wordpress plugin, grid gallery, image album, images, page, photo albums, plugin, portfolio, portfolio wordpress plugin, Post, Posts, widget, wordpress gallery plugin, wordpress portfolio plugin, videos, comments, widget, gallery bank
|
4 |
Requires at least: 3.3
|
5 |
Tested up to: 3.7.1
|
6 |
-
Stable tag: 2.0.
|
7 |
License: GPLv3 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-3.0.html
|
9 |
|
@@ -18,7 +18,7 @@ It has the ability to upload images, with options like adding, editing, re-order
|
|
18 |
|
19 |
Gallery Bank is designed to adapt each portfolio to any situation and can be easily used on mobiles as it is a Responsive Plugin.
|
20 |
|
21 |
-
**December
|
22 |
|
23 |
<a href="http://gallery-bank.com/forum/support-forum/" target="_blank">Support Desk - feel free to ask your queries</a>
|
24 |
|
@@ -146,6 +146,9 @@ With this bulk deletion feature, you can now delete the pictures you want in bul
|
|
146 |
|
147 |
== Changelog ==
|
148 |
|
|
|
|
|
|
|
149 |
|
150 |
= 2.0.21 =
|
151 |
|
3 |
Tags: gallery, images, album, pictures, photos, photo album, photo gallery, media, photo albums, picture, pictures, thumbnails, slideshow, admin, best gallery plugin, filterable gallery, filterable portfolio, gallery, gallery wordpress plugin, grid gallery, image album, images, page, photo albums, plugin, portfolio, portfolio wordpress plugin, Post, Posts, widget, wordpress gallery plugin, wordpress portfolio plugin, videos, comments, widget, gallery bank
|
4 |
Requires at least: 3.3
|
5 |
Tested up to: 3.7.1
|
6 |
+
Stable tag: 2.0.22
|
7 |
License: GPLv3 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-3.0.html
|
9 |
|
18 |
|
19 |
Gallery Bank is designed to adapt each portfolio to any situation and can be easily used on mobiles as it is a Responsive Plugin.
|
20 |
|
21 |
+
**December 13, 2013: We're happy to announce that Gallery Bank reached 61,600+ plugin downloads in only 6 months. We frequently receive positive feedback from people using our gallery bank plugin for WordPress. Thanks so much for your support!**
|
22 |
|
23 |
<a href="http://gallery-bank.com/forum/support-forum/" target="_blank">Support Desk - feel free to ask your queries</a>
|
24 |
|
146 |
|
147 |
== Changelog ==
|
148 |
|
149 |
+
= 2.0.22 =
|
150 |
+
|
151 |
+
* Option Added to Gather Data for Testing Purposes for Better Compatibility
|
152 |
|
153 |
= 2.0.21 =
|
154 |
|
views/dashboard.php
CHANGED
@@ -17,7 +17,6 @@ else
|
|
17 |
</div>
|
18 |
<ul class="midnav midnav-font">
|
19 |
<?php
|
20 |
-
global $wpdb;
|
21 |
$album_count = $wpdb->get_var
|
22 |
(
|
23 |
$wpdb->prepare
|
@@ -52,79 +51,206 @@ else
|
|
52 |
</ul>
|
53 |
<div class="body" style="margin:10px;">
|
54 |
<div class="separator-doubled"></div>
|
55 |
-
<div class="
|
56 |
-
<div class="
|
57 |
-
<div class="
|
58 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
59 |
</div>
|
60 |
</div>
|
61 |
-
<div class="
|
62 |
-
<div class="
|
63 |
-
<
|
64 |
-
<
|
65 |
-
<
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
128 |
</div>
|
129 |
</div>
|
130 |
</div>
|
@@ -162,21 +288,39 @@ else
|
|
162 |
});
|
163 |
}
|
164 |
function delete_all_albums()
|
|
|
|
|
165 |
{
|
166 |
-
|
|
|
167 |
{
|
168 |
-
|
169 |
-
if(confirmed == true)
|
170 |
{
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
|
176 |
-
|
177 |
-
|
178 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
179 |
}
|
|
|
|
|
180 |
</script>
|
181 |
<?php
|
182 |
}
|
17 |
</div>
|
18 |
<ul class="midnav midnav-font">
|
19 |
<?php
|
|
|
20 |
$album_count = $wpdb->get_var
|
21 |
(
|
22 |
$wpdb->prepare
|
51 |
</ul>
|
52 |
<div class="body" style="margin:10px;">
|
53 |
<div class="separator-doubled"></div>
|
54 |
+
<div class="row-fluid">
|
55 |
+
<div class="span9">
|
56 |
+
<div class="block well">
|
57 |
+
<div class="navbar">
|
58 |
+
<div class="navbar-inner">
|
59 |
+
<h5><?php _e( "Existing Albums Overview", gallery_bank ); ?></h5>
|
60 |
+
</div>
|
61 |
+
</div>
|
62 |
+
<div class="body">
|
63 |
+
<div class="table-overflow">
|
64 |
+
<table class="table table-striped" id="data-table-album">
|
65 |
+
<thead>
|
66 |
+
<tr>
|
67 |
+
<th><?php _e( "Album Title", gallery_bank ); ?></th>
|
68 |
+
<th><?php _e( "Images in Album", gallery_bank ); ?></th>
|
69 |
+
<th><?php _e( "Published By", gallery_bank ); ?></th>
|
70 |
+
<th><?php _e( "Date of Creation", gallery_bank ); ?></th>
|
71 |
+
<th></th>
|
72 |
+
</tr>
|
73 |
+
</thead>
|
74 |
+
<tbody>
|
75 |
+
<?php
|
76 |
+
$album = $wpdb->get_results
|
77 |
+
(
|
78 |
+
$wpdb->prepare
|
79 |
+
(
|
80 |
+
"SELECT * FROM ".gallery_bank_albums(),""
|
81 |
+
)
|
82 |
+
);
|
83 |
+
for($flag=0; $flag < count($album); $flag++)
|
84 |
+
{
|
85 |
+
$count_pic = $wpdb->get_var
|
86 |
+
(
|
87 |
+
$wpdb->prepare
|
88 |
+
(
|
89 |
+
"SELECT count(".gallery_bank_albums().".album_id) FROM ".gallery_bank_albums()." join ".gallery_bank_pics()." on ".gallery_bank_albums().".album_id = ".gallery_bank_pics().".album_id where ".gallery_bank_albums().".album_id = %d ",
|
90 |
+
$album[$flag]->album_id
|
91 |
+
)
|
92 |
+
);
|
93 |
+
?>
|
94 |
+
<tr>
|
95 |
+
<td><?php echo stripcslashes(htmlspecialchars_decode($album[$flag] -> album_name));?></td>
|
96 |
+
<td><?php echo $count_pic;?></td>
|
97 |
+
<td><?php echo $album[$flag] -> author;?></td>
|
98 |
+
<td><?php echo date("d-M-Y", strtotime($album[$flag] -> album_date));?></td>
|
99 |
+
<td>
|
100 |
+
<ul class="table-controls">
|
101 |
+
<li>
|
102 |
+
<a href="admin.php?page=edit_album&album_id=<?php echo $album[$flag]->album_id;?>" class="btn hovertip" data-original-title="<?php _e( "Edit Album", gallery_bank ); ?>">
|
103 |
+
<i class="icon-pencil"></i>
|
104 |
+
</a>
|
105 |
+
</li>
|
106 |
+
<li>
|
107 |
+
<a href="admin.php?page=images_sorting&album_id=<?php echo $album[$flag]->album_id;?>" class="btn hovertip" data-original-title="<?php _e( "Re-order Images", gallery_bank ); ?>">
|
108 |
+
<i class="icon-th"></i>
|
109 |
+
</a>
|
110 |
+
</li>
|
111 |
+
<li>
|
112 |
+
<a href="admin.php?page=album_preview&album_id=<?php echo $album[$flag]->album_id;?>" class="btn hovertip" data-original-title="<?php _e( "Preview Album", gallery_bank ); ?>">
|
113 |
+
<i class="icon-eye-open"></i>
|
114 |
+
</a>
|
115 |
+
</li>
|
116 |
+
<li>
|
117 |
+
<a class="btn hovertip" style="cursor: pointer;" data-original-title="<?php _e( "Delete Album", gallery_bank ); ?>" onclick="delete_album(<?php echo $album[$flag]->album_id;?>)">
|
118 |
+
<i class="icon-trash"></i>
|
119 |
+
</a>
|
120 |
+
</li>
|
121 |
+
</ul>
|
122 |
+
</td>
|
123 |
+
</tr>
|
124 |
+
<?php
|
125 |
+
}
|
126 |
+
?>
|
127 |
+
</tbody>
|
128 |
+
</table>
|
129 |
+
</div>
|
130 |
+
</div>
|
131 |
</div>
|
132 |
</div>
|
133 |
+
<div class="span3">
|
134 |
+
<div class="block well">
|
135 |
+
<div class="navbar">
|
136 |
+
<div class="navbar-inner">
|
137 |
+
<h5><?php _e( "Allow Tracking", gallery_bank ); ?></h5>
|
138 |
+
</div>
|
139 |
+
</div>
|
140 |
+
<div class="body">
|
141 |
+
<ul class="settings" style="margin-left: 13px;">
|
142 |
+
<?php
|
143 |
+
$allow_tracking = get_option('allow_tracking_gb');
|
144 |
+
if($allow_tracking == "yes")
|
145 |
+
{
|
146 |
+
?>
|
147 |
+
<input type="checkbox" name="allow-tracking" id="allow-tracking" checked="checked" onchange="allowTracking();" />
|
148 |
+
<?php
|
149 |
+
}
|
150 |
+
else
|
151 |
+
{
|
152 |
+
?>
|
153 |
+
<input type="checkbox" name="allow-tracking" id="allow-tracking" onchange="allowTracking();" />
|
154 |
+
<?php
|
155 |
+
}
|
156 |
+
?>
|
157 |
+
<label style="margin-left: 2px;">Allow tracking of this WordPress installs anonymous data.</label>
|
158 |
+
<p>
|
159 |
+
To maintain a plugin as big as Gallery Bank, we need to know what we're dealing: what kinds of other plugins our users are using,
|
160 |
+
what themes, etc. Please allow us to track that data from your install. It will not track any user details, so your security and privacy are safe with us.
|
161 |
+
</p>
|
162 |
+
</ul>
|
163 |
+
</div>
|
164 |
+
</div>
|
165 |
+
</div>
|
166 |
+
<div class="span3" style="float: right;">
|
167 |
+
<div class="block well">
|
168 |
+
<div class="navbar">
|
169 |
+
<div class="navbar-inner">
|
170 |
+
<h5><?php _e( "Server Settings", gallery_bank ); ?></h5>
|
171 |
+
</div>
|
172 |
+
</div>
|
173 |
+
<div class="body">
|
174 |
+
<ul class="settings" style="margin-left: 13px;">
|
175 |
+
<?php
|
176 |
+
global $wpdb, $gb;
|
177 |
+
// Get MYSQL Version
|
178 |
+
$sql_version = $wpdb->get_var("SELECT VERSION() AS version");
|
179 |
+
// GET SQL Mode
|
180 |
+
$my_sql_info = $wpdb->get_results("SHOW VARIABLES LIKE 'sql_mode'");
|
181 |
+
if (is_array($my_sql_info)) $sqlmode = $my_sql_info[0]->Value;
|
182 |
+
if (empty($sqlmode)) $sqlmode = __('Not set', 'gallery_bank');
|
183 |
+
// Get PHP Safe Mode
|
184 |
+
if(ini_get('safemode')) $safemode = __('On', 'gallery_bank');
|
185 |
+
else $safemode = __('Off', 'gallery_bank');
|
186 |
+
// Get PHP allow_url_fopen
|
187 |
+
if(ini_get('allow-url-fopen')) $allowurlfopen = __('On', 'gallery_bank');
|
188 |
+
else $allowurlfopen = __('Off', 'gallery_bank');
|
189 |
+
// Get PHP Max Upload Size
|
190 |
+
if(ini_get('upload_max_filesize')) $upload_maximum = ini_get('upload_max_filesize');
|
191 |
+
else $upload_maximum = __('N/A', 'gallery_bank');
|
192 |
+
// Get PHP Output buffer Size
|
193 |
+
if(ini_get('pcre.backtrack_limit')) $backtrack_lmt = ini_get('pcre.backtrack_limit');
|
194 |
+
else $backtrack_lmt = __('N/A', 'gallery_bank');
|
195 |
+
// Get PHP Max Post Size
|
196 |
+
if(ini_get('post_max_size')) $post_maximum = ini_get('post_max_size');
|
197 |
+
else $post_maximum = __('N/A', 'gallery_bank');
|
198 |
+
// Get PHP Max execution time
|
199 |
+
if(ini_get('max_execution_time')) $maximum_execute = ini_get('max_execution_time');
|
200 |
+
else $maximum_execute = __('N/A', 'gallery_bank');
|
201 |
+
// Get PHP Memory Limit
|
202 |
+
if(ini_get('memory_limit')) $memory_limit = ini_get('memory_limit');
|
203 |
+
else $memory_limit = __('N/A', 'gallery_bank');
|
204 |
+
// Get actual memory_get_usage
|
205 |
+
if (function_exists('memory_get_usage')) $memory_usage = round(memory_get_usage() / 1024 / 1024, 2) . __(' MByte', 'gallery_bank');
|
206 |
+
else $memory_usage = __('N/A', 'gallery_bank');
|
207 |
+
// required for EXIF read
|
208 |
+
if (is_callable('exif_read_data')) $exif = __('Yes', 'gallery_bank'). " ( V" . substr(phpversion('exif'),0,4) . ")" ;
|
209 |
+
else $exif = __('No', 'gallery_bank');
|
210 |
+
// required for meta data
|
211 |
+
if (is_callable('iptcparse')) $iptc = __('Yes', 'gallery_bank');
|
212 |
+
else $iptc = __('No', 'gallery_bank');
|
213 |
+
// required for meta data
|
214 |
+
if (is_callable('xml_parser_create')) $xml = __('Yes', 'gallery_bank');
|
215 |
+
else $xml = __('No', 'gallery_bank');
|
216 |
+
|
217 |
+
// Get Read Write permissions
|
218 |
+
error_reporting('0');
|
219 |
+
|
220 |
+
$fileName = GALLERY_BK_PLUGIN_DIR."/gallery-uploads/temp.txt";
|
221 |
+
$myFile0 = fopen($fileName, 'w');//w indicates you can write text to the file
|
222 |
+
fclose($myFile);
|
223 |
+
if(file_exists($fileName))
|
224 |
+
{
|
225 |
+
$WRpermission = __('On', 'gallery_bank');
|
226 |
+
}
|
227 |
+
else
|
228 |
+
{
|
229 |
+
$WRpermission = __('Off', 'gallery_bank');
|
230 |
+
}
|
231 |
+
|
232 |
+
|
233 |
+
?>
|
234 |
+
<li><strong><?php _e('Operating System', 'gallery_bank'); ?> : </strong> <span><?php echo PHP_OS; ?> (<?php echo (PHP_INT_SIZE * 8) ?> Bit)</span></li>
|
235 |
+
<li><strong><?php _e('Server', 'gallery_bank'); ?> : </strong> <span><?php echo $_SERVER["SERVER_SOFTWARE"]; ?></span></li>
|
236 |
+
<li><strong><?php _e('Read Permissions', 'gallery_bank'); ?> : </strong> <span><?php echo $WRpermission; ?></span></li>
|
237 |
+
<li><strong><?php _e('Write Permissions', 'gallery_bank'); ?> : </strong> <span><?php echo $WRpermission; ?></span></li>
|
238 |
+
<li><strong><?php _e('Memory usage', 'gallery_bank'); ?> :</strong> <span><?php echo $memory_usage; ?></span></li>
|
239 |
+
<li><strong><?php _e('MYSQL Version', 'gallery_bank'); ?> : </strong> <span><?php echo $sql_version; ?></span></li>
|
240 |
+
<li><strong><?php _e('SQL Mode', 'gallery_bank'); ?> : </strong> <span><?php echo $sqlmode; ?></span></li>
|
241 |
+
<li><strong><?php _e('PHP Version', 'gallery_bank'); ?> : </strong> <span><?php echo PHP_VERSION; ?></span></li>
|
242 |
+
<li><strong><?php _e('PHP Safe Mode', 'gallery_bank'); ?> : </strong> <span><?php echo $safemode; ?></span></li>
|
243 |
+
<li><strong><?php _e('PHP Allow URL fopen', 'gallery_bank'); ?> : </strong> <span><?php echo $allowurlfopen; ?></span></li>
|
244 |
+
<li><strong><?php _e('PHP Memory Limit', 'gallery_bank'); ?> : </strong> <span><?php echo $memory_limit; ?></span></li>
|
245 |
+
<li><strong><?php _e('PHP Max Upload Size', 'gallery_bank'); ?> : </strong> <span><?php echo $upload_maximum; ?></span></li>
|
246 |
+
<li><strong><?php _e('PHP Max Post Size', 'gallery_bank'); ?> : </strong> <span><?php echo $post_maximum; ?></span></li>
|
247 |
+
<li><strong><?php _e('PCRE Backtracking Limit', 'gallery_bank'); ?> : </strong> <span><?php echo $backtrack_lmt; ?></span></li>
|
248 |
+
<li><strong><?php _e('PHP Max Script Execute Time', 'gallery_bank'); ?> : </strong> <span><?php echo $maximum_execute; ?>s</span></li>
|
249 |
+
<li><strong><?php _e('PHP Exif support', 'gallery_bank'); ?> : </strong> <span><?php echo $exif; ?></span></li>
|
250 |
+
<li><strong><?php _e('PHP IPTC support', 'gallery_bank'); ?> : </strong> <span><?php echo $iptc; ?></span></li>
|
251 |
+
<li><strong><?php _e('PHP XML support', 'gallery_bank'); ?> : </strong> <span><?php echo $xml; ?></span></li>
|
252 |
+
</ul>
|
253 |
+
</div>
|
254 |
</div>
|
255 |
</div>
|
256 |
</div>
|
288 |
});
|
289 |
}
|
290 |
function delete_all_albums()
|
291 |
+
{
|
292 |
+
bootbox.confirm("<?php _e("Are you sure you want to delete all Albums?", gallery_bank ); ?>", function(confirmed)
|
293 |
{
|
294 |
+
console.log("Confirmed: "+confirmed);
|
295 |
+
if(confirmed == true)
|
296 |
{
|
297 |
+
jQuery.post(ajaxurl, "¶m=delete_all_albums&action=album_gallery_library", function(data)
|
|
|
298 |
{
|
299 |
+
var check_page = "<?php echo intval($_REQUEST['page']); ?>";
|
300 |
+
window.location.href = "admin.php?page="+check_page;
|
301 |
+
});
|
302 |
+
|
303 |
+
}
|
304 |
+
});
|
305 |
+
}
|
306 |
+
function allowTracking()
|
307 |
+
{
|
308 |
+
var checkProp = jQuery("#allow-tracking").prop("checked");
|
309 |
+
|
310 |
+
if(checkProp == true)
|
311 |
+
{
|
312 |
+
<?php
|
313 |
+
update_option( 'allow_tracking_gb', 'yes' );
|
314 |
+
?>
|
315 |
+
}
|
316 |
+
else
|
317 |
+
{
|
318 |
+
<?php
|
319 |
+
update_option( 'allow_tracking_gb', 'no' );
|
320 |
+
?>
|
321 |
}
|
322 |
+
}
|
323 |
+
|
324 |
</script>
|
325 |
<?php
|
326 |
}
|