Version Description
- added search images in gallery (optional), optional info, resize.
Download this release
Release Info
Developer | webdorado |
Plugin | Photo Gallery by WD – Responsive Photo Gallery |
Version | 1.1.15 |
Comparing to | |
See all releases |
Code changes from version 1.1.14 to 1.1.15
- admin/controllers/BWGControllerGalleries_bwg.php +110 -7
- admin/controllers/BWGControllerOptions_bwg.php +10 -0
- admin/models/BWGModelOptions_bwg.php +5 -0
- admin/views/BWGViewBWGShortcode.php +106 -1
- admin/views/BWGViewGalleries_bwg.php +13 -1
- admin/views/BWGViewOptions_bwg.php +59 -0
- css/bwg_shortcode.css +1 -1
- css/bwg_tables.css +14 -3
- filemanager/UploadHandler.php +8 -1
- framework/WDWLibrary.php +89 -1
- frontend/models/BWGModelAlbum_compact_preview.php +17 -3
- frontend/models/BWGModelAlbum_extended_preview.php +16 -2
- frontend/models/BWGModelImage_browser.php +16 -2
- frontend/models/BWGModelThumbnails.php +38 -4
- frontend/models/BWGModelWidget.php +1 -1
- frontend/views/BWGViewAlbum_compact_preview.php +61 -11
- frontend/views/BWGViewAlbum_extended_preview.php +61 -11
- frontend/views/BWGViewGalleryBox.php +7 -10
- frontend/views/BWGViewImage_browser.php +26 -6
- frontend/views/BWGViewThumbnails.php +28 -9
- js/bwg.js +16 -1
- js/bwg_frontend.js +19 -18
- js/bwg_shortcode.js +30 -0
- photo-gallery.php +19 -2
- readme.txt +65 -5
- update/bwg_update.php +8 -0
admin/controllers/BWGControllerGalleries_bwg.php
CHANGED
@@ -255,7 +255,7 @@ class BWGControllerGalleries_bwg {
|
|
255 |
}
|
256 |
}
|
257 |
}
|
258 |
-
|
259 |
public function image_set_watermark() {
|
260 |
global $wpdb;
|
261 |
global $WD_BWG_UPLOAD_DIR;
|
@@ -273,20 +273,123 @@ class BWGControllerGalleries_bwg {
|
|
273 |
case 'image':
|
274 |
foreach ($images as $image) {
|
275 |
if (isset($_POST['check_' . $image->id])) {
|
276 |
-
$this->set_image_watermark
|
277 |
}
|
278 |
}
|
279 |
break;
|
280 |
-
}
|
281 |
}
|
282 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
283 |
function bwg_hex2rgb($hex) {
|
284 |
$hex = str_replace("#", "", $hex);
|
285 |
-
if(strlen($hex) == 3) {
|
286 |
$r = hexdec(substr($hex,0,1).substr($hex,0,1));
|
287 |
$g = hexdec(substr($hex,1,1).substr($hex,1,1));
|
288 |
$b = hexdec(substr($hex,2,1).substr($hex,2,1));
|
289 |
-
}
|
|
|
290 |
$r = hexdec(substr($hex,0,2));
|
291 |
$g = hexdec(substr($hex,2,2));
|
292 |
$b = hexdec(substr($hex,4,2));
|
@@ -294,7 +397,7 @@ class BWGControllerGalleries_bwg {
|
|
294 |
$rgb = array($r, $g, $b);
|
295 |
return $rgb;
|
296 |
}
|
297 |
-
|
298 |
function bwg_imagettfbboxdimensions($font_size, $font_angle, $font, $text) {
|
299 |
$box = @ImageTTFBBox($font_size, $font_angle, $font, $text) or die;
|
300 |
$max_x = max(array($box[0], $box[2], $box[4], $box[6]));
|
255 |
}
|
256 |
}
|
257 |
}
|
258 |
+
|
259 |
public function image_set_watermark() {
|
260 |
global $wpdb;
|
261 |
global $WD_BWG_UPLOAD_DIR;
|
273 |
case 'image':
|
274 |
foreach ($images as $image) {
|
275 |
if (isset($_POST['check_' . $image->id])) {
|
276 |
+
$this->set_image_watermark(ABSPATH . $WD_BWG_UPLOAD_DIR . $image->image_url, ABSPATH . $WD_BWG_UPLOAD_DIR . $image->image_url, $options->built_in_watermark_url, $options->built_in_watermark_size, $options->built_in_watermark_size, $options->built_in_watermark_position);
|
277 |
}
|
278 |
}
|
279 |
break;
|
280 |
+
}
|
281 |
}
|
282 |
+
|
283 |
+
public function image_resize() {
|
284 |
+
global $wpdb;
|
285 |
+
global $WD_BWG_UPLOAD_DIR;
|
286 |
+
$gallery_id = ((isset($_POST['current_id'])) ? esc_html(stripslashes($_POST['current_id'])) : 0);
|
287 |
+
$image_width = ((isset($_POST['image_width'])) ? esc_html(stripslashes($_POST['image_width'])) : 1600);
|
288 |
+
$image_height = ((isset($_POST['image_height'])) ? esc_html(stripslashes($_POST['image_height'])) : 1200);
|
289 |
+
$images = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE gallery_id="%d"', $gallery_id));
|
290 |
+
foreach ($images as $image) {
|
291 |
+
if (isset($_POST['check_' . $image->id]) || isset($_POST['check_all_items'])) {
|
292 |
+
$this->bwg_scaled_image(ABSPATH . $WD_BWG_UPLOAD_DIR . $image->image_url, $image_width, $image_height);
|
293 |
+
}
|
294 |
+
}
|
295 |
+
}
|
296 |
+
|
297 |
+
function bwg_scaled_image($file_path, $max_width = 0, $max_height = 0, $crop = FALSE) {
|
298 |
+
$file_path = htmlspecialchars_decode($file_path, ENT_COMPAT | ENT_QUOTES);
|
299 |
+
if (!function_exists('getimagesize')) {
|
300 |
+
error_log('Function not found: getimagesize');
|
301 |
+
return FALSE;
|
302 |
+
}
|
303 |
+
list($img_width, $img_height, $type) = @getimagesize($file_path);
|
304 |
+
if (!$img_width || !$img_height) {
|
305 |
+
return FALSE;
|
306 |
+
}
|
307 |
+
$scale = min(
|
308 |
+
$max_width / $img_width,
|
309 |
+
$max_height / $img_height
|
310 |
+
);
|
311 |
+
ini_set('memory_limit', '-1');
|
312 |
+
if (($scale >= 1) || (($max_width === 0) && ($max_height === 0))) {
|
313 |
+
// if ($file_path !== $new_file_path) {
|
314 |
+
// return copy($file_path, $new_file_path);
|
315 |
+
// }
|
316 |
+
return TRUE;
|
317 |
+
}
|
318 |
+
|
319 |
+
if (!function_exists('imagecreatetruecolor')) {
|
320 |
+
error_log('Function not found: imagecreatetruecolor');
|
321 |
+
return FALSE;
|
322 |
+
}
|
323 |
+
if (!$crop) {
|
324 |
+
$new_width = $img_width * $scale;
|
325 |
+
$new_height = $img_height * $scale;
|
326 |
+
$dst_x = 0;
|
327 |
+
$dst_y = 0;
|
328 |
+
$new_img = @imagecreatetruecolor($new_width, $new_height);
|
329 |
+
}
|
330 |
+
else {
|
331 |
+
if (($img_width / $img_height) >= ($max_width / $max_height)) {
|
332 |
+
$new_width = $img_width / ($img_height / $max_height);
|
333 |
+
$new_height = $max_height;
|
334 |
+
}
|
335 |
+
else {
|
336 |
+
$new_width = $max_width;
|
337 |
+
$new_height = $img_height / ($img_width / $max_width);
|
338 |
+
}
|
339 |
+
$dst_x = 0 - ($new_width - $max_width) / 2;
|
340 |
+
$dst_y = 0 - ($new_height - $max_height) / 2;
|
341 |
+
$new_img = @imagecreatetruecolor($max_width, $max_height);
|
342 |
+
}
|
343 |
+
switch ($type) {
|
344 |
+
case 2:
|
345 |
+
$src_img = @imagecreatefromjpeg($file_path);
|
346 |
+
$write_image = 'imagejpeg';
|
347 |
+
$image_quality = 90;
|
348 |
+
break;
|
349 |
+
case 1:
|
350 |
+
@imagecolortransparent($new_img, @imagecolorallocate($new_img, 0, 0, 0));
|
351 |
+
$src_img = @imagecreatefromgif($file_path);
|
352 |
+
$write_image = 'imagegif';
|
353 |
+
$image_quality = NULL;
|
354 |
+
break;
|
355 |
+
case 3:
|
356 |
+
@imagecolortransparent($new_img, @imagecolorallocate($new_img, 0, 0, 0));
|
357 |
+
@imagealphablending($new_img, FALSE);
|
358 |
+
@imagesavealpha($new_img, TRUE);
|
359 |
+
$src_img = @imagecreatefrompng($file_path);
|
360 |
+
$write_image = 'imagepng';
|
361 |
+
$image_quality = 9;
|
362 |
+
break;
|
363 |
+
default:
|
364 |
+
$src_img = NULL;
|
365 |
+
}
|
366 |
+
$success = $src_img && @imagecopyresampled(
|
367 |
+
$new_img,
|
368 |
+
$src_img,
|
369 |
+
$dst_x,
|
370 |
+
$dst_y,
|
371 |
+
0,
|
372 |
+
0,
|
373 |
+
$new_width,
|
374 |
+
$new_height,
|
375 |
+
$img_width,
|
376 |
+
$img_height
|
377 |
+
) && $write_image($new_img, $file_path, $image_quality);
|
378 |
+
// Free up memory (imagedestroy does not delete files):
|
379 |
+
@imagedestroy($src_img);
|
380 |
+
@imagedestroy($new_img);
|
381 |
+
ini_restore('memory_limit');
|
382 |
+
return $success;
|
383 |
+
}
|
384 |
+
|
385 |
function bwg_hex2rgb($hex) {
|
386 |
$hex = str_replace("#", "", $hex);
|
387 |
+
if (strlen($hex) == 3) {
|
388 |
$r = hexdec(substr($hex,0,1).substr($hex,0,1));
|
389 |
$g = hexdec(substr($hex,1,1).substr($hex,1,1));
|
390 |
$b = hexdec(substr($hex,2,1).substr($hex,2,1));
|
391 |
+
}
|
392 |
+
else {
|
393 |
$r = hexdec(substr($hex,0,2));
|
394 |
$g = hexdec(substr($hex,2,2));
|
395 |
$b = hexdec(substr($hex,4,2));
|
397 |
$rgb = array($r, $g, $b);
|
398 |
return $rgb;
|
399 |
}
|
400 |
+
|
401 |
function bwg_imagettfbboxdimensions($font_size, $font_angle, $font, $text) {
|
402 |
$box = @ImageTTFBBox($font_size, $font_angle, $font, $text) or die;
|
403 |
$max_x = max(array($box[0], $box[2], $box[4], $box[6]));
|
admin/controllers/BWGControllerOptions_bwg.php
CHANGED
@@ -138,6 +138,8 @@ class BWGControllerOptions_bwg {
|
|
138 |
$popup_enable_facebook = (isset($_POST['popup_enable_facebook']) ? esc_html(stripslashes($_POST['popup_enable_facebook'])) : 1);
|
139 |
$popup_enable_twitter = (isset($_POST['popup_enable_twitter']) ? esc_html(stripslashes($_POST['popup_enable_twitter'])) : 1);
|
140 |
$popup_enable_google = (isset($_POST['popup_enable_google']) ? esc_html(stripslashes($_POST['popup_enable_google'])) : 1);
|
|
|
|
|
141 |
$watermark_type = (isset($_POST['watermark_type']) ? esc_html(stripslashes($_POST['watermark_type'])) : 'none');
|
142 |
$watermark_position = (isset($_POST['watermark_position']) ? esc_html(stripslashes($_POST['watermark_position'])) : 'bottom-right');
|
143 |
$watermark_width = (isset($_POST['watermark_width']) ? esc_html(stripslashes($_POST['watermark_width'])) : 600);
|
@@ -165,6 +167,9 @@ class BWGControllerOptions_bwg {
|
|
165 |
$image_role = (isset($_POST['image_role']) ? esc_html(stripslashes($_POST['image_role'])) : 0);
|
166 |
$popup_autoplay = (isset($_POST['popup_autoplay']) ? esc_html(stripslashes($_POST['popup_autoplay'])) : 0);
|
167 |
$album_view_type = (isset($_POST['album_view_type']) ? esc_html(stripslashes($_POST['album_view_type'])) : 'thumbnail');
|
|
|
|
|
|
|
168 |
|
169 |
$save = $wpdb->update($wpdb->prefix . 'bwg_option', array(
|
170 |
'images_directory' => $images_directory,
|
@@ -223,6 +228,8 @@ class BWGControllerOptions_bwg {
|
|
223 |
'popup_enable_facebook' => $popup_enable_facebook,
|
224 |
'popup_enable_twitter' => $popup_enable_twitter,
|
225 |
'popup_enable_google' => $popup_enable_google,
|
|
|
|
|
226 |
'watermark_type' => $watermark_type,
|
227 |
'watermark_position' => $watermark_position,
|
228 |
'watermark_width' => $watermark_width,
|
@@ -250,6 +257,9 @@ class BWGControllerOptions_bwg {
|
|
250 |
'image_role' => $image_role,
|
251 |
'popup_autoplay' => $popup_autoplay,
|
252 |
'album_view_type' => $album_view_type,
|
|
|
|
|
|
|
253 |
), array('id' => 1));
|
254 |
|
255 |
if ($save !== FALSE) {
|
138 |
$popup_enable_facebook = (isset($_POST['popup_enable_facebook']) ? esc_html(stripslashes($_POST['popup_enable_facebook'])) : 1);
|
139 |
$popup_enable_twitter = (isset($_POST['popup_enable_twitter']) ? esc_html(stripslashes($_POST['popup_enable_twitter'])) : 1);
|
140 |
$popup_enable_google = (isset($_POST['popup_enable_google']) ? esc_html(stripslashes($_POST['popup_enable_google'])) : 1);
|
141 |
+
$popup_enable_pinterest = (isset($_POST['popup_enable_pinterest']) ? esc_html(stripslashes($_POST['popup_enable_pinterest'])) : 0);
|
142 |
+
$popup_enable_tumblr = (isset($_POST['popup_enable_tumblr']) ? esc_html(stripslashes($_POST['popup_enable_tumblr'])) : 0);
|
143 |
$watermark_type = (isset($_POST['watermark_type']) ? esc_html(stripslashes($_POST['watermark_type'])) : 'none');
|
144 |
$watermark_position = (isset($_POST['watermark_position']) ? esc_html(stripslashes($_POST['watermark_position'])) : 'bottom-right');
|
145 |
$watermark_width = (isset($_POST['watermark_width']) ? esc_html(stripslashes($_POST['watermark_width'])) : 600);
|
167 |
$image_role = (isset($_POST['image_role']) ? esc_html(stripslashes($_POST['image_role'])) : 0);
|
168 |
$popup_autoplay = (isset($_POST['popup_autoplay']) ? esc_html(stripslashes($_POST['popup_autoplay'])) : 0);
|
169 |
$album_view_type = (isset($_POST['album_view_type']) ? esc_html(stripslashes($_POST['album_view_type'])) : 'thumbnail');
|
170 |
+
$show_search_box = (isset($_POST['show_search_box']) ? esc_html(stripslashes($_POST['show_search_box'])) : 0);
|
171 |
+
$search_box_width = (isset($_POST['search_box_width']) ? esc_html(stripslashes($_POST['search_box_width'])) : 180);
|
172 |
+
$popup_enable_info = (isset($_POST['popup_enable_info']) ? esc_html(stripslashes($_POST['popup_enable_info'])) : 1);
|
173 |
|
174 |
$save = $wpdb->update($wpdb->prefix . 'bwg_option', array(
|
175 |
'images_directory' => $images_directory,
|
228 |
'popup_enable_facebook' => $popup_enable_facebook,
|
229 |
'popup_enable_twitter' => $popup_enable_twitter,
|
230 |
'popup_enable_google' => $popup_enable_google,
|
231 |
+
'popup_enable_pinterest' => $popup_enable_pinterest,
|
232 |
+
'popup_enable_tumblr' => $popup_enable_tumblr,
|
233 |
'watermark_type' => $watermark_type,
|
234 |
'watermark_position' => $watermark_position,
|
235 |
'watermark_width' => $watermark_width,
|
257 |
'image_role' => $image_role,
|
258 |
'popup_autoplay' => $popup_autoplay,
|
259 |
'album_view_type' => $album_view_type,
|
260 |
+
'show_search_box' => $show_search_box,
|
261 |
+
'search_box_width' => $search_box_width,
|
262 |
+
'popup_enable_info' => $popup_enable_info,
|
263 |
), array('id' => 1));
|
264 |
|
265 |
if ($save !== FALSE) {
|
admin/models/BWGModelOptions_bwg.php
CHANGED
@@ -89,6 +89,8 @@ class BWGModelOptions_bwg {
|
|
89 |
$row->popup_enable_facebook = 1;
|
90 |
$row->popup_enable_twitter = 1;
|
91 |
$row->popup_enable_google = 1;
|
|
|
|
|
92 |
|
93 |
$row->watermark_type = 'none';
|
94 |
$row->watermark_position = 'bottom-left';
|
@@ -119,6 +121,9 @@ class BWGModelOptions_bwg {
|
|
119 |
$row->image_role = 0;
|
120 |
$row->popup_autoplay = 0;
|
121 |
$row->album_view_type = 'thumbnail';
|
|
|
|
|
|
|
122 |
}
|
123 |
return $row;
|
124 |
}
|
89 |
$row->popup_enable_facebook = 1;
|
90 |
$row->popup_enable_twitter = 1;
|
91 |
$row->popup_enable_google = 1;
|
92 |
+
$row->popup_enable_pinterest = 0;
|
93 |
+
$row->popup_enable_tumblr = 0;
|
94 |
|
95 |
$row->watermark_type = 'none';
|
96 |
$row->watermark_position = 'bottom-left';
|
121 |
$row->image_role = 0;
|
122 |
$row->popup_autoplay = 0;
|
123 |
$row->album_view_type = 'thumbnail';
|
124 |
+
$row->show_search_box = 0;
|
125 |
+
$row->search_box_width = 180;
|
126 |
+
$row->popup_enable_info = 1;
|
127 |
}
|
128 |
return $row;
|
129 |
}
|
admin/views/BWGViewBWGShortcode.php
CHANGED
@@ -205,7 +205,18 @@ class BWGViewBWGShortcode {
|
|
205 |
<input type="radio" name="order_by" id="order_by_0" value="desc" /><label for="order_by_0">Descending</label>
|
206 |
</td>
|
207 |
</tr>
|
208 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
209 |
<!--Thumbnails, Masonry viewies-->
|
210 |
<tr id="tr_masonry_hor_ver">
|
211 |
<td class="spider_label"><label>Masonry: </label></td>
|
@@ -640,6 +651,13 @@ class BWGViewBWGShortcode {
|
|
640 |
<input type="radio" name="popup_enable_fullscreen" id="popup_fullscreen_no" value="0" <?php echo ($option_row->popup_enable_fullscreen) ? '' : 'checked'; ?> /><label for="popup_fullscreen_no">No</label>
|
641 |
</td>
|
642 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
643 |
<tr id="tr_popup_enable_comment">
|
644 |
<td title="Enable comments for images<br /><br />This option is disabled in free version." class="spider_label spider_free_version_label"><label>Enable comments: </label></td>
|
645 |
<td>
|
@@ -668,6 +686,20 @@ class BWGViewBWGShortcode {
|
|
668 |
<input disabled="disabled" type="radio" name="popup_enable_google" id="popup_google_no" value="0" <?php echo ($option_row->popup_enable_google) ? '' : 'checked'; ?> /><label for="popup_google_no">No</label>
|
669 |
</td>
|
670 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
671 |
</tbody>
|
672 |
</table>
|
673 |
</div>
|
@@ -834,6 +866,17 @@ class BWGViewBWGShortcode {
|
|
834 |
else {
|
835 |
jQuery("#order_by_0").attr('checked', 'checked');
|
836 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
837 |
jQuery("#image_column_number").val(short_code['image_column_number']);
|
838 |
jQuery("#images_per_page").val(short_code['images_per_page']);
|
839 |
jQuery("#image_title_" + short_code['image_title']).attr('checked', 'checked');
|
@@ -923,6 +966,17 @@ class BWGViewBWGShortcode {
|
|
923 |
else {
|
924 |
jQuery("#order_by_0").attr('checked', 'checked');
|
925 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
926 |
jQuery("#image_browser_width").val(short_code['image_browser_width']);
|
927 |
if (short_code['image_browser_title_enable'] == 1) {
|
928 |
jQuery("#image_browser_title_yes").attr('checked', 'checked');
|
@@ -942,6 +996,17 @@ class BWGViewBWGShortcode {
|
|
942 |
case 'album_compact_preview': {
|
943 |
jQuery("select[id=album] option[value='" + short_code['album_id'] + "']").attr('selected', 'selected');
|
944 |
jQuery("select[id=sort_by] option[value='" + short_code['sort_by'] + "']").attr('selected', 'selected');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
945 |
jQuery("#compuct_album_column_number").val(short_code['compuct_album_column_number']);
|
946 |
jQuery("#compuct_albums_per_page").val(short_code['compuct_albums_per_page']);
|
947 |
jQuery("#compuct_album_title_" + short_code['compuct_album_title']).attr('checked', 'checked');
|
@@ -970,6 +1035,17 @@ class BWGViewBWGShortcode {
|
|
970 |
case 'album_extended_preview': {
|
971 |
jQuery("select[id=album] option[value='" + short_code['album_id'] + "']").attr('selected', 'selected');
|
972 |
jQuery("select[id=sort_by] option[value='" + short_code['sort_by'] + "']").attr('selected', 'selected');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
973 |
jQuery("#extended_albums_per_page").val(short_code['extended_albums_per_page']);
|
974 |
jQuery("#extended_album_height").val(short_code['extended_album_height']);
|
975 |
if (short_code['extended_album_description_enable'] == 1) {
|
@@ -1038,6 +1114,12 @@ class BWGViewBWGShortcode {
|
|
1038 |
else {
|
1039 |
jQuery("#popup_fullscreen_no").attr('checked', 'checked');
|
1040 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
1041 |
if (short_code['popup_enable_comment'] == 1) {
|
1042 |
jQuery("#popup_comment_yes").attr('checked', 'checked');
|
1043 |
}
|
@@ -1062,6 +1144,18 @@ class BWGViewBWGShortcode {
|
|
1062 |
else {
|
1063 |
jQuery("#popup_google_no").attr('checked', 'checked');
|
1064 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1065 |
}
|
1066 |
else {
|
1067 |
jQuery("#popup_ctrl_btn_no").attr('checked', 'checked');
|
@@ -1133,6 +1227,8 @@ class BWGViewBWGShortcode {
|
|
1133 |
tagtext += ' gallery_id="' + jQuery("#gallery").val() + '"';
|
1134 |
tagtext += ' sort_by="' + jQuery("#sort_by").val() + '"';
|
1135 |
tagtext += ' order_by="' + jQuery("input[name=order_by]:checked").val() + '"';
|
|
|
|
|
1136 |
tagtext += ' image_column_number="' + jQuery("#image_column_number").val() + '"';
|
1137 |
tagtext += ' images_per_page="' + jQuery("#images_per_page").val() + '"';
|
1138 |
tagtext += ' image_title="' + jQuery("input[name=image_title]:checked").val() + '"';
|
@@ -1168,6 +1264,8 @@ class BWGViewBWGShortcode {
|
|
1168 |
tagtext += ' gallery_id="' + jQuery("#gallery").val() + '"';
|
1169 |
tagtext += ' sort_by="' + jQuery("#sort_by").val() + '"';
|
1170 |
tagtext += ' order_by="' + jQuery("input[name=order_by]:checked").val() + '"';
|
|
|
|
|
1171 |
tagtext += ' image_browser_width="' + jQuery("#image_browser_width").val() + '"';
|
1172 |
tagtext += ' image_browser_title_enable="' + jQuery("input[name=image_browser_title_enable]:checked").val() + '"';
|
1173 |
tagtext += ' image_browser_description_enable="' + jQuery("input[name=image_browser_description_enable]:checked").val() + '"';
|
@@ -1178,6 +1276,8 @@ class BWGViewBWGShortcode {
|
|
1178 |
tagtext += ' album_id="' + jQuery("#album").val() + '"';
|
1179 |
tagtext += ' sort_by="order"';
|
1180 |
tagtext += ' order_by="asc"';
|
|
|
|
|
1181 |
tagtext += ' compuct_album_column_number="' + jQuery("#compuct_album_column_number").val() + '"';
|
1182 |
tagtext += ' compuct_albums_per_page="' + jQuery("#compuct_albums_per_page").val() + '"';
|
1183 |
tagtext += ' compuct_album_title="' + jQuery("input[name=compuct_album_title]:checked").val() + '"';
|
@@ -1197,6 +1297,8 @@ class BWGViewBWGShortcode {
|
|
1197 |
tagtext += ' album_id="' + jQuery("#album").val() + '"';
|
1198 |
tagtext += ' sort_by="order"';
|
1199 |
tagtext += ' order_by="asc"';
|
|
|
|
|
1200 |
tagtext += ' extended_albums_per_page="' + jQuery("#extended_albums_per_page").val() + '"';
|
1201 |
tagtext += ' extended_album_height="' + jQuery("#extended_album_height").val() + '"';
|
1202 |
tagtext += ' extended_album_description_enable="' + jQuery("input[name=extended_album_description_enable]:checked").val() + '"';
|
@@ -1225,10 +1327,13 @@ class BWGViewBWGShortcode {
|
|
1225 |
tagtext += ' popup_filmstrip_height="' + jQuery("#popup_filmstrip_height").val() + '"';
|
1226 |
tagtext += ' popup_enable_ctrl_btn="' + jQuery("input[name=popup_enable_ctrl_btn]:checked").val() + '"';
|
1227 |
tagtext += ' popup_enable_fullscreen="' + jQuery("input[name=popup_enable_fullscreen]:checked").val() + '"';
|
|
|
1228 |
tagtext += ' popup_enable_comment="' + jQuery("input[name=popup_enable_comment]:checked").val() + '"';
|
1229 |
tagtext += ' popup_enable_facebook="' + jQuery("input[name=popup_enable_facebook]:checked").val() + '"';
|
1230 |
tagtext += ' popup_enable_twitter="' + jQuery("input[name=popup_enable_twitter]:checked").val() + '"';
|
1231 |
tagtext += ' popup_enable_google="' + jQuery("input[name=popup_enable_google]:checked").val() + '"';
|
|
|
|
|
1232 |
}
|
1233 |
// Watermark parameters.
|
1234 |
tagtext += ' watermark_type="' + jQuery("input[name=watermark_type]:checked").val() + '"';
|
205 |
<input type="radio" name="order_by" id="order_by_0" value="desc" /><label for="order_by_0">Descending</label>
|
206 |
</td>
|
207 |
</tr>
|
208 |
+
<tr id="tr_show_search_box">
|
209 |
+
<td class="spider_label"><label>Show search box: </label></td>
|
210 |
+
<td>
|
211 |
+
<input type="radio" name="show_search_box" id="show_search_box_1" value="1" <?php if ($option_row->show_search_box) echo 'checked="checked"'; ?> onchange="bwg_show_search_box()" /><label for="show_search_box_1">Yes</label>
|
212 |
+
<input type="radio" name="show_search_box" id="show_search_box_0" value="0" <?php if (!$option_row->show_search_box) echo 'checked="checked"'; ?> onchange="bwg_show_search_box()" /><label for="show_search_box_0">No</label>
|
213 |
+
</td>
|
214 |
+
</tr>
|
215 |
+
<tr id="tr_search_box_width">
|
216 |
+
<td class="spider_label"><label for="search_box_width">Search box width: </label></td>
|
217 |
+
<td><input type="text" name="search_box_width" id="search_box_width" value="<?php echo $option_row->search_box_width; ?>" class="spider_int_input" /> px</td>
|
218 |
+
</tr>
|
219 |
+
|
220 |
<!--Thumbnails, Masonry viewies-->
|
221 |
<tr id="tr_masonry_hor_ver">
|
222 |
<td class="spider_label"><label>Masonry: </label></td>
|
651 |
<input type="radio" name="popup_enable_fullscreen" id="popup_fullscreen_no" value="0" <?php echo ($option_row->popup_enable_fullscreen) ? '' : 'checked'; ?> /><label for="popup_fullscreen_no">No</label>
|
652 |
</td>
|
653 |
</tr>
|
654 |
+
<tr id="tr_popup_enable_info">
|
655 |
+
<td title="Enable title, description for images" class="spider_label"><label>Enable info: </label></td>
|
656 |
+
<td>
|
657 |
+
<input type="radio" name="popup_enable_info" id="popup_info_yes" value="1" <?php echo ($option_row->popup_enable_info) ? 'checked="checked"' : ''; ?> /><label for="popup_info_yes">Yes</label>
|
658 |
+
<input type="radio" name="popup_enable_info" id="popup_info_no" value="0" <?php echo ($option_row->popup_enable_info) ? '' : 'checked="checked"'; ?> /><label for="popup_info_no">No</label>
|
659 |
+
</td>
|
660 |
+
</tr>
|
661 |
<tr id="tr_popup_enable_comment">
|
662 |
<td title="Enable comments for images<br /><br />This option is disabled in free version." class="spider_label spider_free_version_label"><label>Enable comments: </label></td>
|
663 |
<td>
|
686 |
<input disabled="disabled" type="radio" name="popup_enable_google" id="popup_google_no" value="0" <?php echo ($option_row->popup_enable_google) ? '' : 'checked'; ?> /><label for="popup_google_no">No</label>
|
687 |
</td>
|
688 |
</tr>
|
689 |
+
<tr id="tr_popup_enable_pinterest">
|
690 |
+
<td title="Enable Pinterest share button for images<br /><br />This option is disabled in free version." class="spider_label spider_free_version_label"><label>Enable Pinterest button: </label></td>
|
691 |
+
<td>
|
692 |
+
<input disabled="disabled" type="radio" name="popup_enable_pinterest" id="popup_pinterest_yes" value="1" <?php echo ($option_row->popup_enable_pinterest) ? 'checked' : ''; ?> /><label for="popup_pinterest_yes">Yes</label>
|
693 |
+
<input disabled="disabled" type="radio" name="popup_enable_pinterest" id="popup_pinterest_no" value="0" <?php echo ($option_row->popup_enable_pinterest) ? '' : 'checked'; ?> /><label for="popup_pinterest_no">No</label>
|
694 |
+
</td>
|
695 |
+
</tr>
|
696 |
+
<tr id="tr_popup_enable_tumblr">
|
697 |
+
<td title="Enable Tumblr share button for images<br /><br />This option is disabled in free version." class="spider_label spider_free_version_label"><label>Enable Tumblr button: </label></td>
|
698 |
+
<td>
|
699 |
+
<input disabled="disabled" type="radio" name="popup_enable_tumblr" id="popup_tumblr_yes" value="1" <?php echo ($option_row->popup_enable_tumblr) ? 'checked' : ''; ?> /><label for="popup_tumblr_yes">Yes</label>
|
700 |
+
<input disabled="disabled" type="radio" name="popup_enable_tumblr" id="popup_tumblr_no" value="0" <?php echo ($option_row->popup_enable_tumblr) ? '' : 'checked'; ?> /><label for="popup_tumblr_no">No</label>
|
701 |
+
</td>
|
702 |
+
</tr>
|
703 |
</tbody>
|
704 |
</table>
|
705 |
</div>
|
866 |
else {
|
867 |
jQuery("#order_by_0").attr('checked', 'checked');
|
868 |
}
|
869 |
+
if (short_code['show_search_box'] == 1) {
|
870 |
+
jQuery("#show_search_box_1").attr('checked', 'checked');
|
871 |
+
jQuery("#tr_search_box_width").css('display', '');
|
872 |
+
}
|
873 |
+
else {
|
874 |
+
jQuery("#show_search_box_0").attr('checked', 'checked');
|
875 |
+
jQuery("#tr_search_box_width").css('display', 'none');
|
876 |
+
}
|
877 |
+
if (short_code['search_box_width']) {
|
878 |
+
jQuery("#search_box_width").val(short_code['search_box_width']);
|
879 |
+
}
|
880 |
jQuery("#image_column_number").val(short_code['image_column_number']);
|
881 |
jQuery("#images_per_page").val(short_code['images_per_page']);
|
882 |
jQuery("#image_title_" + short_code['image_title']).attr('checked', 'checked');
|
966 |
else {
|
967 |
jQuery("#order_by_0").attr('checked', 'checked');
|
968 |
}
|
969 |
+
if (short_code['show_search_box'] == 1) {
|
970 |
+
jQuery("#show_search_box_1").attr('checked', 'checked');
|
971 |
+
jQuery("#tr_search_box_width").css('display', '');
|
972 |
+
}
|
973 |
+
else {
|
974 |
+
jQuery("#show_search_box_0").attr('checked', 'checked');
|
975 |
+
jQuery("#tr_search_box_width").css('display', 'none');
|
976 |
+
}
|
977 |
+
if (short_code['search_box_width']) {
|
978 |
+
jQuery("#search_box_width").val(short_code['search_box_width']);
|
979 |
+
}
|
980 |
jQuery("#image_browser_width").val(short_code['image_browser_width']);
|
981 |
if (short_code['image_browser_title_enable'] == 1) {
|
982 |
jQuery("#image_browser_title_yes").attr('checked', 'checked');
|
996 |
case 'album_compact_preview': {
|
997 |
jQuery("select[id=album] option[value='" + short_code['album_id'] + "']").attr('selected', 'selected');
|
998 |
jQuery("select[id=sort_by] option[value='" + short_code['sort_by'] + "']").attr('selected', 'selected');
|
999 |
+
if (short_code['show_search_box'] == 1) {
|
1000 |
+
jQuery("#show_search_box_1").attr('checked', 'checked');
|
1001 |
+
jQuery("#tr_search_box_width").css('display', '');
|
1002 |
+
}
|
1003 |
+
else {
|
1004 |
+
jQuery("#show_search_box_0").attr('checked', 'checked');
|
1005 |
+
jQuery("#tr_search_box_width").css('display', 'none');
|
1006 |
+
}
|
1007 |
+
if (short_code['search_box_width']) {
|
1008 |
+
jQuery("#search_box_width").val(short_code['search_box_width']);
|
1009 |
+
}
|
1010 |
jQuery("#compuct_album_column_number").val(short_code['compuct_album_column_number']);
|
1011 |
jQuery("#compuct_albums_per_page").val(short_code['compuct_albums_per_page']);
|
1012 |
jQuery("#compuct_album_title_" + short_code['compuct_album_title']).attr('checked', 'checked');
|
1035 |
case 'album_extended_preview': {
|
1036 |
jQuery("select[id=album] option[value='" + short_code['album_id'] + "']").attr('selected', 'selected');
|
1037 |
jQuery("select[id=sort_by] option[value='" + short_code['sort_by'] + "']").attr('selected', 'selected');
|
1038 |
+
if (short_code['show_search_box'] == 1) {
|
1039 |
+
jQuery("#show_search_box_1").attr('checked', 'checked');
|
1040 |
+
jQuery("#tr_search_box_width").css('display', '');
|
1041 |
+
}
|
1042 |
+
else {
|
1043 |
+
jQuery("#show_search_box_0").attr('checked', 'checked');
|
1044 |
+
jQuery("#tr_search_box_width").css('display', 'none');
|
1045 |
+
}
|
1046 |
+
if (short_code['search_box_width']) {
|
1047 |
+
jQuery("#search_box_width").val(short_code['search_box_width']);
|
1048 |
+
}
|
1049 |
jQuery("#extended_albums_per_page").val(short_code['extended_albums_per_page']);
|
1050 |
jQuery("#extended_album_height").val(short_code['extended_album_height']);
|
1051 |
if (short_code['extended_album_description_enable'] == 1) {
|
1114 |
else {
|
1115 |
jQuery("#popup_fullscreen_no").attr('checked', 'checked');
|
1116 |
}
|
1117 |
+
if (short_code['popup_enable_info'] == 1 || !short_code['popup_enable_info']) {
|
1118 |
+
jQuery("#popup_info_yes").attr('checked', 'checked');
|
1119 |
+
}
|
1120 |
+
else {
|
1121 |
+
jQuery("#popup_info_no").attr('checked', 'checked');
|
1122 |
+
}
|
1123 |
if (short_code['popup_enable_comment'] == 1) {
|
1124 |
jQuery("#popup_comment_yes").attr('checked', 'checked');
|
1125 |
}
|
1144 |
else {
|
1145 |
jQuery("#popup_google_no").attr('checked', 'checked');
|
1146 |
}
|
1147 |
+
if (short_code['popup_enable_pinterest'] == 1) {
|
1148 |
+
jQuery("#popup_pinterest_yes").attr('checked', 'checked');
|
1149 |
+
}
|
1150 |
+
else {
|
1151 |
+
jQuery("#popup_pinterest_no").attr('checked', 'checked');
|
1152 |
+
}
|
1153 |
+
if (short_code['popup_enable_tumblr'] == 1) {
|
1154 |
+
jQuery("#popup_tumblr_yes").attr('checked', 'checked');
|
1155 |
+
}
|
1156 |
+
else {
|
1157 |
+
jQuery("#popup_tumblr_no").attr('checked', 'checked');
|
1158 |
+
}
|
1159 |
}
|
1160 |
else {
|
1161 |
jQuery("#popup_ctrl_btn_no").attr('checked', 'checked');
|
1227 |
tagtext += ' gallery_id="' + jQuery("#gallery").val() + '"';
|
1228 |
tagtext += ' sort_by="' + jQuery("#sort_by").val() + '"';
|
1229 |
tagtext += ' order_by="' + jQuery("input[name=order_by]:checked").val() + '"';
|
1230 |
+
tagtext += ' show_search_box="' + jQuery("input[name=show_search_box]:checked").val() + '"';
|
1231 |
+
tagtext += ' search_box_width="' + jQuery("#search_box_width").val() + '"';
|
1232 |
tagtext += ' image_column_number="' + jQuery("#image_column_number").val() + '"';
|
1233 |
tagtext += ' images_per_page="' + jQuery("#images_per_page").val() + '"';
|
1234 |
tagtext += ' image_title="' + jQuery("input[name=image_title]:checked").val() + '"';
|
1264 |
tagtext += ' gallery_id="' + jQuery("#gallery").val() + '"';
|
1265 |
tagtext += ' sort_by="' + jQuery("#sort_by").val() + '"';
|
1266 |
tagtext += ' order_by="' + jQuery("input[name=order_by]:checked").val() + '"';
|
1267 |
+
tagtext += ' show_search_box="' + jQuery("input[name=show_search_box]:checked").val() + '"';
|
1268 |
+
tagtext += ' search_box_width="' + jQuery("#search_box_width").val() + '"';
|
1269 |
tagtext += ' image_browser_width="' + jQuery("#image_browser_width").val() + '"';
|
1270 |
tagtext += ' image_browser_title_enable="' + jQuery("input[name=image_browser_title_enable]:checked").val() + '"';
|
1271 |
tagtext += ' image_browser_description_enable="' + jQuery("input[name=image_browser_description_enable]:checked").val() + '"';
|
1276 |
tagtext += ' album_id="' + jQuery("#album").val() + '"';
|
1277 |
tagtext += ' sort_by="order"';
|
1278 |
tagtext += ' order_by="asc"';
|
1279 |
+
tagtext += ' show_search_box="' + jQuery("input[name=show_search_box]:checked").val() + '"';
|
1280 |
+
tagtext += ' search_box_width="' + jQuery("#search_box_width").val() + '"';
|
1281 |
tagtext += ' compuct_album_column_number="' + jQuery("#compuct_album_column_number").val() + '"';
|
1282 |
tagtext += ' compuct_albums_per_page="' + jQuery("#compuct_albums_per_page").val() + '"';
|
1283 |
tagtext += ' compuct_album_title="' + jQuery("input[name=compuct_album_title]:checked").val() + '"';
|
1297 |
tagtext += ' album_id="' + jQuery("#album").val() + '"';
|
1298 |
tagtext += ' sort_by="order"';
|
1299 |
tagtext += ' order_by="asc"';
|
1300 |
+
tagtext += ' show_search_box="' + jQuery("input[name=show_search_box]:checked").val() + '"';
|
1301 |
+
tagtext += ' search_box_width="' + jQuery("#search_box_width").val() + '"';
|
1302 |
tagtext += ' extended_albums_per_page="' + jQuery("#extended_albums_per_page").val() + '"';
|
1303 |
tagtext += ' extended_album_height="' + jQuery("#extended_album_height").val() + '"';
|
1304 |
tagtext += ' extended_album_description_enable="' + jQuery("input[name=extended_album_description_enable]:checked").val() + '"';
|
1327 |
tagtext += ' popup_filmstrip_height="' + jQuery("#popup_filmstrip_height").val() + '"';
|
1328 |
tagtext += ' popup_enable_ctrl_btn="' + jQuery("input[name=popup_enable_ctrl_btn]:checked").val() + '"';
|
1329 |
tagtext += ' popup_enable_fullscreen="' + jQuery("input[name=popup_enable_fullscreen]:checked").val() + '"';
|
1330 |
+
tagtext += ' popup_enable_info="' + jQuery("input[name=popup_enable_info]:checked").val() + '"';
|
1331 |
tagtext += ' popup_enable_comment="' + jQuery("input[name=popup_enable_comment]:checked").val() + '"';
|
1332 |
tagtext += ' popup_enable_facebook="' + jQuery("input[name=popup_enable_facebook]:checked").val() + '"';
|
1333 |
tagtext += ' popup_enable_twitter="' + jQuery("input[name=popup_enable_twitter]:checked").val() + '"';
|
1334 |
tagtext += ' popup_enable_google="' + jQuery("input[name=popup_enable_google]:checked").val() + '"';
|
1335 |
+
tagtext += ' popup_enable_pinterest="' + jQuery("input[name=popup_enable_pinterest]:checked").val() + '"';
|
1336 |
+
tagtext += ' popup_enable_tumblr="' + jQuery("input[name=popup_enable_tumblr]:checked").val() + '"';
|
1337 |
}
|
1338 |
// Watermark parameters.
|
1339 |
tagtext += ' watermark_type="' + jQuery("input[name=watermark_type]:checked").val() + '"';
|
admin/views/BWGViewGalleries_bwg.php
CHANGED
@@ -607,6 +607,7 @@ class BWGViewGalleries_bwg {
|
|
607 |
<input class="button-primary" type="submit" onclick="spider_set_input_value('ajax_task', 'image_set_watermark');
|
608 |
spider_ajax_save('galleries_form');
|
609 |
return false;" value="Set Watermark" />
|
|
|
610 |
<input class="button-secondary" type="submit" onclick="spider_set_input_value('ajax_task', 'image_recover_all');
|
611 |
spider_ajax_save('galleries_form');
|
612 |
return false;" value="Reset" />
|
@@ -624,13 +625,24 @@ class BWGViewGalleries_bwg {
|
|
624 |
return false;
|
625 |
}" value="Delete" />
|
626 |
</div>
|
627 |
-
<div id="opacity_add_video" class="opacity_add_video bwg_opacity_video" onclick="jQuery('.opacity_add_video').hide();"></div>
|
628 |
<div id="add_video" class="opacity_add_video bwg_add_video">
|
629 |
<input type="text" id="video_url" name="video_url" value="" />
|
630 |
<input class="button-primary" type="button" onclick="if (bwg_get_video_info('video_url')) {jQuery('.opacity_add_video').hide();} return false;" value="Add to gallery" />
|
631 |
<input class="button-secondary" type="button" onclick="jQuery('.opacity_add_video').hide(); return false;" value="Cancel" />
|
632 |
<div class="spider_description">Enter YouTube or Vimeo link here.</div>
|
633 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
634 |
<div class="tablenav top">
|
635 |
<?php
|
636 |
WDWLibrary::ajax_search('Filename', $search_value, 'galleries_form');
|
607 |
<input class="button-primary" type="submit" onclick="spider_set_input_value('ajax_task', 'image_set_watermark');
|
608 |
spider_ajax_save('galleries_form');
|
609 |
return false;" value="Set Watermark" />
|
610 |
+
<input class="button-secondary" type="submit" onclick="jQuery('.opacity_resize_image').show(); return false;" value="Resize" />
|
611 |
<input class="button-secondary" type="submit" onclick="spider_set_input_value('ajax_task', 'image_recover_all');
|
612 |
spider_ajax_save('galleries_form');
|
613 |
return false;" value="Reset" />
|
625 |
return false;
|
626 |
}" value="Delete" />
|
627 |
</div>
|
628 |
+
<div id="opacity_add_video" class="opacity_resize_image opacity_add_video bwg_opacity_video" onclick="jQuery('.opacity_add_video').hide();jQuery('.opacity_resize_image').hide();"></div>
|
629 |
<div id="add_video" class="opacity_add_video bwg_add_video">
|
630 |
<input type="text" id="video_url" name="video_url" value="" />
|
631 |
<input class="button-primary" type="button" onclick="if (bwg_get_video_info('video_url')) {jQuery('.opacity_add_video').hide();} return false;" value="Add to gallery" />
|
632 |
<input class="button-secondary" type="button" onclick="jQuery('.opacity_add_video').hide(); return false;" value="Cancel" />
|
633 |
<div class="spider_description">Enter YouTube or Vimeo link here.</div>
|
634 |
</div>
|
635 |
+
<div id="" class="opacity_resize_image bwg_resize_image">
|
636 |
+
Resize images to:
|
637 |
+
<input type="text" name="image_width" id="image_width" value="1600" /> x
|
638 |
+
<input type="text" name="image_height" id="image_height" value="1200" /> px
|
639 |
+
<input class="button-primary" type="button" onclick="spider_set_input_value('ajax_task', 'image_resize');
|
640 |
+
spider_ajax_save('galleries_form');
|
641 |
+
jQuery('.opacity_resize_image').hide();
|
642 |
+
return false;" value="Resize" />
|
643 |
+
<input class="button-secondary" type="button" onclick="jQuery('.opacity_resize_image').hide(); return false;" value="Cancel" />
|
644 |
+
<div class="spider_description">The maximum size of resized image.</div>
|
645 |
+
</div>
|
646 |
<div class="tablenav top">
|
647 |
<?php
|
648 |
WDWLibrary::ajax_search('Filename', $search_value, 'galleries_form');
|
admin/views/BWGViewOptions_bwg.php
CHANGED
@@ -165,6 +165,25 @@ class BWGViewOptions_bwg {
|
|
165 |
<div class="spider_description">Only author can change an image.</div>
|
166 |
</td>
|
167 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
168 |
</tbody>
|
169 |
</table>
|
170 |
</div>
|
@@ -548,19 +567,25 @@ class BWGViewOptions_bwg {
|
|
548 |
</td>
|
549 |
<td>
|
550 |
<input type="radio" name="popup_enable_ctrl_btn" id="popup_enable_ctrl_btn_1" value="1" <?php if ($row->popup_enable_ctrl_btn) echo 'checked="checked"'; ?> onClick="bwg_enable_disable('', 'tr_popup_fullscreen', 'popup_enable_ctrl_btn_1');
|
|
|
551 |
bwg_enable_disable('', 'tr_popup_comment', 'popup_enable_ctrl_btn_1');
|
552 |
bwg_enable_disable('', 'tr_popup_facebook', 'popup_enable_ctrl_btn_1');
|
553 |
bwg_enable_disable('', 'tr_popup_twitter', 'popup_enable_ctrl_btn_1');
|
554 |
bwg_enable_disable('', 'tr_popup_google', 'popup_enable_ctrl_btn_1');
|
|
|
|
|
555 |
bwg_enable_disable('', 'tr_popup_email', 'popup_enable_ctrl_btn_1');
|
556 |
bwg_enable_disable('', 'tr_popup_captcha', 'popup_enable_ctrl_btn_1');
|
557 |
bwg_enable_disable('', 'tr_popup_download', 'popup_enable_ctrl_btn_1');
|
558 |
bwg_enable_disable('', 'tr_popup_fullsize_image', 'popup_enable_ctrl_btn_1');" /><label for="popup_enable_ctrl_btn_1">Yes</label>
|
559 |
<input type="radio" name="popup_enable_ctrl_btn" id="popup_enable_ctrl_btn_0" value="0" <?php if (!$row->popup_enable_ctrl_btn) echo 'checked="checked"'; ?> onClick="bwg_enable_disable('none', 'tr_popup_fullscreen', 'popup_enable_ctrl_btn_0');
|
|
|
560 |
bwg_enable_disable('none', 'tr_popup_comment', 'popup_enable_ctrl_btn_0');
|
561 |
bwg_enable_disable('none', 'tr_popup_facebook', 'popup_enable_ctrl_btn_0');
|
562 |
bwg_enable_disable('none', 'tr_popup_twitter', 'popup_enable_ctrl_btn_0');
|
563 |
bwg_enable_disable('none', 'tr_popup_google', 'popup_enable_ctrl_btn_0');
|
|
|
|
|
564 |
bwg_enable_disable('none', 'tr_popup_email', 'popup_enable_ctrl_btn_0');
|
565 |
bwg_enable_disable('none', 'tr_popup_captcha', 'popup_enable_ctrl_btn_0');
|
566 |
bwg_enable_disable('none', 'tr_popup_download', 'popup_enable_ctrl_btn_0');
|
@@ -578,6 +603,16 @@ class BWGViewOptions_bwg {
|
|
578 |
<div class="spider_description"></div>
|
579 |
</td>
|
580 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
581 |
<tr id="tr_popup_comment">
|
582 |
<td class="spider_label_options spider_free_version_label">
|
583 |
<label>Enable comments:</label>
|
@@ -660,6 +695,26 @@ class BWGViewOptions_bwg {
|
|
660 |
<div class="spider_description spider_free_version">This option is disabled in free version.</div>
|
661 |
</td>
|
662 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
663 |
</tbody>
|
664 |
</table>
|
665 |
</div>
|
@@ -1106,7 +1161,9 @@ class BWGViewOptions_bwg {
|
|
1106 |
window.onload = bwg_watermark('watermark_type_<?php echo $row->watermark_type ?>');
|
1107 |
window.onload = bwg_built_in_watermark('watermark_type_<?php echo $row->built_in_watermark_type ?>');
|
1108 |
window.onload = bwg_popup_fullscreen(<?php echo $row->popup_fullscreen; ?>);
|
|
|
1109 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_fullscreen', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_fullscreen', 'popup_enable_ctrl_btn_0'" ?>);
|
|
|
1110 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_download', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_download', 'popup_enable_ctrl_btn_0'" ?>);
|
1111 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_fullsize_image', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_fullsize_image', 'popup_enable_ctrl_btn_0'" ?>);
|
1112 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_comment', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_comment', 'popup_enable_ctrl_btn_0'" ?>);
|
@@ -1115,6 +1172,8 @@ class BWGViewOptions_bwg {
|
|
1115 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_facebook', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_facebook', 'popup_enable_ctrl_btn_0'" ?>);
|
1116 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_twitter', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_twitter', 'popup_enable_ctrl_btn_0'" ?>);
|
1117 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_google', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_google', 'popup_enable_ctrl_btn_0'" ?>);
|
|
|
|
|
1118 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_filmstrip ? "'', 'tr_popup_filmstrip_height', 'popup_enable_filmstrip_1'" : "'none', 'tr_popup_filmstrip_height', 'popup_enable_filmstrip_0'" ?>);
|
1119 |
window.onload = bwg_enable_disable(<?php echo $row->slideshow_enable_filmstrip ? "'', 'tr_slideshow_filmstrip_height', 'slideshow_enable_filmstrip_yes'" : "'none', 'tr_slideshow_filmstrip_height', 'slideshow_enable_filmstrip_no'" ?>);
|
1120 |
window.onload = bwg_enable_disable(<?php echo $row->slideshow_enable_title ? "'', 'tr_slideshow_title_position', 'slideshow_enable_title_yes'" : "'none', 'tr_slideshow_title_position', 'slideshow_enable_title_no'" ?>);
|
165 |
<div class="spider_description">Only author can change an image.</div>
|
166 |
</td>
|
167 |
</tr>
|
168 |
+
<tr>
|
169 |
+
<td class="spider_label_options">
|
170 |
+
<label>Show search box:</label>
|
171 |
+
</td>
|
172 |
+
<td>
|
173 |
+
<input type="radio" name="show_search_box" id="show_search_box_1" value="1" <?php if ($row->show_search_box) echo 'checked="checked"'; ?> onchange="bwg_show_search_box(1)" /><label for="show_search_box_1">Yes</label>
|
174 |
+
<input type="radio" name="show_search_box" id="show_search_box_0" value="0" <?php if (!$row->show_search_box) echo 'checked="checked"'; ?> onchange="bwg_show_search_box(0)" /><label for="show_search_box_0">No</label>
|
175 |
+
<div class="spider_description"></div>
|
176 |
+
</td>
|
177 |
+
</tr>
|
178 |
+
<tr id="tr_search_box_width">
|
179 |
+
<td class="spider_label_options">
|
180 |
+
<label for="search_box_width">Search box width: </label>
|
181 |
+
</td>
|
182 |
+
<td>
|
183 |
+
<input type="text" name="search_box_width" id="search_box_width" value="<?php echo $row->search_box_width; ?>" class="spider_int_input" /> px
|
184 |
+
<div class="spider_description"></div>
|
185 |
+
</td>
|
186 |
+
</tr>
|
187 |
</tbody>
|
188 |
</table>
|
189 |
</div>
|
567 |
</td>
|
568 |
<td>
|
569 |
<input type="radio" name="popup_enable_ctrl_btn" id="popup_enable_ctrl_btn_1" value="1" <?php if ($row->popup_enable_ctrl_btn) echo 'checked="checked"'; ?> onClick="bwg_enable_disable('', 'tr_popup_fullscreen', 'popup_enable_ctrl_btn_1');
|
570 |
+
bwg_enable_disable('', 'tr_popup_info', 'popup_enable_ctrl_btn_1');
|
571 |
bwg_enable_disable('', 'tr_popup_comment', 'popup_enable_ctrl_btn_1');
|
572 |
bwg_enable_disable('', 'tr_popup_facebook', 'popup_enable_ctrl_btn_1');
|
573 |
bwg_enable_disable('', 'tr_popup_twitter', 'popup_enable_ctrl_btn_1');
|
574 |
bwg_enable_disable('', 'tr_popup_google', 'popup_enable_ctrl_btn_1');
|
575 |
+
bwg_enable_disable('', 'tr_popup_pinterest', 'popup_enable_ctrl_btn_1');
|
576 |
+
bwg_enable_disable('', 'tr_popup_tumblr', 'popup_enable_ctrl_btn_1');
|
577 |
bwg_enable_disable('', 'tr_popup_email', 'popup_enable_ctrl_btn_1');
|
578 |
bwg_enable_disable('', 'tr_popup_captcha', 'popup_enable_ctrl_btn_1');
|
579 |
bwg_enable_disable('', 'tr_popup_download', 'popup_enable_ctrl_btn_1');
|
580 |
bwg_enable_disable('', 'tr_popup_fullsize_image', 'popup_enable_ctrl_btn_1');" /><label for="popup_enable_ctrl_btn_1">Yes</label>
|
581 |
<input type="radio" name="popup_enable_ctrl_btn" id="popup_enable_ctrl_btn_0" value="0" <?php if (!$row->popup_enable_ctrl_btn) echo 'checked="checked"'; ?> onClick="bwg_enable_disable('none', 'tr_popup_fullscreen', 'popup_enable_ctrl_btn_0');
|
582 |
+
bwg_enable_disable('none', 'tr_popup_info', 'popup_enable_ctrl_btn_0');
|
583 |
bwg_enable_disable('none', 'tr_popup_comment', 'popup_enable_ctrl_btn_0');
|
584 |
bwg_enable_disable('none', 'tr_popup_facebook', 'popup_enable_ctrl_btn_0');
|
585 |
bwg_enable_disable('none', 'tr_popup_twitter', 'popup_enable_ctrl_btn_0');
|
586 |
bwg_enable_disable('none', 'tr_popup_google', 'popup_enable_ctrl_btn_0');
|
587 |
+
bwg_enable_disable('none', 'tr_popup_pinterest', 'popup_enable_ctrl_btn_0');
|
588 |
+
bwg_enable_disable('none', 'tr_popup_tumblr', 'popup_enable_ctrl_btn_0');
|
589 |
bwg_enable_disable('none', 'tr_popup_email', 'popup_enable_ctrl_btn_0');
|
590 |
bwg_enable_disable('none', 'tr_popup_captcha', 'popup_enable_ctrl_btn_0');
|
591 |
bwg_enable_disable('none', 'tr_popup_download', 'popup_enable_ctrl_btn_0');
|
603 |
<div class="spider_description"></div>
|
604 |
</td>
|
605 |
</tr>
|
606 |
+
<tr id="tr_popup_info">
|
607 |
+
<td class="spider_label_options">
|
608 |
+
<label>Enable info:</label>
|
609 |
+
</td>
|
610 |
+
<td>
|
611 |
+
<input type="radio" name="popup_enable_info" id="popup_enable_info_1" value="1" <?php if ($row->popup_enable_info) echo 'checked="checked"'; ?> /><label for="popup_enable_info_1">Yes</label>
|
612 |
+
<input type="radio" name="popup_enable_info" id="popup_enable_info_0" value="0" <?php if (!$row->popup_enable_info) echo 'checked="checked"'; ?> /><label for="popup_enable_info_0">No</label>
|
613 |
+
<div class="spider_description"></div>
|
614 |
+
</td>
|
615 |
+
</tr>
|
616 |
<tr id="tr_popup_comment">
|
617 |
<td class="spider_label_options spider_free_version_label">
|
618 |
<label>Enable comments:</label>
|
695 |
<div class="spider_description spider_free_version">This option is disabled in free version.</div>
|
696 |
</td>
|
697 |
</tr>
|
698 |
+
<tr id="tr_popup_pinterest">
|
699 |
+
<td class="spider_label_options spider_free_version_label">
|
700 |
+
<label>Enable Pinterest button:</label>
|
701 |
+
</td>
|
702 |
+
<td>
|
703 |
+
<input disabled="disabled" type="radio" name="popup_enable_pinterest" id="popup_enable_pinterest_1" value="1" <?php if ($row->popup_enable_pinterest) echo 'checked="checked"'; ?> /><label for="popup_enable_pinterest_1">Yes</label>
|
704 |
+
<input disabled="disabled" type="radio" name="popup_enable_pinterest" id="popup_enable_pinterest_0" value="0" <?php if (!$row->popup_enable_pinterest) echo 'checked="checked"'; ?> /><label for="popup_enable_pinterest_0">No</label>
|
705 |
+
<div class="spider_description spider_free_version">This option is disabled in free version.</div>
|
706 |
+
</td>
|
707 |
+
</tr>
|
708 |
+
<tr id="tr_popup_tumblr">
|
709 |
+
<td class="spider_label_options spider_free_version_label">
|
710 |
+
<label>Enable Tumblr button:</label>
|
711 |
+
</td>
|
712 |
+
<td>
|
713 |
+
<input disabled="disabled" type="radio" name="popup_enable_tumblr" id="popup_enable_tumblr_1" value="1" <?php if ($row->popup_enable_tumblr) echo 'checked="checked"'; ?> /><label for="popup_enable_tumblr_1">Yes</label>
|
714 |
+
<input disabled="disabled" type="radio" name="popup_enable_tumblr" id="popup_enable_tumblr_0" value="0" <?php if (!$row->popup_enable_tumblr) echo 'checked="checked"'; ?> /><label for="popup_enable_tumblr_0">No</label>
|
715 |
+
<div class="spider_description spider_free_version">This option is disabled in free version.</div>
|
716 |
+
</td>
|
717 |
+
</tr>
|
718 |
</tbody>
|
719 |
</table>
|
720 |
</div>
|
1161 |
window.onload = bwg_watermark('watermark_type_<?php echo $row->watermark_type ?>');
|
1162 |
window.onload = bwg_built_in_watermark('watermark_type_<?php echo $row->built_in_watermark_type ?>');
|
1163 |
window.onload = bwg_popup_fullscreen(<?php echo $row->popup_fullscreen; ?>);
|
1164 |
+
window.onload = bwg_show_search_box(<?php echo $row->show_search_box; ?>);
|
1165 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_fullscreen', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_fullscreen', 'popup_enable_ctrl_btn_0'" ?>);
|
1166 |
+
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_info', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_info', 'popup_enable_ctrl_btn_0'" ?>);
|
1167 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_download', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_download', 'popup_enable_ctrl_btn_0'" ?>);
|
1168 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_fullsize_image', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_fullsize_image', 'popup_enable_ctrl_btn_0'" ?>);
|
1169 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_comment', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_comment', 'popup_enable_ctrl_btn_0'" ?>);
|
1172 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_facebook', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_facebook', 'popup_enable_ctrl_btn_0'" ?>);
|
1173 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_twitter', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_twitter', 'popup_enable_ctrl_btn_0'" ?>);
|
1174 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_google', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_google', 'popup_enable_ctrl_btn_0'" ?>);
|
1175 |
+
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_pinterest', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_pinterest', 'popup_enable_ctrl_btn_0'" ?>);
|
1176 |
+
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_ctrl_btn ? "'', 'tr_popup_thumblr', 'popup_enable_ctrl_btn_1'" : "'none', 'tr_popup_thumblr', 'popup_enable_ctrl_btn_0'" ?>);
|
1177 |
window.onload = bwg_enable_disable(<?php echo $row->popup_enable_filmstrip ? "'', 'tr_popup_filmstrip_height', 'popup_enable_filmstrip_1'" : "'none', 'tr_popup_filmstrip_height', 'popup_enable_filmstrip_0'" ?>);
|
1178 |
window.onload = bwg_enable_disable(<?php echo $row->slideshow_enable_filmstrip ? "'', 'tr_slideshow_filmstrip_height', 'slideshow_enable_filmstrip_yes'" : "'none', 'tr_slideshow_filmstrip_height', 'slideshow_enable_filmstrip_no'" ?>);
|
1179 |
window.onload = bwg_enable_disable(<?php echo $row->slideshow_enable_title ? "'', 'tr_slideshow_title_position', 'slideshow_enable_title_yes'" : "'none', 'tr_slideshow_title_position', 'slideshow_enable_title_no'" ?>);
|
css/bwg_shortcode.css
CHANGED
@@ -51,7 +51,7 @@
|
|
51 |
|
52 |
.bwg_short_div {
|
53 |
float: left;
|
54 |
-
height:
|
55 |
padding: 15px;
|
56 |
width: 30%;
|
57 |
}
|
51 |
|
52 |
.bwg_short_div {
|
53 |
float: left;
|
54 |
+
height: 475px;
|
55 |
padding: 15px;
|
56 |
width: 30%;
|
57 |
}
|
css/bwg_tables.css
CHANGED
@@ -467,7 +467,6 @@
|
|
467 |
border-radius: 2px;
|
468 |
border: 1px solid #FFFFFF;
|
469 |
height: 30px;
|
470 |
-
|
471 |
}
|
472 |
|
473 |
.spider_search_value {
|
@@ -480,7 +479,8 @@
|
|
480 |
display: none;
|
481 |
}
|
482 |
|
483 |
-
.bwg_add_video
|
|
|
484 |
display: none;
|
485 |
padding: 10px;
|
486 |
height: 60px;
|
@@ -492,14 +492,25 @@
|
|
492 |
text-align: left;
|
493 |
z-index: 100000;
|
494 |
border-radius: 3px;
|
495 |
-
margin-left: -340px;
|
496 |
margin-top: -45px;
|
497 |
}
|
498 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
499 |
#add_video input[type="text"] {
|
500 |
width: 500px;
|
501 |
}
|
502 |
|
|
|
|
|
|
|
|
|
503 |
.bwg_opacity_video {
|
504 |
display: none;
|
505 |
background-color: #000000;
|
467 |
border-radius: 2px;
|
468 |
border: 1px solid #FFFFFF;
|
469 |
height: 30px;
|
|
|
470 |
}
|
471 |
|
472 |
.spider_search_value {
|
479 |
display: none;
|
480 |
}
|
481 |
|
482 |
+
.bwg_add_video,
|
483 |
+
.bwg_resize_image {
|
484 |
display: none;
|
485 |
padding: 10px;
|
486 |
height: 60px;
|
492 |
text-align: left;
|
493 |
z-index: 100000;
|
494 |
border-radius: 3px;
|
|
|
495 |
margin-top: -45px;
|
496 |
}
|
497 |
|
498 |
+
.bwg_add_video {
|
499 |
+
margin-left: -340px;
|
500 |
+
}
|
501 |
+
|
502 |
+
.bwg_resize_image {
|
503 |
+
margin-left: -200px;
|
504 |
+
}
|
505 |
+
|
506 |
#add_video input[type="text"] {
|
507 |
width: 500px;
|
508 |
}
|
509 |
|
510 |
+
.bwg_resize_image input[type="text"] {
|
511 |
+
width: 60px;
|
512 |
+
}
|
513 |
+
|
514 |
.bwg_opacity_video {
|
515 |
display: none;
|
516 |
background-color: #000000;
|
filemanager/UploadHandler.php
CHANGED
@@ -9,7 +9,14 @@
|
|
9 |
* Licensed under the MIT license:
|
10 |
* http://www.opensource.org/licenses/MIT
|
11 |
*/
|
12 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
$upload_handler = new UploadHandler(array(
|
14 |
'upload_dir' => $_GET['dir'],
|
15 |
'accept_file_types' => '/\.(gif|jpe?g|png|bmp|mp4|flv|webm|ogg|mp3|wav|pdf|zip)$/i'
|
9 |
* Licensed under the MIT license:
|
10 |
* http://www.opensource.org/licenses/MIT
|
11 |
*/
|
12 |
+
if (function_exists('current_user_can')) {
|
13 |
+
if (!current_user_can('manage_options')) {
|
14 |
+
die('Access Denied');
|
15 |
+
}
|
16 |
+
}
|
17 |
+
else {
|
18 |
+
die('Access Denied');
|
19 |
+
}
|
20 |
$upload_handler = new UploadHandler(array(
|
21 |
'upload_dir' => $_GET['dir'],
|
22 |
'accept_file_types' => '/\.(gif|jpe?g|png|bmp|mp4|flv|webm|ogg|mp3|wav|pdf|zip)$/i'
|
framework/WDWLibrary.php
CHANGED
@@ -471,7 +471,7 @@ class WDWLibrary {
|
|
471 |
default:
|
472 |
document.getElementById('page_number_<?php echo $current_view; ?>').value = 1;
|
473 |
}
|
474 |
-
spider_frontend_ajax('<?php echo $form_id; ?>', '<?php echo $current_view; ?>', '<?php echo $id; ?>', '<?php echo $album_gallery_id; ?>', '', '<?php echo $type; ?>');
|
475 |
}
|
476 |
</script>
|
477 |
<div class="tablenav-pages_<?php echo $current_view; ?>">
|
@@ -530,6 +530,94 @@ class WDWLibrary {
|
|
530 |
<?php
|
531 |
}
|
532 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
533 |
public static function spider_hex2rgb($colour) {
|
534 |
if ($colour[0] == '#') {
|
535 |
$colour = substr( $colour, 1 );
|
471 |
default:
|
472 |
document.getElementById('page_number_<?php echo $current_view; ?>').value = 1;
|
473 |
}
|
474 |
+
spider_frontend_ajax('<?php echo $form_id; ?>', '<?php echo $current_view; ?>', '<?php echo $id; ?>', '<?php echo $album_gallery_id; ?>', '', '<?php echo $type; ?>', 0);
|
475 |
}
|
476 |
</script>
|
477 |
<div class="tablenav-pages_<?php echo $current_view; ?>">
|
530 |
<?php
|
531 |
}
|
532 |
|
533 |
+
public static function ajax_html_frontend_search_box($form_id, $current_view, $cur_gal_id, $images_count, $search_box_width) {
|
534 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $current_view]) && esc_html($_POST['bwg_search_' . $current_view]) != '') ? esc_html($_POST['bwg_search_' . $current_view]) : '');
|
535 |
+
$type = (isset($_POST['type_' . $current_view]) ? esc_html($_POST['type_' . $current_view]) : 'album');
|
536 |
+
$album_gallery_id = (isset($_POST['album_gallery_id_' . $current_view]) ? esc_html($_POST['album_gallery_id_' . $current_view]) : 0);
|
537 |
+
?>
|
538 |
+
<style>
|
539 |
+
.bwg_search_container_1 {
|
540 |
+
display: inline-block;
|
541 |
+
width: 100%;
|
542 |
+
text-align: right;
|
543 |
+
margin: 0 5px 20px 5px;
|
544 |
+
background-color: rgba(0,0,0,0);
|
545 |
+
}
|
546 |
+
.bwg_search_container_2 {
|
547 |
+
display: inline-block;
|
548 |
+
position: relative;
|
549 |
+
border-radius: 4px;
|
550 |
+
box-shadow: 0 0 3px 1px #CCCCCC;
|
551 |
+
background-color: #FFFFFF;
|
552 |
+
border: 1px solid #CCCCCC;
|
553 |
+
width: <?php echo $search_box_width; ?>px;
|
554 |
+
max-width: 100%;
|
555 |
+
}
|
556 |
+
#bwg_search_container_1_<?php echo $current_view; ?> #bwg_search_container_2_<?php echo $current_view; ?> .bwg_search_input_container {
|
557 |
+
display: block;
|
558 |
+
margin-right: 45px;
|
559 |
+
}
|
560 |
+
#bwg_search_container_1_<?php echo $current_view; ?> #bwg_search_container_2_<?php echo $current_view; ?> .bwg_search_loupe_container {
|
561 |
+
display: inline-block;
|
562 |
+
margin-right: 1px;
|
563 |
+
vertical-align: middle;
|
564 |
+
float: right;
|
565 |
+
padding-top: 3px;
|
566 |
+
}
|
567 |
+
#bwg_search_container_1_<?php echo $current_view; ?> #bwg_search_container_2_<?php echo $current_view; ?> .bwg_search_reset_container {
|
568 |
+
display: inline-block;
|
569 |
+
margin-right: 5px;
|
570 |
+
vertical-align: middle;
|
571 |
+
float: right;
|
572 |
+
padding-top: 3px;
|
573 |
+
}
|
574 |
+
#bwg_search_container_1_<?php echo $current_view; ?> #bwg_search_container_2_<?php echo $current_view; ?> .bwg_search,
|
575 |
+
#bwg_search_container_1_<?php echo $current_view; ?> #bwg_search_container_2_<?php echo $current_view; ?> .bwg_reset {
|
576 |
+
font-size: 18px;
|
577 |
+
color: #CCCCCC;
|
578 |
+
cursor: pointer;
|
579 |
+
}
|
580 |
+
#bwg_search_container_1_<?php echo $current_view; ?> #bwg_search_container_2_<?php echo $current_view; ?> .bwg_search_input_<?php echo $current_view; ?>,
|
581 |
+
#bwg_search_container_1_<?php echo $current_view; ?> #bwg_search_container_2_<?php echo $current_view; ?> .bwg_search_input_<?php echo $current_view; ?>:focus {
|
582 |
+
color: hsl(0, 1%, 3%);
|
583 |
+
outline: none;
|
584 |
+
border: none;
|
585 |
+
box-shadow: none;
|
586 |
+
background: none;
|
587 |
+
padding: 0 5px;
|
588 |
+
font-family: inherit;
|
589 |
+
width: 100%;
|
590 |
+
}
|
591 |
+
</style>
|
592 |
+
<script type="text/javascript">
|
593 |
+
function clear_input_<?php echo $current_view; ?> (current_view) {
|
594 |
+
jQuery("#bwg_search_input_" + current_view).val('');
|
595 |
+
}
|
596 |
+
function check_enter_key(e) {
|
597 |
+
var key_code = e.which || e.keyCode;
|
598 |
+
if (key_code == 13) {
|
599 |
+
return false;
|
600 |
+
}
|
601 |
+
return true;
|
602 |
+
}
|
603 |
+
</script>
|
604 |
+
<div class="bwg_search_container_1" id="bwg_search_container_1_<?php echo $current_view; ?>">
|
605 |
+
<div class="bwg_search_container_2" id="bwg_search_container_2_<?php echo $current_view; ?>">
|
606 |
+
<span class="bwg_search_reset_container" >
|
607 |
+
<i title="<?php echo __('Reset', 'bwg'); ?>" class="bwg_reset fa fa-times" onclick="clear_input_<?php echo $current_view; ?>('<?php echo $current_view; ?>'),spider_frontend_ajax('<?php echo $form_id; ?>', '<?php echo $current_view; ?>', '<?php echo $cur_gal_id; ?>', <?php echo $album_gallery_id; ?>, '', '<?php echo $type; ?>', 1)"></i>
|
608 |
+
</span>
|
609 |
+
<span class="bwg_search_loupe_container" >
|
610 |
+
<i title="<?php echo __('Search', 'bwg'); ?>" class="bwg_search fa fa-search" onclick="spider_frontend_ajax('<?php echo $form_id; ?>', '<?php echo $current_view; ?>', '<?php echo $cur_gal_id; ?>', <?php echo $album_gallery_id; ?>, '', '<?php echo $type; ?>', 1)"></i>
|
611 |
+
</span>
|
612 |
+
<span class="bwg_search_input_container">
|
613 |
+
<input id="bwg_search_input_<?php echo $current_view; ?>" class="bwg_search_input_<?php echo $current_view; ?>" type="text" onkeypress="return check_enter_key(event)" name="bwg_search_<?php echo $current_view; ?>" value="<?php echo $bwg_search; ?>" >
|
614 |
+
<input id="bwg_images_count_<?php echo $current_view; ?>" class="bwg_search_input" type="hidden" name="bwg_images_count_<?php echo $current_view; ?>" value="<?php echo $images_count; ?>" >
|
615 |
+
</span>
|
616 |
+
</div>
|
617 |
+
</div>
|
618 |
+
<?php
|
619 |
+
}
|
620 |
+
|
621 |
public static function spider_hex2rgb($colour) {
|
622 |
if ($colour[0] == '#') {
|
623 |
$colour = substr( $colour, 1 );
|
frontend/models/BWGModelAlbum_compact_preview.php
CHANGED
@@ -67,6 +67,13 @@ class BWGModelAlbum_compact_preview {
|
|
67 |
|
68 |
public function get_image_rows_data($id, $images_per_page, $sort_by, $bwg, $sort_direction = ' ASC ') {
|
69 |
global $wpdb;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
70 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
71 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
72 |
}
|
@@ -79,13 +86,20 @@ class BWGModelAlbum_compact_preview {
|
|
79 |
else {
|
80 |
$limit_str = '';
|
81 |
}
|
82 |
-
$row = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 AND gallery_id="%d" ORDER BY `' . $sort_by . '` ' . $sort_direction . $limit_str, $id));
|
83 |
return $row;
|
84 |
}
|
85 |
|
86 |
public function gallery_page_nav($id, $images_per_page, $bwg) {
|
87 |
global $wpdb;
|
88 |
-
$
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
89 |
$page_nav['total'] = $total;
|
90 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
91 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
@@ -126,7 +140,7 @@ class BWGModelAlbum_compact_preview {
|
|
126 |
$bwg_post_id = get_page_by_title($title, OBJECT, $post_type);
|
127 |
$options_row = $this->get_options_row_data();
|
128 |
$theme_row = $this->get_theme_row_data(0);
|
129 |
-
$shortecode_string = '[Best_Wordpress_Gallery type="' . $type . '" gallery_type="album_compact_preview" theme_id="' . $theme_row->id . '" album_id="' . $id . '" sort_by="order" order_by="asc" compuct_album_column_number="' . $options_row->album_column_number . '" compuct_albums_per_page="' . $options_row->albums_per_page . '" compuct_album_title="' . $options_row->album_title_show_hover . '" compuct_album_view_type="' . $options_row->album_view_type . '" compuct_album_thumb_width="' . $options_row->album_thumb_width . '" compuct_album_thumb_height="' . $options_row->album_thumb_height . '" compuct_album_image_column_number="' . $options_row->image_column_number . '" compuct_album_images_per_page="' . $options_row->images_per_page . '" compuct_album_image_title="' . $options_row->image_title_show_hover . '" compuct_album_image_thumb_width="' . $options_row->thumb_width . '" compuct_album_image_thumb_height="' . $options_row->thumb_height . '" compuct_album_enable_page="' . $options_row->album_enable_page . '" popup_fullscreen="' . $options_row->popup_fullscreen . '" popup_autoplay="' . $options_row->popup_autoplay . '" popup_width="' . $options_row->popup_width . '" popup_height="' . $options_row->popup_height . '" popup_effect="' . $options_row->popup_type . '" popup_interval="' . $options_row->popup_interval . '" popup_enable_filmstrip="' . $options_row->popup_enable_filmstrip . '" popup_filmstrip_height="' . $options_row->popup_filmstrip_height . '" popup_enable_ctrl_btn="' . $options_row->popup_enable_ctrl_btn . '" popup_enable_fullscreen="' . $options_row->popup_enable_fullscreen . '" popup_enable_comment="' . $options_row->popup_enable_comment . '" popup_enable_facebook="' . $options_row->popup_enable_facebook . '" popup_enable_twitter="' . $options_row->popup_enable_twitter . '" popup_enable_google="' . $options_row->popup_enable_google . '" watermark_type="' . $options_row->watermark_type . '" watermark_link="' . $options_row->watermark_link . '" watermark_text="' . $options_row->watermark_text . '" watermark_font_size="' . $options_row->watermark_font_size . '" watermark_font="' . $options_row->watermark_font . '" watermark_color="' . $options_row->watermark_color . '" watermark_opacity="' . $options_row->watermark_opacity . '" watermark_position="' . $options_row->watermark_position . '" watermark_url="' . $options_row->watermark_url . '" watermark_width="' . $options_row->watermark_width . '" watermark_height="' . $options_row->watermark_height . '"]';
|
130 |
if (!$bwg_post_id) {
|
131 |
$post = array(
|
132 |
'post_content' => $shortecode_string,
|
67 |
|
68 |
public function get_image_rows_data($id, $images_per_page, $sort_by, $bwg, $sort_direction = ' ASC ') {
|
69 |
global $wpdb;
|
70 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
71 |
+
if ($bwg_search != '') {
|
72 |
+
$where = 'AND alt LIKE "%%' . $bwg_search . '%%"';
|
73 |
+
}
|
74 |
+
else {
|
75 |
+
$where = '';
|
76 |
+
}
|
77 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
78 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
79 |
}
|
86 |
else {
|
87 |
$limit_str = '';
|
88 |
}
|
89 |
+
$row = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 ' . $where . ' AND gallery_id="%d" ORDER BY `' . $sort_by . '` ' . $sort_direction . $limit_str, $id));
|
90 |
return $row;
|
91 |
}
|
92 |
|
93 |
public function gallery_page_nav($id, $images_per_page, $bwg) {
|
94 |
global $wpdb;
|
95 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
96 |
+
if ($bwg_search != '') {
|
97 |
+
$where = 'AND alt LIKE "%%' . $bwg_search . '%%"';
|
98 |
+
}
|
99 |
+
else {
|
100 |
+
$where = '';
|
101 |
+
}
|
102 |
+
$total = $wpdb->get_var($wpdb->prepare('SELECT COUNT(*) FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 ' . $where . ' AND gallery_id="%d"', $id));
|
103 |
$page_nav['total'] = $total;
|
104 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
105 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
140 |
$bwg_post_id = get_page_by_title($title, OBJECT, $post_type);
|
141 |
$options_row = $this->get_options_row_data();
|
142 |
$theme_row = $this->get_theme_row_data(0);
|
143 |
+
$shortecode_string = '[Best_Wordpress_Gallery type="' . $type . '" gallery_type="album_compact_preview" theme_id="' . $theme_row->id . '" album_id="' . $id . '" sort_by="order" order_by="asc" compuct_album_column_number="' . $options_row->album_column_number . '" compuct_albums_per_page="' . $options_row->albums_per_page . '" compuct_album_title="' . $options_row->album_title_show_hover . '" compuct_album_view_type="' . $options_row->album_view_type . '" compuct_album_thumb_width="' . $options_row->album_thumb_width . '" compuct_album_thumb_height="' . $options_row->album_thumb_height . '" compuct_album_image_column_number="' . $options_row->image_column_number . '" compuct_album_images_per_page="' . $options_row->images_per_page . '" compuct_album_image_title="' . $options_row->image_title_show_hover . '" compuct_album_image_thumb_width="' . $options_row->thumb_width . '" compuct_album_image_thumb_height="' . $options_row->thumb_height . '" compuct_album_enable_page="' . $options_row->album_enable_page . '" popup_fullscreen="' . $options_row->popup_fullscreen . '" popup_autoplay="' . $options_row->popup_autoplay . '" popup_width="' . $options_row->popup_width . '" popup_height="' . $options_row->popup_height . '" popup_effect="' . $options_row->popup_type . '" popup_interval="' . $options_row->popup_interval . '" popup_enable_filmstrip="' . $options_row->popup_enable_filmstrip . '" popup_filmstrip_height="' . $options_row->popup_filmstrip_height . '" popup_enable_ctrl_btn="' . $options_row->popup_enable_ctrl_btn . '" popup_enable_fullscreen="' . $options_row->popup_enable_fullscreen . '" popup_enable_comment="' . $options_row->popup_enable_comment . '" popup_enable_facebook="' . $options_row->popup_enable_facebook . '" popup_enable_twitter="' . $options_row->popup_enable_twitter . '" popup_enable_google="' . $options_row->popup_enable_google . '" watermark_type="' . $options_row->watermark_type . '" watermark_link="' . $options_row->watermark_link . '" watermark_text="' . $options_row->watermark_text . '" watermark_font_size="' . $options_row->watermark_font_size . '" watermark_font="' . $options_row->watermark_font . '" watermark_color="' . $options_row->watermark_color . '" watermark_opacity="' . $options_row->watermark_opacity . '" watermark_position="' . $options_row->watermark_position . '" watermark_url="' . $options_row->watermark_url . '" watermark_width="' . $options_row->watermark_width . '" watermark_height="' . $options_row->watermark_height . '" show_search_box="' . $options_row->show_search_box . '" search_box_width="' . $options_row->search_box_width . '" popup_enable_info="' . $options_row->popup_enable_info . '"]';
|
144 |
if (!$bwg_post_id) {
|
145 |
$post = array(
|
146 |
'post_content' => $shortecode_string,
|
frontend/models/BWGModelAlbum_extended_preview.php
CHANGED
@@ -56,6 +56,13 @@ class BWGModelAlbum_extended_preview {
|
|
56 |
|
57 |
public function get_image_rows_data($id, $images_per_page, $sort_by, $bwg) {
|
58 |
global $wpdb;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
59 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
60 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
61 |
}
|
@@ -68,13 +75,20 @@ class BWGModelAlbum_extended_preview {
|
|
68 |
else {
|
69 |
$limit_str = '';
|
70 |
}
|
71 |
-
$row = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 AND gallery_id="%d" ORDER BY `' . $sort_by . '` ASC ' . $limit_str, $id));
|
72 |
return $row;
|
73 |
}
|
74 |
|
75 |
public function gallery_page_nav($id, $images_per_page, $bwg) {
|
76 |
global $wpdb;
|
77 |
-
$
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
78 |
$page_nav['total'] = $total;
|
79 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
80 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
56 |
|
57 |
public function get_image_rows_data($id, $images_per_page, $sort_by, $bwg) {
|
58 |
global $wpdb;
|
59 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
60 |
+
if ($bwg_search != '') {
|
61 |
+
$where = 'AND alt LIKE "%%' . $bwg_search . '%%"';
|
62 |
+
}
|
63 |
+
else {
|
64 |
+
$where = '';
|
65 |
+
}
|
66 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
67 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
68 |
}
|
75 |
else {
|
76 |
$limit_str = '';
|
77 |
}
|
78 |
+
$row = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 ' . $where . ' AND gallery_id="%d" ORDER BY `' . $sort_by . '` ASC ' . $limit_str, $id));
|
79 |
return $row;
|
80 |
}
|
81 |
|
82 |
public function gallery_page_nav($id, $images_per_page, $bwg) {
|
83 |
global $wpdb;
|
84 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
85 |
+
if ($bwg_search != '') {
|
86 |
+
$where = 'AND alt LIKE "%%' . $bwg_search . '%%"';
|
87 |
+
}
|
88 |
+
else {
|
89 |
+
$where = '';
|
90 |
+
}
|
91 |
+
$total = $wpdb->get_var($wpdb->prepare('SELECT COUNT(*) FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 ' . $where . ' AND gallery_id="%d"', $id));
|
92 |
$page_nav['total'] = $total;
|
93 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
94 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
frontend/models/BWGModelImage_browser.php
CHANGED
@@ -32,6 +32,13 @@ class BWGModelImage_browser {
|
|
32 |
|
33 |
public function get_image_rows_data($id, $images_per_page, $sort_by, $order_by = 'asc', $bwg) {
|
34 |
global $wpdb;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
35 |
if ($sort_by == 'size' || $sort_by == 'resolution') {
|
36 |
$sort_by = ' CAST(' . $sort_by . ' AS SIGNED) ';
|
37 |
}
|
@@ -50,7 +57,7 @@ class BWGModelImage_browser {
|
|
50 |
else {
|
51 |
$limit_str = '';
|
52 |
}
|
53 |
-
$row = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 AND gallery_id="%d" ORDER BY ' . $sort_by . ' ' . $order_by . ' ' . $limit_str, $id));
|
54 |
return $row;
|
55 |
}
|
56 |
|
@@ -62,7 +69,14 @@ class BWGModelImage_browser {
|
|
62 |
|
63 |
public function page_nav($id, $images_per_page, $bwg) {
|
64 |
global $wpdb;
|
65 |
-
$
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
$page_nav['total'] = $total;
|
67 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
68 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
32 |
|
33 |
public function get_image_rows_data($id, $images_per_page, $sort_by, $order_by = 'asc', $bwg) {
|
34 |
global $wpdb;
|
35 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
36 |
+
if ($bwg_search != '') {
|
37 |
+
$where = 'AND alt LIKE "%%' . $bwg_search . '%%"';
|
38 |
+
}
|
39 |
+
else {
|
40 |
+
$where = '';
|
41 |
+
}
|
42 |
if ($sort_by == 'size' || $sort_by == 'resolution') {
|
43 |
$sort_by = ' CAST(' . $sort_by . ' AS SIGNED) ';
|
44 |
}
|
57 |
else {
|
58 |
$limit_str = '';
|
59 |
}
|
60 |
+
$row = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 ' . $where . ' AND gallery_id="%d" ORDER BY ' . $sort_by . ' ' . $order_by . ' ' . $limit_str, $id));
|
61 |
return $row;
|
62 |
}
|
63 |
|
69 |
|
70 |
public function page_nav($id, $images_per_page, $bwg) {
|
71 |
global $wpdb;
|
72 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
73 |
+
if ($bwg_search != '') {
|
74 |
+
$where = 'AND alt LIKE "%%' . $bwg_search . '%%"';
|
75 |
+
}
|
76 |
+
else {
|
77 |
+
$where = '';
|
78 |
+
}
|
79 |
+
$total = $wpdb->get_var($wpdb->prepare('SELECT COUNT(*) FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 ' . $where . ' AND gallery_id="%d"', $id));
|
80 |
$page_nav['total'] = $total;
|
81 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
82 |
$limit = ((int) $_POST['page_number_' . $bwg] - 1) * $images_per_page;
|
frontend/models/BWGModelThumbnails.php
CHANGED
@@ -37,6 +37,23 @@ class BWGModelThumbnails {
|
|
37 |
|
38 |
public function get_image_rows_data($id, $images_per_page, $sort_by, $bwg, $type, $sort_direction = ' ASC ') {
|
39 |
global $wpdb;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
if ($sort_by == 'size' || $sort_by == 'resolution') {
|
41 |
$sort_by = ' CAST(' . $sort_by . ' AS SIGNED) ';
|
42 |
}
|
@@ -56,21 +73,38 @@ class BWGModelThumbnails {
|
|
56 |
$limit_str = '';
|
57 |
}
|
58 |
if($type == 'tag') {
|
59 |
-
$row = $wpdb->get_results($wpdb->prepare('SELECT image.* FROM ' . $wpdb->prefix . 'bwg_image as image INNER JOIN ' . $wpdb->prefix . 'bwg_image_tag as tag ON image.id=tag.image_id WHERE image.published=1 AND tag.tag_id="%d" ORDER BY ' . $sort_by . $sort_direction, $id));
|
60 |
}
|
61 |
else {
|
62 |
-
$row = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 AND gallery_id="%d" ORDER BY ' . $sort_by . ' ' . $sort_direction . ' ' . $limit_str, $id));
|
63 |
}
|
64 |
return $row;
|
65 |
}
|
66 |
|
67 |
public function page_nav($id, $images_per_page, $bwg, $type) {
|
68 |
global $wpdb;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
69 |
if ($type == 'tag') {
|
70 |
-
$total = $wpdb->get_var($wpdb->prepare('SELECT COUNT(*) FROM ' . $wpdb->prefix . 'bwg_image as image INNER JOIN ' . $wpdb->prefix . 'bwg_image_tag as tag ON image.id=tag.image_id WHERE image.published=1 AND tag.tag_id="%d"', $id));
|
71 |
}
|
72 |
else {
|
73 |
-
$total = $wpdb->get_var($wpdb->prepare('SELECT COUNT(*) FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 AND gallery_id="%d"', $id));
|
74 |
}
|
75 |
$page_nav['total'] = $total;
|
76 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
37 |
|
38 |
public function get_image_rows_data($id, $images_per_page, $sort_by, $bwg, $type, $sort_direction = ' ASC ') {
|
39 |
global $wpdb;
|
40 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
41 |
+
if ($type == 'tag') {
|
42 |
+
if ($bwg_search != '') {
|
43 |
+
$where = 'AND image.alt LIKE "%%' . $bwg_search . '%%"';
|
44 |
+
}
|
45 |
+
else {
|
46 |
+
$where = '';
|
47 |
+
}
|
48 |
+
}
|
49 |
+
else {
|
50 |
+
if ($bwg_search != '') {
|
51 |
+
$where = 'AND alt LIKE "%%' . $bwg_search . '%%"';
|
52 |
+
}
|
53 |
+
else {
|
54 |
+
$where = '';
|
55 |
+
}
|
56 |
+
}
|
57 |
if ($sort_by == 'size' || $sort_by == 'resolution') {
|
58 |
$sort_by = ' CAST(' . $sort_by . ' AS SIGNED) ';
|
59 |
}
|
73 |
$limit_str = '';
|
74 |
}
|
75 |
if($type == 'tag') {
|
76 |
+
$row = $wpdb->get_results($wpdb->prepare('SELECT image.* FROM ' . $wpdb->prefix . 'bwg_image as image INNER JOIN ' . $wpdb->prefix . 'bwg_image_tag as tag ON image.id=tag.image_id WHERE image.published=1 ' . $where . ' AND tag.tag_id="%d" ORDER BY ' . $sort_by . $sort_direction, $id));
|
77 |
}
|
78 |
else {
|
79 |
+
$row = $wpdb->get_results($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 ' . $where . ' AND gallery_id="%d" ORDER BY ' . $sort_by . ' ' . $sort_direction . ' ' . $limit_str, $id));
|
80 |
}
|
81 |
return $row;
|
82 |
}
|
83 |
|
84 |
public function page_nav($id, $images_per_page, $bwg, $type) {
|
85 |
global $wpdb;
|
86 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
87 |
+
if ($type == 'tag') {
|
88 |
+
if ($bwg_search != '') {
|
89 |
+
$where = 'AND image.alt LIKE "%%' . $bwg_search . '%%"';
|
90 |
+
}
|
91 |
+
else {
|
92 |
+
$where = '';
|
93 |
+
}
|
94 |
+
}
|
95 |
+
else {
|
96 |
+
if ($bwg_search != '') {
|
97 |
+
$where = 'AND alt LIKE "%%' . $bwg_search . '%%"';
|
98 |
+
}
|
99 |
+
else {
|
100 |
+
$where = '';
|
101 |
+
}
|
102 |
+
}
|
103 |
if ($type == 'tag') {
|
104 |
+
$total = $wpdb->get_var($wpdb->prepare('SELECT COUNT(*) FROM ' . $wpdb->prefix . 'bwg_image as image INNER JOIN ' . $wpdb->prefix . 'bwg_image_tag as tag ON image.id=tag.image_id WHERE image.published=1 ' . $where . ' AND tag.tag_id="%d"', $id));
|
105 |
}
|
106 |
else {
|
107 |
+
$total = $wpdb->get_var($wpdb->prepare('SELECT COUNT(*) FROM ' . $wpdb->prefix . 'bwg_image WHERE published=1 ' . $where . ' AND gallery_id="%d"', $id));
|
108 |
}
|
109 |
$page_nav['total'] = $total;
|
110 |
if (isset($_POST['page_number_' . $bwg]) && $_POST['page_number_' . $bwg]) {
|
frontend/models/BWGModelWidget.php
CHANGED
@@ -48,7 +48,7 @@ class BWGModelWidgetFrontEnd {
|
|
48 |
$bwg_post_id = get_page_by_title($title, OBJECT, 'bwg_tag');
|
49 |
$options_row = $this->get_options_row_data();
|
50 |
$theme_row = $this->get_theme_row_data(0);
|
51 |
-
$shortecode_string = '[Best_Wordpress_Gallery type="' . $type . '" gallery_type="thumbnails" theme_id="' . $theme_row->id . '" gallery_id="' . $id . '" sort_by="date" order_by="asc" image_column_number="' . $options_row->image_column_number . '" images_per_page="' . $options_row->images_per_page . '" image_title="' . $options_row->image_title_show_hover . '" image_enable_page="' . $options_row->image_enable_page . '" thumb_width="' . $options_row->thumb_width . '" thumb_height="' . $options_row->thumb_height . '" popup_fullscreen="' . $options_row->popup_fullscreen . '" popup_autoplay="' . $options_row->popup_autoplay . '" popup_width="' . $options_row->popup_width . '" popup_height="' . $options_row->popup_height . '" popup_effect="' . $options_row->popup_type . '" popup_interval="' . $options_row->popup_interval . '" popup_enable_filmstrip="' . $options_row->popup_enable_filmstrip . '" popup_filmstrip_height="' . $options_row->popup_filmstrip_height . '" popup_enable_ctrl_btn="' . $options_row->popup_enable_ctrl_btn . '" popup_enable_fullscreen="' . $options_row->popup_enable_fullscreen . '" popup_enable_comment="' . $options_row->popup_enable_comment . '" popup_enable_facebook="' . $options_row->popup_enable_facebook . '" popup_enable_twitter="' . $options_row->popup_enable_twitter . '" popup_enable_google="' . $options_row->popup_enable_google . '" watermark_type="' . $options_row->watermark_type . '" watermark_link="' . $options_row->watermark_link . '" watermark_text="' . $options_row->watermark_text . '" watermark_font_size="' . $options_row->watermark_font_size . '" watermark_font="' . $options_row->watermark_font . '" watermark_color="' . $options_row->watermark_color . '" watermark_opacity="' . $options_row->watermark_opacity . '" watermark_position="' . $options_row->watermark_position . '" watermark_url="' . $options_row->watermark_url . '" watermark_width="' . $options_row->watermark_width . '" watermark_height="' . $options_row->watermark_height . '"]';
|
52 |
if (!$bwg_post_id) {
|
53 |
$post = array(
|
54 |
'post_content' => $shortecode_string,
|
48 |
$bwg_post_id = get_page_by_title($title, OBJECT, 'bwg_tag');
|
49 |
$options_row = $this->get_options_row_data();
|
50 |
$theme_row = $this->get_theme_row_data(0);
|
51 |
+
$shortecode_string = '[Best_Wordpress_Gallery type="' . $type . '" gallery_type="thumbnails" theme_id="' . $theme_row->id . '" gallery_id="' . $id . '" sort_by="date" order_by="asc" image_column_number="' . $options_row->image_column_number . '" images_per_page="' . $options_row->images_per_page . '" image_title="' . $options_row->image_title_show_hover . '" image_enable_page="' . $options_row->image_enable_page . '" thumb_width="' . $options_row->thumb_width . '" thumb_height="' . $options_row->thumb_height . '" popup_fullscreen="' . $options_row->popup_fullscreen . '" popup_autoplay="' . $options_row->popup_autoplay . '" popup_width="' . $options_row->popup_width . '" popup_height="' . $options_row->popup_height . '" popup_effect="' . $options_row->popup_type . '" popup_interval="' . $options_row->popup_interval . '" popup_enable_filmstrip="' . $options_row->popup_enable_filmstrip . '" popup_filmstrip_height="' . $options_row->popup_filmstrip_height . '" popup_enable_ctrl_btn="' . $options_row->popup_enable_ctrl_btn . '" popup_enable_fullscreen="' . $options_row->popup_enable_fullscreen . '" popup_enable_comment="' . $options_row->popup_enable_comment . '" popup_enable_facebook="' . $options_row->popup_enable_facebook . '" popup_enable_twitter="' . $options_row->popup_enable_twitter . '" popup_enable_google="' . $options_row->popup_enable_google . '" watermark_type="' . $options_row->watermark_type . '" watermark_link="' . $options_row->watermark_link . '" watermark_text="' . $options_row->watermark_text . '" watermark_font_size="' . $options_row->watermark_font_size . '" watermark_font="' . $options_row->watermark_font . '" watermark_color="' . $options_row->watermark_color . '" watermark_opacity="' . $options_row->watermark_opacity . '" watermark_position="' . $options_row->watermark_position . '" watermark_url="' . $options_row->watermark_url . '" watermark_width="' . $options_row->watermark_width . '" watermark_height="' . $options_row->watermark_height . '" show_search_box="' . $options_row->show_search_box . '" popup_enable_info="' . $options_row->popup_enable_info . '" search_box_width="' . $options_row->search_box_width . '"]';
|
52 |
if (!$bwg_post_id) {
|
53 |
$post = array(
|
54 |
'post_content' => $shortecode_string,
|
frontend/views/BWGViewAlbum_compact_preview.php
CHANGED
@@ -31,14 +31,30 @@ class BWGViewAlbum_compact_preview {
|
|
31 |
if (!isset($params['compuct_album_image_title'])) {
|
32 |
$params['compuct_album_image_title'] = 'none';
|
33 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
34 |
if (!isset($params['popup_fullscreen'])) {
|
35 |
$params['popup_fullscreen'] = 0;
|
36 |
}
|
37 |
if (!isset($params['popup_autoplay'])) {
|
38 |
$params['popup_autoplay'] = 0;
|
39 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
$from = (isset($params['from']) ? esc_html($params['from']) : 0);
|
41 |
$type = (isset($_POST['type_' . $bwg]) ? esc_html($_POST['type_' . $bwg]) : (isset($params['type']) ? $params['type'] : 'album'));
|
|
|
42 |
$sort_direction = ' ASC ';
|
43 |
if ($from === "widget") {
|
44 |
$options_row = $this->model->get_options_row_data();
|
@@ -70,6 +86,7 @@ class BWGViewAlbum_compact_preview {
|
|
70 |
$items_per_page = $params['compuct_album_images_per_page'];
|
71 |
$items_col_num = $params['compuct_album_image_column_number'];
|
72 |
$image_rows = $this->model->get_image_rows_data($album_gallery_id, $items_per_page, $params['sort_by'], $bwg, $sort_direction);
|
|
|
73 |
if (!$image_rows) {
|
74 |
echo WDWLibrary::message(__('There are no images in this gallery.', 'bwg'), 'error');
|
75 |
}
|
@@ -89,6 +106,24 @@ class BWGViewAlbum_compact_preview {
|
|
89 |
$album_gallery_div_id = 'bwg_album_compact_' . $bwg;
|
90 |
$album_gallery_div_class = 'bwg_album_thumbnails_' . $bwg;
|
91 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
92 |
$bwg_previous_album_id = (isset($_POST['bwg_previous_album_id_' . $bwg]) ? esc_html($_POST['bwg_previous_album_id_' . $bwg]) : 0);
|
93 |
$bwg_previous_album_page_number = (isset($_POST['bwg_previous_album_page_number_' . $bwg]) ? esc_html($_POST['bwg_previous_album_page_number_' . $bwg]) : 0);
|
94 |
|
@@ -394,7 +429,21 @@ class BWGViewAlbum_compact_preview {
|
|
394 |
<div id="bwg_container1_<?php echo $bwg; ?>">
|
395 |
<div id="bwg_container2_<?php echo $bwg; ?>">
|
396 |
<form id="gal_front_form_<?php echo $bwg; ?>" method="post" action="#">
|
397 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
398 |
<?php
|
399 |
if ($params['compuct_album_enable_page'] && $items_per_page && ($theme_row->page_nav_position == 'top') && $page_nav['total']) {
|
400 |
WDWLibrary::ajax_html_frontend_page_nav($theme_row, $page_nav['total'], $page_nav['limit'], 'gal_front_form_' . $bwg, $items_per_page, $bwg, $album_gallery_div_id, $params['album_id']);
|
@@ -405,13 +454,7 @@ class BWGViewAlbum_compact_preview {
|
|
405 |
<?php
|
406 |
}
|
407 |
?>
|
408 |
-
<div id="
|
409 |
-
<div id="ajax_loading_<?php echo $bwg; ?>" style="position:absolute;">
|
410 |
-
<div id="opacity_div_<?php echo $bwg; ?>" style="display:none; background-color:#FFFFFF; opacity:0.7; filter:Alpha(opacity=70); position:absolute; z-index:105;"></div>
|
411 |
-
<span id="loading_div_<?php echo $bwg; ?>" style="display:none; text-align:center; position:relative; vertical-align:middle; z-index:107">
|
412 |
-
<img src="<?php echo WD_BWG_URL . '/images/ajax_loader.png'; ?>" class="spider_ajax_loading" style="float: none; width:50px;">
|
413 |
-
</span>
|
414 |
-
</div>
|
415 |
<input type="hidden" id="bwg_previous_album_id_<?php echo $bwg; ?>" name="bwg_previous_album_id_<?php echo $bwg; ?>" value="<?php echo $bwg_previous_album_id; ?>" />
|
416 |
<input type="hidden" id="bwg_previous_album_page_number_<?php echo $bwg; ?>" name="bwg_previous_album_page_number_<?php echo $bwg; ?>" value="<?php echo $bwg_previous_album_page_number; ?>" />
|
417 |
<?php
|
@@ -512,9 +555,16 @@ class BWGViewAlbum_compact_preview {
|
|
512 |
}
|
513 |
elseif ($type == 'gallery') {
|
514 |
if (!$page_nav['total']) {
|
515 |
-
|
516 |
-
|
517 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
518 |
}
|
519 |
foreach ($image_rows as $image_row) {
|
520 |
$params_array = array(
|
31 |
if (!isset($params['compuct_album_image_title'])) {
|
32 |
$params['compuct_album_image_title'] = 'none';
|
33 |
}
|
34 |
+
if (!isset($params['compuct_album_view_type'])) {
|
35 |
+
$album_view_type = 'thumbnail';
|
36 |
+
}
|
37 |
+
else {
|
38 |
+
$album_view_type = $params['compuct_album_view_type'];
|
39 |
+
}
|
40 |
if (!isset($params['popup_fullscreen'])) {
|
41 |
$params['popup_fullscreen'] = 0;
|
42 |
}
|
43 |
if (!isset($params['popup_autoplay'])) {
|
44 |
$params['popup_autoplay'] = 0;
|
45 |
}
|
46 |
+
if (!isset($params['show_search_box'])) {
|
47 |
+
$params['show_search_box'] = 0;
|
48 |
+
}
|
49 |
+
if (!isset($params['search_box_width'])) {
|
50 |
+
$params['search_box_width'] = 180;
|
51 |
+
}
|
52 |
+
if (!isset($params['popup_enable_info'])) {
|
53 |
+
$params['popup_enable_info'] = 1;
|
54 |
+
}
|
55 |
$from = (isset($params['from']) ? esc_html($params['from']) : 0);
|
56 |
$type = (isset($_POST['type_' . $bwg]) ? esc_html($_POST['type_' . $bwg]) : (isset($params['type']) ? $params['type'] : 'album'));
|
57 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
58 |
$sort_direction = ' ASC ';
|
59 |
if ($from === "widget") {
|
60 |
$options_row = $this->model->get_options_row_data();
|
86 |
$items_per_page = $params['compuct_album_images_per_page'];
|
87 |
$items_col_num = $params['compuct_album_image_column_number'];
|
88 |
$image_rows = $this->model->get_image_rows_data($album_gallery_id, $items_per_page, $params['sort_by'], $bwg, $sort_direction);
|
89 |
+
$images_count = count($image_rows);
|
90 |
if (!$image_rows) {
|
91 |
echo WDWLibrary::message(__('There are no images in this gallery.', 'bwg'), 'error');
|
92 |
}
|
106 |
$album_gallery_div_id = 'bwg_album_compact_' . $bwg;
|
107 |
$album_gallery_div_class = 'bwg_album_thumbnails_' . $bwg;
|
108 |
}
|
109 |
+
|
110 |
+
if ($type == 'gallery' ) {
|
111 |
+
if($album_view_type == 'masonry') {
|
112 |
+
$form_child_div_style = 'background-color:rgba(0, 0, 0, 0); position:relative; text-align:' . $theme_row->masonry_thumb_align . '; width:100%;';
|
113 |
+
$form_child_div_id = 'bwg_masonry_thumbnails_div_' . $bwg;
|
114 |
+
$album_gallery_div_id = 'bwg_masonry_thumbnails_' . $bwg;
|
115 |
+
$album_gallery_div_class = 'bwg_masonry_thumbnails_' . $bwg;
|
116 |
+
}
|
117 |
+
else {
|
118 |
+
$form_child_div_style = 'background-color:rgba(0, 0, 0, 0); position:relative; text-align:' . $theme_row->thumb_align . '; width:100%;';
|
119 |
+
$form_child_div_id = '';
|
120 |
+
}
|
121 |
+
}
|
122 |
+
else {
|
123 |
+
$form_child_div_id = '';
|
124 |
+
$form_child_div_style = 'background-color:rgba(0, 0, 0, 0); position:relative; text-align:' . $theme_row->album_compact_thumb_align . '; width:100%;';
|
125 |
+
}
|
126 |
+
|
127 |
$bwg_previous_album_id = (isset($_POST['bwg_previous_album_id_' . $bwg]) ? esc_html($_POST['bwg_previous_album_id_' . $bwg]) : 0);
|
128 |
$bwg_previous_album_page_number = (isset($_POST['bwg_previous_album_page_number_' . $bwg]) ? esc_html($_POST['bwg_previous_album_page_number_' . $bwg]) : 0);
|
129 |
|
429 |
<div id="bwg_container1_<?php echo $bwg; ?>">
|
430 |
<div id="bwg_container2_<?php echo $bwg; ?>">
|
431 |
<form id="gal_front_form_<?php echo $bwg; ?>" method="post" action="#">
|
432 |
+
<?php
|
433 |
+
if ($params['show_search_box'] && $type == 'gallery') {
|
434 |
+
WDWLibrary::ajax_html_frontend_search_box('gal_front_form_' . $bwg, $bwg, $album_gallery_div_id, $images_count, $params['search_box_width']);
|
435 |
+
}
|
436 |
+
?>
|
437 |
+
<div id="<?php echo $form_child_div_id; ?>" style="<?php echo $form_child_div_style; ?>">
|
438 |
+
<div id="ajax_loading_<?php echo $bwg; ?>" style="position:absolute;width: 100%; z-index: 115; text-align: center; height: 100%; vertical-align: middle; display: none;">
|
439 |
+
<div style="display: table; vertical-align: middle; width: 100%; height: 100%; background-color: #FFFFFF; opacity: 0.7; filter: Alpha(opacity=70);">
|
440 |
+
<div style="display: table-cell; text-align: center; position: relative; vertical-align: middle;" >
|
441 |
+
<div id="loading_div_<?php echo $bwg; ?>" style="display: inline-block; text-align:center; position:relative; vertical-align:middle;">
|
442 |
+
<img src="<?php echo WD_BWG_URL . '/images/ajax_loader.png'; ?>" class="spider_ajax_loading" style="float: none; width:50px;">
|
443 |
+
</div>
|
444 |
+
</div>
|
445 |
+
</div>
|
446 |
+
</div>
|
447 |
<?php
|
448 |
if ($params['compuct_album_enable_page'] && $items_per_page && ($theme_row->page_nav_position == 'top') && $page_nav['total']) {
|
449 |
WDWLibrary::ajax_html_frontend_page_nav($theme_row, $page_nav['total'], $page_nav['limit'], 'gal_front_form_' . $bwg, $items_per_page, $bwg, $album_gallery_div_id, $params['album_id']);
|
454 |
<?php
|
455 |
}
|
456 |
?>
|
457 |
+
<div id="<?php echo $album_gallery_div_id; ?>" class="<?php echo $album_gallery_div_class; ?>" >
|
|
|
|
|
|
|
|
|
|
|
|
|
458 |
<input type="hidden" id="bwg_previous_album_id_<?php echo $bwg; ?>" name="bwg_previous_album_id_<?php echo $bwg; ?>" value="<?php echo $bwg_previous_album_id; ?>" />
|
459 |
<input type="hidden" id="bwg_previous_album_page_number_<?php echo $bwg; ?>" name="bwg_previous_album_page_number_<?php echo $bwg; ?>" value="<?php echo $bwg_previous_album_page_number; ?>" />
|
460 |
<?php
|
555 |
}
|
556 |
elseif ($type == 'gallery') {
|
557 |
if (!$page_nav['total']) {
|
558 |
+
if ($bwg_search != '') {
|
559 |
+
?>
|
560 |
+
<span class="bwg_back_<?php echo $bwg; ?>"><?php echo __('There are no images matching your search.', 'bwg'); ?></span>
|
561 |
+
<?php
|
562 |
+
}
|
563 |
+
else {
|
564 |
+
?>
|
565 |
+
<span class="bwg_back_<?php echo $bwg; ?>"><?php echo __('Gallery is empty.', 'bwg'); ?></span>
|
566 |
+
<?php
|
567 |
+
}
|
568 |
}
|
569 |
foreach ($image_rows as $image_row) {
|
570 |
$params_array = array(
|
frontend/views/BWGViewAlbum_extended_preview.php
CHANGED
@@ -31,18 +31,34 @@ class BWGViewAlbum_extended_preview {
|
|
31 |
if (!isset($params['extended_album_image_title'])) {
|
32 |
$params['extended_album_image_title'] = 'none';
|
33 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
34 |
if (!isset($params['popup_fullscreen'])) {
|
35 |
$params['popup_fullscreen'] = 0;
|
36 |
}
|
37 |
if (!isset($params['popup_autoplay'])) {
|
38 |
$params['popup_autoplay'] = 0;
|
39 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
$theme_row = $this->model->get_theme_row_data($params['theme_id']);
|
41 |
if (!$theme_row) {
|
42 |
echo WDWLibrary::message(__('There is no theme selected or the theme was deleted.', 'bwg'), 'error');
|
43 |
return;
|
44 |
}
|
45 |
$type = (isset($_POST['type_' . $bwg]) ? esc_html($_POST['type_' . $bwg]) : 'album');
|
|
|
46 |
$album_gallery_id = (isset($_POST['album_gallery_id_' . $bwg]) ? esc_html($_POST['album_gallery_id_' . $bwg]) : $params['album_id']);
|
47 |
if (!$album_gallery_id || ($type == 'album' && !$this->model->get_album_row_data($album_gallery_id))) {
|
48 |
echo WDWLibrary::message(__('There is no album selected or the album was deleted.', 'bwg'), 'error');
|
@@ -52,6 +68,7 @@ class BWGViewAlbum_extended_preview {
|
|
52 |
$items_per_page = $params['extended_album_images_per_page'];
|
53 |
$items_col_num = $params['extended_album_image_column_number'];
|
54 |
$image_rows = $this->model->get_image_rows_data($album_gallery_id, $items_per_page, $params['sort_by'], $bwg);
|
|
|
55 |
if (!$image_rows) {
|
56 |
echo WDWLibrary::message(__('There are no images in this gallery.', 'bwg'), 'error');
|
57 |
}
|
@@ -71,6 +88,24 @@ class BWGViewAlbum_extended_preview {
|
|
71 |
$album_gallery_div_id = 'bwg_album_extended_' . $bwg;
|
72 |
$album_gallery_div_class = 'bwg_album_extended_thumbnails_' . $bwg;
|
73 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
74 |
$bwg_previous_album_id = (isset($_POST['bwg_previous_album_id_' . $bwg]) ? esc_html($_POST['bwg_previous_album_id_' . $bwg]) : 0);
|
75 |
$bwg_previous_album_page_number = (isset($_POST['bwg_previous_album_page_number_' . $bwg]) ? esc_html($_POST['bwg_previous_album_page_number_' . $bwg]) : 0);
|
76 |
|
@@ -404,7 +439,21 @@ class BWGViewAlbum_extended_preview {
|
|
404 |
<div id="bwg_container1_<?php echo $bwg; ?>">
|
405 |
<div id="bwg_container2_<?php echo $bwg; ?>">
|
406 |
<form id="gal_front_form_<?php echo $bwg; ?>" method="post" action="#">
|
407 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
408 |
<?php
|
409 |
if ($params['extended_album_enable_page'] && $items_per_page && ($theme_row->page_nav_position == 'top') && $page_nav['total']) {
|
410 |
WDWLibrary::ajax_html_frontend_page_nav($theme_row, $page_nav['total'], $page_nav['limit'], 'gal_front_form_' . $bwg, $items_per_page, $bwg, $album_gallery_div_id, $params['album_id']);
|
@@ -415,13 +464,7 @@ class BWGViewAlbum_extended_preview {
|
|
415 |
<?php
|
416 |
}
|
417 |
?>
|
418 |
-
<div id="
|
419 |
-
<div id="ajax_loading_<?php echo $bwg; ?>" style="position:absolute;">
|
420 |
-
<div id="opacity_div_<?php echo $bwg; ?>" style="display:none; background-color:#FFFFFF; opacity:0.7; filter:Alpha(opacity=70); position:absolute; z-index:105;"></div>
|
421 |
-
<span id="loading_div_<?php echo $bwg; ?>" style="display:none; text-align:center; position:relative; vertical-align:middle; z-index:107">
|
422 |
-
<img src="<?php echo WD_BWG_URL . '/images/ajax_loader.png'; ?>" class="spider_ajax_loading" style="float: none; width:50px;">
|
423 |
-
</span>
|
424 |
-
</div>
|
425 |
<input type="hidden" id="bwg_previous_album_id_<?php echo $bwg; ?>" name="bwg_previous_album_id_<?php echo $bwg; ?>" value="<?php echo $bwg_previous_album_id; ?>" />
|
426 |
<input type="hidden" id="bwg_previous_album_page_number_<?php echo $bwg; ?>" name="bwg_previous_album_page_number_<?php echo $bwg; ?>" value="<?php echo $bwg_previous_album_page_number; ?>" />
|
427 |
<?php
|
@@ -531,9 +574,16 @@ class BWGViewAlbum_extended_preview {
|
|
531 |
}
|
532 |
elseif ($type == 'gallery') {
|
533 |
if (!$page_nav['total']) {
|
534 |
-
|
535 |
-
|
536 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
537 |
}
|
538 |
foreach ($image_rows as $image_row) {
|
539 |
$params_array = array(
|
31 |
if (!isset($params['extended_album_image_title'])) {
|
32 |
$params['extended_album_image_title'] = 'none';
|
33 |
}
|
34 |
+
if (!isset($params['extended_album_view_type'])) {
|
35 |
+
$album_view_type = 'thumbnail';
|
36 |
+
}
|
37 |
+
else {
|
38 |
+
$album_view_type = $params['extended_album_view_type'];
|
39 |
+
}
|
40 |
if (!isset($params['popup_fullscreen'])) {
|
41 |
$params['popup_fullscreen'] = 0;
|
42 |
}
|
43 |
if (!isset($params['popup_autoplay'])) {
|
44 |
$params['popup_autoplay'] = 0;
|
45 |
}
|
46 |
+
if (!isset($params['show_search_box'])) {
|
47 |
+
$params['show_search_box'] = 0;
|
48 |
+
}
|
49 |
+
if (!isset($params['search_box_width'])) {
|
50 |
+
$params['search_box_width'] = 180;
|
51 |
+
}
|
52 |
+
if (!isset($params['popup_enable_info'])) {
|
53 |
+
$params['popup_enable_info'] = 1;
|
54 |
+
}
|
55 |
$theme_row = $this->model->get_theme_row_data($params['theme_id']);
|
56 |
if (!$theme_row) {
|
57 |
echo WDWLibrary::message(__('There is no theme selected or the theme was deleted.', 'bwg'), 'error');
|
58 |
return;
|
59 |
}
|
60 |
$type = (isset($_POST['type_' . $bwg]) ? esc_html($_POST['type_' . $bwg]) : 'album');
|
61 |
+
$bwg_search = ((isset($_POST['bwg_search_' . $bwg]) && esc_html($_POST['bwg_search_' . $bwg]) != '') ? esc_html($_POST['bwg_search_' . $bwg]) : '');
|
62 |
$album_gallery_id = (isset($_POST['album_gallery_id_' . $bwg]) ? esc_html($_POST['album_gallery_id_' . $bwg]) : $params['album_id']);
|
63 |
if (!$album_gallery_id || ($type == 'album' && !$this->model->get_album_row_data($album_gallery_id))) {
|
64 |
echo WDWLibrary::message(__('There is no album selected or the album was deleted.', 'bwg'), 'error');
|
68 |
$items_per_page = $params['extended_album_images_per_page'];
|
69 |
$items_col_num = $params['extended_album_image_column_number'];
|
70 |
$image_rows = $this->model->get_image_rows_data($album_gallery_id, $items_per_page, $params['sort_by'], $bwg);
|
71 |
+
$images_count = count($image_rows);
|
72 |
if (!$image_rows) {
|
73 |
echo WDWLibrary::message(__('There are no images in this gallery.', 'bwg'), 'error');
|
74 |
}
|
88 |
$album_gallery_div_id = 'bwg_album_extended_' . $bwg;
|
89 |
$album_gallery_div_class = 'bwg_album_extended_thumbnails_' . $bwg;
|
90 |
}
|
91 |
+
|
92 |
+
if ($type == 'gallery' ) {
|
93 |
+
if($album_view_type == 'masonry') {
|
94 |
+
$form_child_div_id = 'bwg_masonry_thumbnails_div_' . $bwg;
|
95 |
+
$form_child_div_style = 'background-color:rgba(0, 0, 0, 0); position:relative; text-align:' . $theme_row->masonry_thumb_align . '; width:100%;';
|
96 |
+
$album_gallery_div_id = 'bwg_masonry_thumbnails_' . $bwg;
|
97 |
+
$album_gallery_div_class = 'bwg_masonry_thumbnails_' . $bwg;
|
98 |
+
}
|
99 |
+
else {
|
100 |
+
$form_child_div_style = 'background-color:rgba(0, 0, 0, 0); position:relative; text-align:' . $theme_row->thumb_align . '; width:100%;';
|
101 |
+
$form_child_div_id = '';
|
102 |
+
}
|
103 |
+
}
|
104 |
+
else {
|
105 |
+
$form_child_div_id = '';
|
106 |
+
$form_child_div_style = 'background-color:rgba(0, 0, 0, 0); position:relative; text-align:' . $theme_row->album_extended_thumb_align . '; width:100%;';
|
107 |
+
}
|
108 |
+
|
109 |
$bwg_previous_album_id = (isset($_POST['bwg_previous_album_id_' . $bwg]) ? esc_html($_POST['bwg_previous_album_id_' . $bwg]) : 0);
|
110 |
$bwg_previous_album_page_number = (isset($_POST['bwg_previous_album_page_number_' . $bwg]) ? esc_html($_POST['bwg_previous_album_page_number_' . $bwg]) : 0);
|
111 |
|
439 |
<div id="bwg_container1_<?php echo $bwg; ?>">
|
440 |
<div id="bwg_container2_<?php echo $bwg; ?>">
|
441 |
<form id="gal_front_form_<?php echo $bwg; ?>" method="post" action="#">
|
442 |
+
<?php
|
443 |
+
if ($params['show_search_box'] && $type == 'gallery') {
|
444 |
+
WDWLibrary::ajax_html_frontend_search_box('gal_front_form_' . $bwg, $bwg, $album_gallery_div_id, $images_count, $params['search_box_width']);
|
445 |
+
}
|
446 |
+
?>
|
447 |
+
<div id="<?php echo $form_child_div_id; ?>" style="<?php echo $form_child_div_style; ?>">
|
448 |
+
<div id="ajax_loading_<?php echo $bwg; ?>" style="position:absolute;width: 100%; z-index: 115; text-align: center; height: 100%; vertical-align: middle; display: none;">
|
449 |
+
<div style="display: table; vertical-align: middle; width: 100%; height: 100%; background-color:#FFFFFF; opacity:0.7; filter:Alpha(opacity=70);">
|
450 |
+
<div style="display: table-cell; text-align: center; position: relative; vertical-align: middle;" >
|
451 |
+
<div id="loading_div_<?php echo $bwg; ?>" style="display: inline-block; text-align: center; position: relative; vertical-align: middle;">
|
452 |
+
<img src="<?php echo WD_BWG_URL . '/images/ajax_loader.png'; ?>" class="spider_ajax_loading" style="float: none; width:50px;">
|
453 |
+
</div>
|
454 |
+
</div>
|
455 |
+
</div>
|
456 |
+
</div>
|
457 |
<?php
|
458 |
if ($params['extended_album_enable_page'] && $items_per_page && ($theme_row->page_nav_position == 'top') && $page_nav['total']) {
|
459 |
WDWLibrary::ajax_html_frontend_page_nav($theme_row, $page_nav['total'], $page_nav['limit'], 'gal_front_form_' . $bwg, $items_per_page, $bwg, $album_gallery_div_id, $params['album_id']);
|
464 |
<?php
|
465 |
}
|
466 |
?>
|
467 |
+
<div id="<?php echo $album_gallery_div_id; ?>" class="<?php echo $album_gallery_div_class; ?>">
|
|
|
|
|
|
|
|
|
|
|
|
|
468 |
<input type="hidden" id="bwg_previous_album_id_<?php echo $bwg; ?>" name="bwg_previous_album_id_<?php echo $bwg; ?>" value="<?php echo $bwg_previous_album_id; ?>" />
|
469 |
<input type="hidden" id="bwg_previous_album_page_number_<?php echo $bwg; ?>" name="bwg_previous_album_page_number_<?php echo $bwg; ?>" value="<?php echo $bwg_previous_album_page_number; ?>" />
|
470 |
<?php
|
574 |
}
|
575 |
elseif ($type == 'gallery') {
|
576 |
if (!$page_nav['total']) {
|
577 |
+
if ($bwg_search != '') {
|
578 |
+
?>
|
579 |
+
<span class="bwg_back_<?php echo $bwg; ?>"><?php echo __('There are no images matching your search.', 'bwg'); ?></span>
|
580 |
+
<?php
|
581 |
+
}
|
582 |
+
else {
|
583 |
+
?>
|
584 |
+
<span class="bwg_back_<?php echo $bwg; ?>"><?php echo __('Gallery is empty.', 'bwg'); ?></span>
|
585 |
+
<?php
|
586 |
+
}
|
587 |
}
|
588 |
foreach ($image_rows as $image_row) {
|
589 |
$params_array = array(
|
frontend/views/BWGViewGalleryBox.php
CHANGED
@@ -42,6 +42,7 @@ class BWGViewGalleryBox {
|
|
42 |
$order_by = (isset($_GET['order_by']) ? esc_html($_GET['order_by']) : 'asc');
|
43 |
$enable_image_filmstrip = FALSE;
|
44 |
$enable_image_fullscreen = (isset($_GET['enable_image_fullscreen']) ? esc_html($_GET['enable_image_fullscreen']) : 0);
|
|
|
45 |
|
46 |
if ($enable_image_filmstrip) {
|
47 |
$image_filmstrip_height = (isset($_GET['image_filmstrip_height']) ? esc_html($_GET['image_filmstrip_height']) : '20');
|
@@ -104,6 +105,7 @@ class BWGViewGalleryBox {
|
|
104 |
'image_filmstrip_height' => $image_filmstrip_height,
|
105 |
'enable_image_ctrl_btn' => $enable_image_ctrl_btn,
|
106 |
'enable_image_fullscreen' => $enable_image_fullscreen,
|
|
|
107 |
'slideshow_interval' => $slideshow_interval,
|
108 |
'enable_comment_social' => $enable_comment_social,
|
109 |
'enable_image_facebook' => $enable_image_facebook,
|
@@ -695,9 +697,9 @@ class BWGViewGalleryBox {
|
|
695 |
}
|
696 |
?>
|
697 |
<i title="<?php echo __('Fullscreen', 'bwg'); ?>" class="bwg_ctrl_btn bwg_fullscreen fa fa-fullscreen"></i>
|
698 |
-
<?php } ?>
|
699 |
<i title="<?php echo __('Show info', 'bwg'); ?>" class="bwg_ctrl_btn bwg_info fa fa-info"></i>
|
700 |
-
<?php
|
701 |
if ($option_row->popup_enable_fullsize_image) {
|
702 |
?>
|
703 |
<a id="bwg_fullsize_image" href="<?php echo site_url() . '/' . $WD_BWG_UPLOAD_DIR . $current_image_url; ?>" target="_blank">
|
@@ -1175,11 +1177,6 @@ class BWGViewGalleryBox {
|
|
1175 |
function bwg_blindH(current_image_class, next_image_class, direction) {
|
1176 |
bwg_grid(10, 1, 0, 0, 0, .7, 0, current_image_class, next_image_class);
|
1177 |
}
|
1178 |
-
/*jQuery(document).ready(function () {
|
1179 |
-
jQuery('meta[name="bwg_image"]').attr("content", "");
|
1180 |
-
jQuery('meta[name="bwg_description"]').attr("content", "");
|
1181 |
-
jQuery('meta[name="bwg_title"]').attr("content", "");
|
1182 |
-
});*/
|
1183 |
function bwg_change_image(current_key, key, data, from_effect) {
|
1184 |
/* Pause videos.*/
|
1185 |
jQuery("#bwg_image_container").find("iframe").each(function () {
|
@@ -1225,9 +1222,9 @@ class BWGViewGalleryBox {
|
|
1225 |
bwg_current_key = key;
|
1226 |
/* Change image id, title, description.*/
|
1227 |
jQuery("#bwg_popup_image").attr('image_id', data[key]["id"]);
|
1228 |
-
|
1229 |
-
|
1230 |
-
|
1231 |
jQuery(".bwg_image_info_container1").css("display", "table-cell");
|
1232 |
}
|
1233 |
else {
|
42 |
$order_by = (isset($_GET['order_by']) ? esc_html($_GET['order_by']) : 'asc');
|
43 |
$enable_image_filmstrip = FALSE;
|
44 |
$enable_image_fullscreen = (isset($_GET['enable_image_fullscreen']) ? esc_html($_GET['enable_image_fullscreen']) : 0);
|
45 |
+
$popup_enable_info = (isset($_GET['popup_enable_info']) ? esc_html($_GET['popup_enable_info']) : 0);
|
46 |
|
47 |
if ($enable_image_filmstrip) {
|
48 |
$image_filmstrip_height = (isset($_GET['image_filmstrip_height']) ? esc_html($_GET['image_filmstrip_height']) : '20');
|
105 |
'image_filmstrip_height' => $image_filmstrip_height,
|
106 |
'enable_image_ctrl_btn' => $enable_image_ctrl_btn,
|
107 |
'enable_image_fullscreen' => $enable_image_fullscreen,
|
108 |
+
'popup_enable_info' => $popup_enable_info,
|
109 |
'slideshow_interval' => $slideshow_interval,
|
110 |
'enable_comment_social' => $enable_comment_social,
|
111 |
'enable_image_facebook' => $enable_image_facebook,
|
697 |
}
|
698 |
?>
|
699 |
<i title="<?php echo __('Fullscreen', 'bwg'); ?>" class="bwg_ctrl_btn bwg_fullscreen fa fa-fullscreen"></i>
|
700 |
+
<?php } if ($popup_enable_info) { ?>
|
701 |
<i title="<?php echo __('Show info', 'bwg'); ?>" class="bwg_ctrl_btn bwg_info fa fa-info"></i>
|
702 |
+
<?php }
|
703 |
if ($option_row->popup_enable_fullsize_image) {
|
704 |
?>
|
705 |
<a id="bwg_fullsize_image" href="<?php echo site_url() . '/' . $WD_BWG_UPLOAD_DIR . $current_image_url; ?>" target="_blank">
|
1177 |
function bwg_blindH(current_image_class, next_image_class, direction) {
|
1178 |
bwg_grid(10, 1, 0, 0, 0, .7, 0, current_image_class, next_image_class);
|
1179 |
}
|
|
|
|
|
|
|
|
|
|
|
1180 |
function bwg_change_image(current_key, key, data, from_effect) {
|
1181 |
/* Pause videos.*/
|
1182 |
jQuery("#bwg_image_container").find("iframe").each(function () {
|
1222 |
bwg_current_key = key;
|
1223 |
/* Change image id, title, description.*/
|
1224 |
jQuery("#bwg_popup_image").attr('image_id', data[key]["id"]);
|
1225 |
+
jQuery(".bwg_image_title").html(jQuery('<div />').html(data[key]["alt"]).text());
|
1226 |
+
jQuery(".bwg_image_description").html(jQuery('<div />').html(data[key]["description"]).text());
|
1227 |
+
if (jQuery(".bwg_image_info_container1").css("display") != 'none') {
|
1228 |
jQuery(".bwg_image_info_container1").css("display", "table-cell");
|
1229 |
}
|
1230 |
else {
|
frontend/views/BWGViewImage_browser.php
CHANGED
@@ -34,6 +34,15 @@ class BWGViewImage_browser {
|
|
34 |
else {
|
35 |
$order_by = $params['order_by'];
|
36 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
37 |
if (!$theme_row) {
|
38 |
echo WDWLibrary::message(__('There is no theme selected or the theme was deleted.', 'bwg'), 'error');
|
39 |
return;
|
@@ -44,6 +53,7 @@ class BWGViewImage_browser {
|
|
44 |
return;
|
45 |
}
|
46 |
$image_rows = $this->model->get_image_rows_data($params['gallery_id'], 1, $params['sort_by'], $order_by, $bwg);
|
|
|
47 |
if (!$image_rows) {
|
48 |
echo WDWLibrary::message(__('There are no images in this gallery.', 'bwg'), 'error');
|
49 |
}
|
@@ -77,6 +87,7 @@ class BWGViewImage_browser {
|
|
77 |
'image_filmstrip_height' => $params['popup_filmstrip_height'],
|
78 |
'enable_image_ctrl_btn' => $params['popup_enable_ctrl_btn'],
|
79 |
'enable_image_fullscreen' => $params['popup_enable_fullscreen'],
|
|
|
80 |
'slideshow_interval' => $params['popup_interval'],
|
81 |
'enable_comment_social' => $params['popup_enable_comment'],
|
82 |
'enable_image_facebook' => $params['popup_enable_facebook'],
|
@@ -133,6 +144,7 @@ class BWGViewImage_browser {
|
|
133 |
border-color: #<?php echo $theme_row->image_browser_full_border_color;?>;
|
134 |
padding: <?php echo $theme_row->image_browser_full_padding; ?>;
|
135 |
border-radius: <?php echo $theme_row->image_browser_full_border_radius; ?>;
|
|
|
136 |
}
|
137 |
#bwg_container1_<?php echo $bwg; ?> #bwg_container2_<?php echo $bwg; ?> .image_browser_images_<?php echo $bwg; ?> {
|
138 |
display: inline-block;
|
@@ -386,14 +398,22 @@ class BWGViewImage_browser {
|
|
386 |
<div id="bwg_container1_<?php echo $bwg; ?>">
|
387 |
<div id="bwg_container2_<?php echo $bwg; ?>">
|
388 |
<form id="gal_front_form_<?php echo $bwg; ?>" method="post" action="#">
|
|
|
|
|
|
|
|
|
|
|
389 |
<div class="image_browser_images_conteiner_<?php echo $bwg; ?>">
|
390 |
-
<div
|
391 |
-
<div
|
392 |
-
<div
|
393 |
-
|
394 |
-
|
395 |
-
|
|
|
396 |
</div>
|
|
|
|
|
397 |
<?php
|
398 |
if ( $theme_row->page_nav_position == 'top') {
|
399 |
WDWLibrary::ajax_html_frontend_page_nav($theme_row, $page_nav['total'], $page_nav['limit'], 'gal_front_form_' . $bwg,1, $bwg, 'bwg_standart_thumbnails_' . $bwg);
|
34 |
else {
|
35 |
$order_by = $params['order_by'];
|
36 |
}
|
37 |
+
if (!isset($params['show_search_box'])) {
|
38 |
+
$params['show_search_box'] = 0;
|
39 |
+
}
|
40 |
+
if (!isset($params['search_box_width'])) {
|
41 |
+
$params['search_box_width'] = 180;
|
42 |
+
}
|
43 |
+
if (!isset($params['popup_enable_info'])) {
|
44 |
+
$params['popup_enable_info'] = 1;
|
45 |
+
}
|
46 |
if (!$theme_row) {
|
47 |
echo WDWLibrary::message(__('There is no theme selected or the theme was deleted.', 'bwg'), 'error');
|
48 |
return;
|
53 |
return;
|
54 |
}
|
55 |
$image_rows = $this->model->get_image_rows_data($params['gallery_id'], 1, $params['sort_by'], $order_by, $bwg);
|
56 |
+
$images_count = count($image_rows);
|
57 |
if (!$image_rows) {
|
58 |
echo WDWLibrary::message(__('There are no images in this gallery.', 'bwg'), 'error');
|
59 |
}
|
87 |
'image_filmstrip_height' => $params['popup_filmstrip_height'],
|
88 |
'enable_image_ctrl_btn' => $params['popup_enable_ctrl_btn'],
|
89 |
'enable_image_fullscreen' => $params['popup_enable_fullscreen'],
|
90 |
+
'popup_enable_info' => $params['popup_enable_info'],
|
91 |
'slideshow_interval' => $params['popup_interval'],
|
92 |
'enable_comment_social' => $params['popup_enable_comment'],
|
93 |
'enable_image_facebook' => $params['popup_enable_facebook'],
|
144 |
border-color: #<?php echo $theme_row->image_browser_full_border_color;?>;
|
145 |
padding: <?php echo $theme_row->image_browser_full_padding; ?>;
|
146 |
border-radius: <?php echo $theme_row->image_browser_full_border_radius; ?>;
|
147 |
+
position:relative;
|
148 |
}
|
149 |
#bwg_container1_<?php echo $bwg; ?> #bwg_container2_<?php echo $bwg; ?> .image_browser_images_<?php echo $bwg; ?> {
|
150 |
display: inline-block;
|
398 |
<div id="bwg_container1_<?php echo $bwg; ?>">
|
399 |
<div id="bwg_container2_<?php echo $bwg; ?>">
|
400 |
<form id="gal_front_form_<?php echo $bwg; ?>" method="post" action="#">
|
401 |
+
<?php
|
402 |
+
if ($params['show_search_box']) {
|
403 |
+
WDWLibrary::ajax_html_frontend_search_box('gal_front_form_' . $bwg, $bwg, 'bwg_standart_thumbnails_' . $bwg, $images_count, $params['search_box_width']);
|
404 |
+
}
|
405 |
+
?>
|
406 |
<div class="image_browser_images_conteiner_<?php echo $bwg; ?>">
|
407 |
+
<div id="ajax_loading_<?php echo $bwg; ?>" style="position:absolute;width: 100%; z-index: 115; text-align: center; height: 100%; vertical-align: middle; display:none;">
|
408 |
+
<div style="display: table; vertical-align: middle; width: 100%; height: 100%; background-color: #FFFFFF; opacity: 0.7; filter: Alpha(opacity=70);">
|
409 |
+
<div style="display: table-cell; text-align: center; position: relative; vertical-align: middle;" >
|
410 |
+
<div id="loading_div_<?php echo $bwg; ?>" style="display: inline-block; text-align:center; position: relative; vertical-align: middle;">
|
411 |
+
<img src="<?php echo WD_BWG_URL . '/images/ajax_loader.png'; ?>" class="spider_ajax_loading" style="float: none; width:50px;">
|
412 |
+
</div>
|
413 |
+
</div>
|
414 |
</div>
|
415 |
+
</div>
|
416 |
+
<div class="image_browser_images_<?php echo $bwg; ?>" id="bwg_standart_thumbnails_<?php echo $bwg; ?>" >
|
417 |
<?php
|
418 |
if ( $theme_row->page_nav_position == 'top') {
|
419 |
WDWLibrary::ajax_html_frontend_page_nav($theme_row, $page_nav['total'], $page_nav['limit'], 'gal_front_form_' . $bwg,1, $bwg, 'bwg_standart_thumbnails_' . $bwg);
|
frontend/views/BWGViewThumbnails.php
CHANGED
@@ -40,6 +40,15 @@ class BWGViewThumbnails {
|
|
40 |
if (!isset($params['order_by'])) {
|
41 |
$params['order_by'] = ' asc ';
|
42 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
43 |
$from = (isset($params['from']) ? esc_html($params['from']) : 0);
|
44 |
$sort_direction = ' ' . $params['order_by'] . ' ';
|
45 |
if ($from) {
|
@@ -67,6 +76,7 @@ class BWGViewThumbnails {
|
|
67 |
$params['popup_filmstrip_height'] = $options_row->popup_filmstrip_height;
|
68 |
$params['popup_enable_ctrl_btn'] = $options_row->popup_enable_ctrl_btn;
|
69 |
$params['popup_enable_fullscreen'] = $options_row->popup_enable_fullscreen;
|
|
|
70 |
$params['popup_interval'] = $options_row->popup_interval;
|
71 |
$params['popup_enable_comment'] = $options_row->popup_enable_comment;
|
72 |
$params['popup_enable_facebook'] = $options_row->popup_enable_facebook;
|
@@ -101,6 +111,7 @@ class BWGViewThumbnails {
|
|
101 |
return;
|
102 |
}
|
103 |
$image_rows = $this->model->get_image_rows_data($params['gallery_id'], $params['images_per_page'], $params['sort_by'], $bwg, $type, $sort_direction);
|
|
|
104 |
if (!$image_rows) {
|
105 |
echo WDWLibrary::message(__('There are no images in this gallery.', 'bwg'), 'error');
|
106 |
}
|
@@ -277,25 +288,32 @@ class BWGViewThumbnails {
|
|
277 |
background-color: #<?php echo $theme_row->lightbox_overlay_bg_color; ?>;
|
278 |
opacity: <?php echo $theme_row->lightbox_overlay_bg_transparent / 100; ?>;
|
279 |
filter: Alpha(opacity=<?php echo $theme_row->lightbox_overlay_bg_transparent; ?>);
|
280 |
-
}
|
281 |
</style>
|
282 |
-
|
283 |
<div id="bwg_container1_<?php echo $bwg; ?>">
|
284 |
<div id="bwg_container2_<?php echo $bwg; ?>">
|
285 |
<form id="gal_front_form_<?php echo $bwg; ?>" method="post" action="#">
|
286 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
287 |
<?php
|
288 |
if ($params['image_enable_page'] && $params['images_per_page'] && ($theme_row->page_nav_position == 'top')) {
|
289 |
WDWLibrary::ajax_html_frontend_page_nav($theme_row, $page_nav['total'], $page_nav['limit'], 'gal_front_form_' . $bwg, $params['images_per_page'], $bwg, 'bwg_standart_thumbnails_' . $bwg);
|
290 |
}
|
291 |
?>
|
292 |
<div id="bwg_standart_thumbnails_<?php echo $bwg; ?>" class="bwg_standart_thumbnails_<?php echo $bwg; ?>">
|
293 |
-
<div id="ajax_loading_<?php echo $bwg; ?>" style="position:absolute;">
|
294 |
-
<div id="opacity_div_<?php echo $bwg; ?>" style="display:none; background-color:#FFFFFF; opacity:0.7; filter:Alpha(opacity=70); position:absolute; z-index:105;"></div>
|
295 |
-
<span id="loading_div_<?php echo $bwg; ?>" style="display:none; text-align:center; position:relative; vertical-align:middle; z-index:107">
|
296 |
-
<img src="<?php echo WD_BWG_URL . '/images/ajax_loader.png'; ?>" class="spider_ajax_loading" style="float: none; width:50px;">
|
297 |
-
</span>
|
298 |
-
</div>
|
299 |
<?php
|
300 |
foreach ($image_rows as $image_row) {
|
301 |
$params_array = array(
|
@@ -318,6 +336,7 @@ class BWGViewThumbnails {
|
|
318 |
'image_filmstrip_height' => $params['popup_filmstrip_height'],
|
319 |
'enable_image_ctrl_btn' => $params['popup_enable_ctrl_btn'],
|
320 |
'enable_image_fullscreen' => $params['popup_enable_fullscreen'],
|
|
|
321 |
'slideshow_interval' => $params['popup_interval'],
|
322 |
'enable_comment_social' => $params['popup_enable_comment'],
|
323 |
'enable_image_facebook' => $params['popup_enable_facebook'],
|
40 |
if (!isset($params['order_by'])) {
|
41 |
$params['order_by'] = ' asc ';
|
42 |
}
|
43 |
+
if (!isset($params['show_search_box'])) {
|
44 |
+
$params['show_search_box'] = 0;
|
45 |
+
}
|
46 |
+
if (!isset($params['search_box_width'])) {
|
47 |
+
$params['search_box_width'] = 180;
|
48 |
+
}
|
49 |
+
if (!isset($params['popup_enable_info'])) {
|
50 |
+
$params['popup_enable_info'] = 1;
|
51 |
+
}
|
52 |
$from = (isset($params['from']) ? esc_html($params['from']) : 0);
|
53 |
$sort_direction = ' ' . $params['order_by'] . ' ';
|
54 |
if ($from) {
|
76 |
$params['popup_filmstrip_height'] = $options_row->popup_filmstrip_height;
|
77 |
$params['popup_enable_ctrl_btn'] = $options_row->popup_enable_ctrl_btn;
|
78 |
$params['popup_enable_fullscreen'] = $options_row->popup_enable_fullscreen;
|
79 |
+
$params['popup_enable_info'] = $options_row->popup_enable_info;
|
80 |
$params['popup_interval'] = $options_row->popup_interval;
|
81 |
$params['popup_enable_comment'] = $options_row->popup_enable_comment;
|
82 |
$params['popup_enable_facebook'] = $options_row->popup_enable_facebook;
|
111 |
return;
|
112 |
}
|
113 |
$image_rows = $this->model->get_image_rows_data($params['gallery_id'], $params['images_per_page'], $params['sort_by'], $bwg, $type, $sort_direction);
|
114 |
+
$images_count = count($image_rows);
|
115 |
if (!$image_rows) {
|
116 |
echo WDWLibrary::message(__('There are no images in this gallery.', 'bwg'), 'error');
|
117 |
}
|
288 |
background-color: #<?php echo $theme_row->lightbox_overlay_bg_color; ?>;
|
289 |
opacity: <?php echo $theme_row->lightbox_overlay_bg_transparent / 100; ?>;
|
290 |
filter: Alpha(opacity=<?php echo $theme_row->lightbox_overlay_bg_transparent; ?>);
|
291 |
+
}
|
292 |
</style>
|
|
|
293 |
<div id="bwg_container1_<?php echo $bwg; ?>">
|
294 |
<div id="bwg_container2_<?php echo $bwg; ?>">
|
295 |
<form id="gal_front_form_<?php echo $bwg; ?>" method="post" action="#">
|
296 |
+
<?php
|
297 |
+
if ($params['show_search_box']) {
|
298 |
+
WDWLibrary::ajax_html_frontend_search_box('gal_front_form_' . $bwg, $bwg, 'bwg_standart_thumbnails_' . $bwg, $images_count, $params['search_box_width']);
|
299 |
+
}
|
300 |
+
?>
|
301 |
+
<div style="background-color:rgba(0, 0, 0, 0); text-align: <?php echo $theme_row->thumb_align; ?>; width:100%; position: relative;">
|
302 |
+
<div id="ajax_loading_<?php echo $bwg; ?>" style="position:absolute;width: 100%; z-index: 115; text-align: center; height: 100%; vertical-align: middle; display:none;">
|
303 |
+
<div style="display: table; vertical-align: middle; width: 100%; height: 100%; background-color: #FFFFFF; opacity: 0.7; filter: Alpha(opacity=70);">
|
304 |
+
<div style="display: table-cell; text-align: center; position: relative; vertical-align: middle;" >
|
305 |
+
<div id="loading_div_<?php echo $bwg; ?>" style="display: inline-block; text-align:center; position:relative; vertical-align: middle;">
|
306 |
+
<img src="<?php echo WD_BWG_URL . '/images/ajax_loader.png'; ?>" class="spider_ajax_loading" style="float: none; width:50px;">
|
307 |
+
</div>
|
308 |
+
</div>
|
309 |
+
</div>
|
310 |
+
</div>
|
311 |
<?php
|
312 |
if ($params['image_enable_page'] && $params['images_per_page'] && ($theme_row->page_nav_position == 'top')) {
|
313 |
WDWLibrary::ajax_html_frontend_page_nav($theme_row, $page_nav['total'], $page_nav['limit'], 'gal_front_form_' . $bwg, $params['images_per_page'], $bwg, 'bwg_standart_thumbnails_' . $bwg);
|
314 |
}
|
315 |
?>
|
316 |
<div id="bwg_standart_thumbnails_<?php echo $bwg; ?>" class="bwg_standart_thumbnails_<?php echo $bwg; ?>">
|
|
|
|
|
|
|
|
|
|
|
|
|
317 |
<?php
|
318 |
foreach ($image_rows as $image_row) {
|
319 |
$params_array = array(
|
336 |
'image_filmstrip_height' => $params['popup_filmstrip_height'],
|
337 |
'enable_image_ctrl_btn' => $params['popup_enable_ctrl_btn'],
|
338 |
'enable_image_fullscreen' => $params['popup_enable_fullscreen'],
|
339 |
+
'popup_enable_info' => $params['popup_enable_info'],
|
340 |
'slideshow_interval' => $params['popup_interval'],
|
341 |
'enable_comment_social' => $params['popup_enable_comment'],
|
342 |
'enable_image_facebook' => $params['popup_enable_facebook'],
|
js/bwg.js
CHANGED
@@ -115,6 +115,8 @@ function spider_ajax_save(form_id, tr_group) {
|
|
115 |
post_data["task"] = "ajax_search";
|
116 |
post_data["ajax_task"] = ajax_task;
|
117 |
post_data["image_current_id"] = image_current_id;
|
|
|
|
|
118 |
var flag = false;
|
119 |
if (jQuery("#check_all_items").attr('checked') == 'checked') {
|
120 |
post_data["check_all_items"] = jQuery("#check_all_items").val();
|
@@ -187,7 +189,7 @@ function spider_ajax_save(form_id, tr_group) {
|
|
187 |
jQuery('#draganddrop').html("<strong><p>Item Succesfully Deleted.</p></strong>");
|
188 |
jQuery('#draganddrop').show();
|
189 |
}
|
190 |
-
else if (!flag && ((ajax_task == 'image_publish_all') || (ajax_task == 'image_unpublish_all') || (ajax_task == 'image_delete_all') || (ajax_task == 'image_set_watermark') || (ajax_task == 'image_recover_all'))) {
|
191 |
jQuery('#draganddrop').html("<strong><p>You must select at least one item.</p></strong>");
|
192 |
jQuery('#draganddrop').show();
|
193 |
}
|
@@ -207,6 +209,10 @@ function spider_ajax_save(form_id, tr_group) {
|
|
207 |
jQuery('#draganddrop').html("<strong><p>Watermarks Succesfully Set.</p></strong>");
|
208 |
jQuery('#draganddrop').show();
|
209 |
}
|
|
|
|
|
|
|
|
|
210 |
else if (ajax_task == 'image_recover_all') {
|
211 |
jQuery('#draganddrop').html("<strong><p>Items Succesfully Reset.</p></strong>");
|
212 |
jQuery('#draganddrop').show();
|
@@ -804,6 +810,15 @@ function bwg_popup_fullscreen(num) {
|
|
804 |
}
|
805 |
}
|
806 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
807 |
function bwg_change_album_view_type(type) {
|
808 |
if (type == 'thumbnail') {
|
809 |
jQuery("#album_thumb_dimensions").html('Album thumb dimensions: ');
|
115 |
post_data["task"] = "ajax_search";
|
116 |
post_data["ajax_task"] = ajax_task;
|
117 |
post_data["image_current_id"] = image_current_id;
|
118 |
+
post_data["image_width"] = jQuery("#image_width").val();
|
119 |
+
post_data["image_height"] = jQuery("#image_height").val();
|
120 |
var flag = false;
|
121 |
if (jQuery("#check_all_items").attr('checked') == 'checked') {
|
122 |
post_data["check_all_items"] = jQuery("#check_all_items").val();
|
189 |
jQuery('#draganddrop').html("<strong><p>Item Succesfully Deleted.</p></strong>");
|
190 |
jQuery('#draganddrop').show();
|
191 |
}
|
192 |
+
else if (!flag && ((ajax_task == 'image_publish_all') || (ajax_task == 'image_unpublish_all') || (ajax_task == 'image_delete_all') || (ajax_task == 'image_set_watermark') || (ajax_task == 'image_recover_all') || (ajax_task == 'image_resize'))) {
|
193 |
jQuery('#draganddrop').html("<strong><p>You must select at least one item.</p></strong>");
|
194 |
jQuery('#draganddrop').show();
|
195 |
}
|
209 |
jQuery('#draganddrop').html("<strong><p>Watermarks Succesfully Set.</p></strong>");
|
210 |
jQuery('#draganddrop').show();
|
211 |
}
|
212 |
+
else if (ajax_task == 'image_resize') {
|
213 |
+
jQuery('#draganddrop').html("<strong><p>Images Succesfully Resized.</p></strong>");
|
214 |
+
jQuery('#draganddrop').show();
|
215 |
+
}
|
216 |
else if (ajax_task == 'image_recover_all') {
|
217 |
jQuery('#draganddrop').html("<strong><p>Items Succesfully Reset.</p></strong>");
|
218 |
jQuery('#draganddrop').show();
|
810 |
}
|
811 |
}
|
812 |
|
813 |
+
function bwg_show_search_box(num) {
|
814 |
+
if (num) {
|
815 |
+
jQuery("#tr_search_box_width").css('display', '');
|
816 |
+
}
|
817 |
+
else {
|
818 |
+
jQuery("#tr_search_box_width").css('display', 'none');
|
819 |
+
}
|
820 |
+
}
|
821 |
+
|
822 |
function bwg_change_album_view_type(type) {
|
823 |
if (type == 'thumbnail') {
|
824 |
jQuery("#album_thumb_dimensions").html('Album thumb dimensions: ');
|
js/bwg_frontend.js
CHANGED
@@ -1,4 +1,4 @@
|
|
1 |
-
function spider_frontend_ajax(form_id, current_view, id, album_gallery_id, cur_album_id, type) {
|
2 |
var page_number = jQuery("#page_number_" + current_view).val();
|
3 |
var bwg_previous_album_ids = jQuery('#bwg_previous_album_id_' + current_view).val();
|
4 |
var bwg_previous_album_page_numbers = jQuery('#bwg_previous_album_page_number_' + current_view).val();
|
@@ -18,37 +18,38 @@ function spider_frontend_ajax(form_id, current_view, id, album_gallery_id, cur_a
|
|
18 |
}
|
19 |
page_number = 1;
|
20 |
}
|
|
|
|
|
|
|
21 |
post_data["page_number_" + current_view] = page_number;
|
22 |
post_data["album_gallery_id_" + current_view] = album_gallery_id;
|
23 |
post_data["bwg_previous_album_id_" + current_view] = jQuery('#bwg_previous_album_id_' + current_view).val();
|
24 |
post_data["bwg_previous_album_page_number_" + current_view] = jQuery('#bwg_previous_album_page_number_' + current_view).val();
|
25 |
post_data["type_" + current_view] = type;
|
26 |
-
|
|
|
|
|
27 |
// Loading.
|
28 |
-
jQuery("#ajax_loading_" + current_view).css('
|
29 |
-
|
30 |
-
width: jQuery("#" + id).css('width'),
|
31 |
-
height: jQuery("#" + id).css('height'),
|
32 |
-
display: ''
|
33 |
-
});
|
34 |
-
jQuery("#loading_div_" + current_view).css({
|
35 |
-
width: jQuery("#" + id).css('width'),
|
36 |
-
height: jQuery("#" + id).css('height'),
|
37 |
-
display: 'table-cell'
|
38 |
-
});
|
39 |
-
// if (!bwg_current_url) {
|
40 |
-
// bwg_current_url = window.location;
|
41 |
-
// }
|
42 |
jQuery.post(
|
43 |
window.location,
|
44 |
post_data,
|
45 |
function (data) {
|
46 |
var str = jQuery(data).find('#gal_front_form_' + current_view).html();
|
47 |
jQuery('#gal_front_form_' + current_view).html(str);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
48 |
}
|
49 |
).success(function(jqXHR, textStatus, errorThrown) {
|
50 |
-
jQuery("#
|
51 |
-
jQuery("#loading_div_" + current_view).css({display: 'none'});
|
52 |
// window.scroll(0, spider_get_pos(document.getElementById(form_id)));
|
53 |
jQuery("html, body").animate({scrollTop: jQuery('#' + form_id).offset().top - 150}, 500);
|
54 |
// For masonry view.
|
1 |
+
function spider_frontend_ajax(form_id, current_view, id, album_gallery_id, cur_album_id, type, srch_btn) {
|
2 |
var page_number = jQuery("#page_number_" + current_view).val();
|
3 |
var bwg_previous_album_ids = jQuery('#bwg_previous_album_id_' + current_view).val();
|
4 |
var bwg_previous_album_page_numbers = jQuery('#bwg_previous_album_page_number_' + current_view).val();
|
18 |
}
|
19 |
page_number = 1;
|
20 |
}
|
21 |
+
if (srch_btn) { // Start search.
|
22 |
+
page_number = 1;
|
23 |
+
}
|
24 |
post_data["page_number_" + current_view] = page_number;
|
25 |
post_data["album_gallery_id_" + current_view] = album_gallery_id;
|
26 |
post_data["bwg_previous_album_id_" + current_view] = jQuery('#bwg_previous_album_id_' + current_view).val();
|
27 |
post_data["bwg_previous_album_page_number_" + current_view] = jQuery('#bwg_previous_album_page_number_' + current_view).val();
|
28 |
post_data["type_" + current_view] = type;
|
29 |
+
if (jQuery("#bwg_search_input_" + current_view).length > 0) { // Search box exists.
|
30 |
+
post_data["bwg_search_" + current_view] = jQuery("#bwg_search_input_" + current_view).val();
|
31 |
+
}
|
32 |
// Loading.
|
33 |
+
jQuery("#ajax_loading_" + current_view).css('display', '');
|
34 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
35 |
jQuery.post(
|
36 |
window.location,
|
37 |
post_data,
|
38 |
function (data) {
|
39 |
var str = jQuery(data).find('#gal_front_form_' + current_view).html();
|
40 |
jQuery('#gal_front_form_' + current_view).html(str);
|
41 |
+
// There are no images.
|
42 |
+
if (jQuery("#bwg_search_input_" + current_view).length > 0 && album_gallery_id == 0) { // Search box exists and not album view.
|
43 |
+
var bwg_images_count = jQuery('#bwg_images_count_' + current_view).val();
|
44 |
+
if (bwg_images_count == 0) {
|
45 |
+
var cont = jQuery("#" + id).parent().html();
|
46 |
+
var error_msg = '<div style="width:95%"><div class="error"><p><strong>' + bwg_objectL10n.bwg_search_result + '</strong></p></div></div>';
|
47 |
+
jQuery("#" + id).parent().html(error_msg + cont)
|
48 |
+
}
|
49 |
+
}
|
50 |
}
|
51 |
).success(function(jqXHR, textStatus, errorThrown) {
|
52 |
+
jQuery("#ajax_loading_" + current_view).css('display', 'none');
|
|
|
53 |
// window.scroll(0, spider_get_pos(document.getElementById(form_id)));
|
54 |
jQuery("html, body").animate({scrollTop: jQuery('#' + form_id).offset().top - 150}, 500);
|
55 |
// For masonry view.
|
js/bwg_shortcode.js
CHANGED
@@ -63,6 +63,15 @@ function bwg_popup_fullscreen() {
|
|
63 |
}
|
64 |
}
|
65 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
function bwg_change_compuct_album_view_type() {
|
67 |
if (jQuery("input[name=compuct_album_view_type]:checked").val() == 'thumbnail') {
|
68 |
jQuery("#compuct_album_image_thumb_dimensions").html('Image thumbnail dimensions: ');
|
@@ -102,6 +111,8 @@ function bwg_gallery_type(gallery_type) {
|
|
102 |
jQuery("#tr_gallery").css('display', 'none');
|
103 |
jQuery("#tr_sort_by").css('display', 'none');
|
104 |
jQuery("#tr_order_by").css('display', 'none');
|
|
|
|
|
105 |
jQuery("#tr_album").css('display', 'none');
|
106 |
|
107 |
// Thumbnails, Masonry.
|
@@ -175,10 +186,13 @@ function bwg_gallery_type(gallery_type) {
|
|
175 |
jQuery("#tr_popup_filmstrip_height").css('display', 'none');
|
176 |
jQuery("#tr_popup_enable_ctrl_btn").css('display', 'none');
|
177 |
jQuery("#tr_popup_enable_fullscreen").css('display', 'none');
|
|
|
178 |
jQuery("#tr_popup_enable_comment").css('display', 'none');
|
179 |
jQuery("#tr_popup_enable_facebook").css('display', 'none');
|
180 |
jQuery("#tr_popup_enable_twitter").css('display', 'none');
|
181 |
jQuery("#tr_popup_enable_google").css('display', 'none');
|
|
|
|
|
182 |
|
183 |
// Watermark.
|
184 |
jQuery("#tr_watermark_type").css('display', '');
|
@@ -196,6 +210,7 @@ function bwg_gallery_type(gallery_type) {
|
|
196 |
jQuery("#tr_gallery").css('display', '');
|
197 |
jQuery("#tr_sort_by").css('display', '');
|
198 |
jQuery("#tr_order_by").css('display', '');
|
|
|
199 |
bwg_change_label('image_column_number_label', 'Max. number of image columns: ');
|
200 |
bwg_change_label('thumb_width_height_label', 'Image thumbnail dimensions: ');
|
201 |
jQuery('#thumb_width').show();
|
@@ -206,6 +221,7 @@ function bwg_gallery_type(gallery_type) {
|
|
206 |
jQuery("#tr_image_title_hover").css('display', '');
|
207 |
jQuery("#tr_image_enable_page").css('display', '');
|
208 |
jQuery("#tr_thumb_width_height").css('display', '');
|
|
|
209 |
jQuery("#bwg_pro_version").html('Thumbnails');
|
210 |
jQuery("#bwg_pro_version_link").attr("href", "http://wpdemo.web-dorado.com/thumbnails-view-2/");
|
211 |
break;
|
@@ -215,6 +231,7 @@ function bwg_gallery_type(gallery_type) {
|
|
215 |
jQuery("#tr_gallery").css('display', '');
|
216 |
jQuery("#tr_sort_by").css('display', '');
|
217 |
jQuery("#tr_order_by").css('display', '');
|
|
|
218 |
if (jQuery("input[name=masonry_hor_ver]:checked").val() == 'horizontal') {
|
219 |
bwg_change_label('image_column_number_label', 'Number of image rows: ');
|
220 |
bwg_change_label('thumb_width_height_label', 'Image thumbnail height: ');
|
@@ -227,11 +244,13 @@ function bwg_gallery_type(gallery_type) {
|
|
227 |
jQuery('#thumb_width').show();
|
228 |
jQuery('#thumb_height').hide();
|
229 |
}
|
|
|
230 |
jQuery('#thumb_width_height_separator').hide();
|
231 |
jQuery("#tr_image_column_number").css('display', '');
|
232 |
jQuery("#tr_images_per_page").css('display', '');
|
233 |
jQuery("#tr_image_enable_page").css('display', '');
|
234 |
jQuery("#tr_thumb_width_height").css('display', '');
|
|
|
235 |
break;
|
236 |
|
237 |
}
|
@@ -283,9 +302,11 @@ function bwg_gallery_type(gallery_type) {
|
|
283 |
jQuery("#tr_gallery").css('display', '');
|
284 |
jQuery("#tr_sort_by").css('display', '');
|
285 |
jQuery("#tr_order_by").css('display', '');
|
|
|
286 |
jQuery("#tr_image_browser_width_height").css('display', '');
|
287 |
jQuery("#tr_image_browser_title_enable").css('display', '');
|
288 |
jQuery("#tr_image_browser_description_enable").css('display', '');
|
|
|
289 |
jQuery("#bwg_pro_version").html('Image Browser');
|
290 |
jQuery("#bwg_pro_version_link").attr("href", "http://wpdemo.web-dorado.com/image-browser-view/");
|
291 |
break;
|
@@ -293,6 +314,7 @@ function bwg_gallery_type(gallery_type) {
|
|
293 |
}
|
294 |
case 'album_compact_preview': {
|
295 |
jQuery("#tr_album").css('display', '');
|
|
|
296 |
jQuery("#tr_compuct_album_column_number").css('display', '');
|
297 |
jQuery("#tr_compuct_albums_per_page").css('display', '');
|
298 |
jQuery("#tr_compuct_album_title_hover").css('display', '');
|
@@ -305,6 +327,7 @@ function bwg_gallery_type(gallery_type) {
|
|
305 |
jQuery("#tr_compuct_album_image_thumb_width_height").css('display', '');
|
306 |
jQuery("#tr_compuct_album_enable_page").css('display', '');
|
307 |
bwg_change_compuct_album_view_type();
|
|
|
308 |
jQuery("#bwg_pro_version").html('Compact Album');
|
309 |
jQuery("#bwg_pro_version_link").attr("href", "http://wpdemo.web-dorado.com/compact-album-view/");
|
310 |
break;
|
@@ -312,6 +335,7 @@ function bwg_gallery_type(gallery_type) {
|
|
312 |
}
|
313 |
case 'album_extended_preview': {
|
314 |
jQuery("#tr_album").css('display', '');
|
|
|
315 |
jQuery("#tr_extended_albums_per_page").css('display', '');
|
316 |
jQuery("#tr_extended_album_height").css('display', '');
|
317 |
jQuery("#tr_extended_album_description_enable").css('display', '');
|
@@ -323,6 +347,7 @@ function bwg_gallery_type(gallery_type) {
|
|
323 |
jQuery("#tr_extended_album_image_thumb_width_height").css('display', '');
|
324 |
jQuery("#tr_extended_album_enable_page").css('display', '');
|
325 |
bwg_change_extended_album_view_type();
|
|
|
326 |
jQuery("#bwg_pro_version").html('Extended Album');
|
327 |
jQuery("#bwg_pro_version_link").attr("href", "http://wpdemo.web-dorado.com/extended-album-view/");
|
328 |
break;
|
@@ -332,10 +357,12 @@ function bwg_gallery_type(gallery_type) {
|
|
332 |
jQuery("#tr_gallery").css('display', '');
|
333 |
jQuery("#tr_sort_by").css('display', '');
|
334 |
jQuery("#tr_order_by").css('display', '');
|
|
|
335 |
jQuery("#tr_blog_style_width_height").css('display', '');
|
336 |
jQuery("#tr_blog_style_title_enable").css('display', '');
|
337 |
jQuery("#tr_blog_style_images_per_page").css('display', '');
|
338 |
jQuery("#tr_blog_style_enable_page").css('display', '');
|
|
|
339 |
break;
|
340 |
}
|
341 |
}
|
@@ -359,10 +386,13 @@ function bwg_gallery_type(gallery_type) {
|
|
359 |
bwg_enable_disable('none', 'tbody_popup_ctrl_btn', 'popup_ctrl_btn_no');
|
360 |
}
|
361 |
jQuery("#tr_popup_enable_fullscreen").css('display', '');
|
|
|
362 |
jQuery("#tr_popup_enable_comment").css('display', '');
|
363 |
jQuery("#tr_popup_enable_facebook").css('display', '');
|
364 |
jQuery("#tr_popup_enable_twitter").css('display', '');
|
365 |
jQuery("#tr_popup_enable_google").css('display', '');
|
|
|
|
|
366 |
bwg_popup_fullscreen();
|
367 |
}
|
368 |
}
|
63 |
}
|
64 |
}
|
65 |
|
66 |
+
function bwg_show_search_box() {
|
67 |
+
if (jQuery("#show_search_box_1").is(':checked')) {
|
68 |
+
jQuery("#tr_search_box_width").css('display', '');
|
69 |
+
}
|
70 |
+
else {
|
71 |
+
jQuery("#tr_search_box_width").css('display', 'none');
|
72 |
+
}
|
73 |
+
}
|
74 |
+
|
75 |
function bwg_change_compuct_album_view_type() {
|
76 |
if (jQuery("input[name=compuct_album_view_type]:checked").val() == 'thumbnail') {
|
77 |
jQuery("#compuct_album_image_thumb_dimensions").html('Image thumbnail dimensions: ');
|
111 |
jQuery("#tr_gallery").css('display', 'none');
|
112 |
jQuery("#tr_sort_by").css('display', 'none');
|
113 |
jQuery("#tr_order_by").css('display', 'none');
|
114 |
+
jQuery("#tr_show_search_box").css('display', 'none');
|
115 |
+
jQuery("#tr_search_box_width").css('display', 'none');
|
116 |
jQuery("#tr_album").css('display', 'none');
|
117 |
|
118 |
// Thumbnails, Masonry.
|
186 |
jQuery("#tr_popup_filmstrip_height").css('display', 'none');
|
187 |
jQuery("#tr_popup_enable_ctrl_btn").css('display', 'none');
|
188 |
jQuery("#tr_popup_enable_fullscreen").css('display', 'none');
|
189 |
+
jQuery("#tr_popup_enable_info").css('display', 'none');
|
190 |
jQuery("#tr_popup_enable_comment").css('display', 'none');
|
191 |
jQuery("#tr_popup_enable_facebook").css('display', 'none');
|
192 |
jQuery("#tr_popup_enable_twitter").css('display', 'none');
|
193 |
jQuery("#tr_popup_enable_google").css('display', 'none');
|
194 |
+
jQuery("#tr_popup_enable_pinterest").css('display', 'none');
|
195 |
+
jQuery("#tr_popup_enable_tumblr").css('display', 'none');
|
196 |
|
197 |
// Watermark.
|
198 |
jQuery("#tr_watermark_type").css('display', '');
|
210 |
jQuery("#tr_gallery").css('display', '');
|
211 |
jQuery("#tr_sort_by").css('display', '');
|
212 |
jQuery("#tr_order_by").css('display', '');
|
213 |
+
jQuery("#tr_show_search_box").css('display', '');
|
214 |
bwg_change_label('image_column_number_label', 'Max. number of image columns: ');
|
215 |
bwg_change_label('thumb_width_height_label', 'Image thumbnail dimensions: ');
|
216 |
jQuery('#thumb_width').show();
|
221 |
jQuery("#tr_image_title_hover").css('display', '');
|
222 |
jQuery("#tr_image_enable_page").css('display', '');
|
223 |
jQuery("#tr_thumb_width_height").css('display', '');
|
224 |
+
bwg_show_search_box();
|
225 |
jQuery("#bwg_pro_version").html('Thumbnails');
|
226 |
jQuery("#bwg_pro_version_link").attr("href", "http://wpdemo.web-dorado.com/thumbnails-view-2/");
|
227 |
break;
|
231 |
jQuery("#tr_gallery").css('display', '');
|
232 |
jQuery("#tr_sort_by").css('display', '');
|
233 |
jQuery("#tr_order_by").css('display', '');
|
234 |
+
jQuery("#tr_show_search_box").css('display', '');
|
235 |
if (jQuery("input[name=masonry_hor_ver]:checked").val() == 'horizontal') {
|
236 |
bwg_change_label('image_column_number_label', 'Number of image rows: ');
|
237 |
bwg_change_label('thumb_width_height_label', 'Image thumbnail height: ');
|
244 |
jQuery('#thumb_width').show();
|
245 |
jQuery('#thumb_height').hide();
|
246 |
}
|
247 |
+
jQuery("#tr_masonry_hor_ver").css('display', '');
|
248 |
jQuery('#thumb_width_height_separator').hide();
|
249 |
jQuery("#tr_image_column_number").css('display', '');
|
250 |
jQuery("#tr_images_per_page").css('display', '');
|
251 |
jQuery("#tr_image_enable_page").css('display', '');
|
252 |
jQuery("#tr_thumb_width_height").css('display', '');
|
253 |
+
bwg_show_search_box();
|
254 |
break;
|
255 |
|
256 |
}
|
302 |
jQuery("#tr_gallery").css('display', '');
|
303 |
jQuery("#tr_sort_by").css('display', '');
|
304 |
jQuery("#tr_order_by").css('display', '');
|
305 |
+
jQuery("#tr_show_search_box").css('display', '');
|
306 |
jQuery("#tr_image_browser_width_height").css('display', '');
|
307 |
jQuery("#tr_image_browser_title_enable").css('display', '');
|
308 |
jQuery("#tr_image_browser_description_enable").css('display', '');
|
309 |
+
bwg_show_search_box();
|
310 |
jQuery("#bwg_pro_version").html('Image Browser');
|
311 |
jQuery("#bwg_pro_version_link").attr("href", "http://wpdemo.web-dorado.com/image-browser-view/");
|
312 |
break;
|
314 |
}
|
315 |
case 'album_compact_preview': {
|
316 |
jQuery("#tr_album").css('display', '');
|
317 |
+
jQuery("#tr_show_search_box").css('display', '');
|
318 |
jQuery("#tr_compuct_album_column_number").css('display', '');
|
319 |
jQuery("#tr_compuct_albums_per_page").css('display', '');
|
320 |
jQuery("#tr_compuct_album_title_hover").css('display', '');
|
327 |
jQuery("#tr_compuct_album_image_thumb_width_height").css('display', '');
|
328 |
jQuery("#tr_compuct_album_enable_page").css('display', '');
|
329 |
bwg_change_compuct_album_view_type();
|
330 |
+
bwg_show_search_box();
|
331 |
jQuery("#bwg_pro_version").html('Compact Album');
|
332 |
jQuery("#bwg_pro_version_link").attr("href", "http://wpdemo.web-dorado.com/compact-album-view/");
|
333 |
break;
|
335 |
}
|
336 |
case 'album_extended_preview': {
|
337 |
jQuery("#tr_album").css('display', '');
|
338 |
+
jQuery("#tr_show_search_box").css('display', '');
|
339 |
jQuery("#tr_extended_albums_per_page").css('display', '');
|
340 |
jQuery("#tr_extended_album_height").css('display', '');
|
341 |
jQuery("#tr_extended_album_description_enable").css('display', '');
|
347 |
jQuery("#tr_extended_album_image_thumb_width_height").css('display', '');
|
348 |
jQuery("#tr_extended_album_enable_page").css('display', '');
|
349 |
bwg_change_extended_album_view_type();
|
350 |
+
bwg_show_search_box();
|
351 |
jQuery("#bwg_pro_version").html('Extended Album');
|
352 |
jQuery("#bwg_pro_version_link").attr("href", "http://wpdemo.web-dorado.com/extended-album-view/");
|
353 |
break;
|
357 |
jQuery("#tr_gallery").css('display', '');
|
358 |
jQuery("#tr_sort_by").css('display', '');
|
359 |
jQuery("#tr_order_by").css('display', '');
|
360 |
+
jQuery("#tr_show_search_box").css('display', '');
|
361 |
jQuery("#tr_blog_style_width_height").css('display', '');
|
362 |
jQuery("#tr_blog_style_title_enable").css('display', '');
|
363 |
jQuery("#tr_blog_style_images_per_page").css('display', '');
|
364 |
jQuery("#tr_blog_style_enable_page").css('display', '');
|
365 |
+
bwg_show_search_box();
|
366 |
break;
|
367 |
}
|
368 |
}
|
386 |
bwg_enable_disable('none', 'tbody_popup_ctrl_btn', 'popup_ctrl_btn_no');
|
387 |
}
|
388 |
jQuery("#tr_popup_enable_fullscreen").css('display', '');
|
389 |
+
jQuery("#tr_popup_enable_info").css('display', '');
|
390 |
jQuery("#tr_popup_enable_comment").css('display', '');
|
391 |
jQuery("#tr_popup_enable_facebook").css('display', '');
|
392 |
jQuery("#tr_popup_enable_twitter").css('display', '');
|
393 |
jQuery("#tr_popup_enable_google").css('display', '');
|
394 |
+
jQuery("#tr_popup_enable_pinterest").css('display', '');
|
395 |
+
jQuery("#tr_popup_enable_tumblr").css('display', '');
|
396 |
bwg_popup_fullscreen();
|
397 |
}
|
398 |
}
|
photo-gallery.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Plugin Name: Photo Gallery
|
5 |
* Plugin URI: http://web-dorado.com/products/wordpress-photo-gallery-plugin.html
|
6 |
* Description: This plugin is a fully responsive gallery plugin with advanced functionality. It allows having different image galleries for your posts and pages. You can create unlimited number of galleries, combine them into albums, and provide descriptions and tags.
|
7 |
-
* Version: 1.1.
|
8 |
* Author: http://web-dorado.com/
|
9 |
* License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
|
10 |
*/
|
@@ -154,6 +154,8 @@ function bwg_shortcode($params) {
|
|
154 |
'gallery_id' => 1,
|
155 |
'sort_by' => 'order',
|
156 |
'order_by' => 'asc',
|
|
|
|
|
157 |
'image_column_number' => 3,
|
158 |
'images_per_page' => 15,
|
159 |
'image_title' => 'none',
|
@@ -205,6 +207,8 @@ function bwg_shortcode($params) {
|
|
205 |
'gallery_id' => 1,
|
206 |
'sort_by' => 'order',
|
207 |
'order_by' => 'asc',
|
|
|
|
|
208 |
'image_browser_width' => 800,
|
209 |
'image_browser_title_enable' => 1,
|
210 |
'image_browser_description_enable' => 1,
|
@@ -238,6 +242,8 @@ function bwg_shortcode($params) {
|
|
238 |
shortcode_atts(array(
|
239 |
'album_id' => 1,
|
240 |
'sort_by' => 'order',
|
|
|
|
|
241 |
'extended_albums_per_page' => 15,
|
242 |
'extended_album_height' => 150,
|
243 |
'extended_album_description_enable' => 1,
|
@@ -272,6 +278,7 @@ function bwg_shortcode($params) {
|
|
272 |
'popup_filmstrip_height' => 70,
|
273 |
'popup_enable_ctrl_btn' => 1,
|
274 |
'popup_enable_fullscreen' => 1,
|
|
|
275 |
'popup_enable_comment' => 1,
|
276 |
'popup_enable_facebook' => 1,
|
277 |
'popup_enable_twitter' => 1,
|
@@ -494,6 +501,7 @@ function bwg_activate() {
|
|
494 |
`popup_filmstrip_height` int(4) NOT NULL,
|
495 |
`popup_enable_ctrl_btn` tinyint(1) NOT NULL,
|
496 |
`popup_enable_fullscreen` tinyint(1) NOT NULL,
|
|
|
497 |
`popup_enable_comment` tinyint(1) NOT NULL,
|
498 |
`popup_enable_email` tinyint(1) NOT NULL,
|
499 |
`popup_enable_captcha` tinyint(1) NOT NULL,
|
@@ -534,6 +542,8 @@ function bwg_activate() {
|
|
534 |
`album_view_type` varchar(64) NOT NULL,
|
535 |
`popup_enable_pinterest` tinyint(1) NOT NULL,
|
536 |
`popup_enable_tumblr` tinyint(1) NOT NULL,
|
|
|
|
|
537 |
PRIMARY KEY (`id`)
|
538 |
) ENGINE=MyISAM DEFAULT CHARSET=utf8;";
|
539 |
$wpdb->query($bwg_option);
|
@@ -1005,6 +1015,9 @@ function bwg_activate() {
|
|
1005 |
'album_view_type' => 'thumbnail',
|
1006 |
'popup_enable_pinterest' => 0,
|
1007 |
'popup_enable_tumblr' => 0,
|
|
|
|
|
|
|
1008 |
), array(
|
1009 |
'%d',
|
1010 |
'%s',
|
@@ -1101,6 +1114,9 @@ function bwg_activate() {
|
|
1101 |
'%s',
|
1102 |
'%d',
|
1103 |
'%d',
|
|
|
|
|
|
|
1104 |
));
|
1105 |
}
|
1106 |
$exists_default = $wpdb->get_var('SELECT count(id) FROM ' . $wpdb->prefix . 'bwg_theme');
|
@@ -2506,7 +2522,7 @@ function bwg_activate() {
|
|
2506 |
));
|
2507 |
}
|
2508 |
$version = get_option("wd_bwg_version");
|
2509 |
-
$new_version = '1.1.
|
2510 |
if ($version && version_compare($version, $new_version, '<')) {
|
2511 |
require_once WD_BWG_DIR . "/update/bwg_update.php";
|
2512 |
bwg_update($version);
|
@@ -2590,6 +2606,7 @@ function bwg_front_end_scripts() {
|
|
2590 |
wp_localize_script('bwg_gallery_box', 'bwg_objectL10n', array(
|
2591 |
'bwg_field_required' => __('field is required.', 'bwg'),
|
2592 |
'bwg_mail_validation' => __('This is not a valid email address.', 'bwg'),
|
|
|
2593 |
));
|
2594 |
}
|
2595 |
add_action('wp_enqueue_scripts', 'bwg_front_end_scripts');
|
4 |
* Plugin Name: Photo Gallery
|
5 |
* Plugin URI: http://web-dorado.com/products/wordpress-photo-gallery-plugin.html
|
6 |
* Description: This plugin is a fully responsive gallery plugin with advanced functionality. It allows having different image galleries for your posts and pages. You can create unlimited number of galleries, combine them into albums, and provide descriptions and tags.
|
7 |
+
* Version: 1.1.15
|
8 |
* Author: http://web-dorado.com/
|
9 |
* License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
|
10 |
*/
|
154 |
'gallery_id' => 1,
|
155 |
'sort_by' => 'order',
|
156 |
'order_by' => 'asc',
|
157 |
+
'show_search_box' => 0,
|
158 |
+
'search_box_width' => 180,
|
159 |
'image_column_number' => 3,
|
160 |
'images_per_page' => 15,
|
161 |
'image_title' => 'none',
|
207 |
'gallery_id' => 1,
|
208 |
'sort_by' => 'order',
|
209 |
'order_by' => 'asc',
|
210 |
+
'show_search_box' => 0,
|
211 |
+
'search_box_width' => 180,
|
212 |
'image_browser_width' => 800,
|
213 |
'image_browser_title_enable' => 1,
|
214 |
'image_browser_description_enable' => 1,
|
242 |
shortcode_atts(array(
|
243 |
'album_id' => 1,
|
244 |
'sort_by' => 'order',
|
245 |
+
'show_search_box' => 0,
|
246 |
+
'search_box_width' => 180,
|
247 |
'extended_albums_per_page' => 15,
|
248 |
'extended_album_height' => 150,
|
249 |
'extended_album_description_enable' => 1,
|
278 |
'popup_filmstrip_height' => 70,
|
279 |
'popup_enable_ctrl_btn' => 1,
|
280 |
'popup_enable_fullscreen' => 1,
|
281 |
+
'popup_enable_info' => 1,
|
282 |
'popup_enable_comment' => 1,
|
283 |
'popup_enable_facebook' => 1,
|
284 |
'popup_enable_twitter' => 1,
|
501 |
`popup_filmstrip_height` int(4) NOT NULL,
|
502 |
`popup_enable_ctrl_btn` tinyint(1) NOT NULL,
|
503 |
`popup_enable_fullscreen` tinyint(1) NOT NULL,
|
504 |
+
`popup_enable_info` tinyint(1) NOT NULL,
|
505 |
`popup_enable_comment` tinyint(1) NOT NULL,
|
506 |
`popup_enable_email` tinyint(1) NOT NULL,
|
507 |
`popup_enable_captcha` tinyint(1) NOT NULL,
|
542 |
`album_view_type` varchar(64) NOT NULL,
|
543 |
`popup_enable_pinterest` tinyint(1) NOT NULL,
|
544 |
`popup_enable_tumblr` tinyint(1) NOT NULL,
|
545 |
+
`show_search_box` tinyint(1) NOT NULL,
|
546 |
+
`search_box_width` int(4) NOT NULL,
|
547 |
PRIMARY KEY (`id`)
|
548 |
) ENGINE=MyISAM DEFAULT CHARSET=utf8;";
|
549 |
$wpdb->query($bwg_option);
|
1015 |
'album_view_type' => 'thumbnail',
|
1016 |
'popup_enable_pinterest' => 0,
|
1017 |
'popup_enable_tumblr' => 0,
|
1018 |
+
'show_search_box' => 0,
|
1019 |
+
'search_box_width' => 180,
|
1020 |
+
'popup_enable_info' => 1,
|
1021 |
), array(
|
1022 |
'%d',
|
1023 |
'%s',
|
1114 |
'%s',
|
1115 |
'%d',
|
1116 |
'%d',
|
1117 |
+
'%d',
|
1118 |
+
'%d',
|
1119 |
+
'%d',
|
1120 |
));
|
1121 |
}
|
1122 |
$exists_default = $wpdb->get_var('SELECT count(id) FROM ' . $wpdb->prefix . 'bwg_theme');
|
2522 |
));
|
2523 |
}
|
2524 |
$version = get_option("wd_bwg_version");
|
2525 |
+
$new_version = '1.1.15';
|
2526 |
if ($version && version_compare($version, $new_version, '<')) {
|
2527 |
require_once WD_BWG_DIR . "/update/bwg_update.php";
|
2528 |
bwg_update($version);
|
2606 |
wp_localize_script('bwg_gallery_box', 'bwg_objectL10n', array(
|
2607 |
'bwg_field_required' => __('field is required.', 'bwg'),
|
2608 |
'bwg_mail_validation' => __('This is not a valid email address.', 'bwg'),
|
2609 |
+
'bwg_search_result' => __('There are no images matching your search.', 'bwg'),
|
2610 |
));
|
2611 |
}
|
2612 |
add_action('wp_enqueue_scripts', 'bwg_front_end_scripts');
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: http://web-dorado.com/products/wordpress-photo-gallery-plugin.html
|
|
4 |
Tags: photo, photo gallery, image gallery, video gallery, gallery, galleries, wordpress gallery plugin, images gallery, album, photo albums, Simple gallery, best gallery plugin, free photo gallery, wp gallery, wordpress gallery, website gallery, gallery shortcode, best gallery, picture, pictures, gallery slider, photo album, photogallery, widget gallery, image, images, photos, gallery lightbox, photoset, wordpress photo gallery plugin, wp gallery plugins, responsive wordpress photo gallery, media, image album, filterable gallery, banner rotator, fullscreen gallery, Fotogalerie, Galleria, galerie, galeri
|
5 |
Requires at least: 3.0
|
6 |
Tested up to: 3.9
|
7 |
-
Stable tag: 1.1.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -61,7 +61,8 @@ Photo Gallery product in addition to the main plugin includes 4 specific widgets
|
|
61 |
* WordPress Tag cloud hosted widget
|
62 |
* Photo Gallery Slideshow widget
|
63 |
* Photo Gallery Widget for displaying albums and galleries as widgets
|
64 |
-
* Separate shortcode generator page for the websites using custom pages/custom editors.
|
|
|
65 |
|
66 |
Upgrade to [WordPress Photo Gallery Pro](http://web-dorado.com/products/wordpress-photo-gallery-plugin.html) to add features:
|
67 |
|
@@ -71,10 +72,12 @@ Upgrade to [WordPress Photo Gallery Pro](http://web-dorado.com/products/wordpres
|
|
71 |
* Editable themes.
|
72 |
* Commenting possibility with Captcha protection possibility.
|
73 |
* Comment-managing possibility to avoid spamming (Unpublish/Delete).
|
74 |
-
* Social sharing possibility (Facebook, Google+, Twitter)
|
75 |
* Dynamic Photo Gallery Tag Cloud widget with image tag cloud and text tag cloud options.
|
76 |
|
77 |
|
|
|
|
|
78 |
### Supported languages
|
79 |
|
80 |
*If you need language of Photo Gallery which is not included in this list, please contact us and we will do the translation of Photo Gallery within 3 days. If you find some mistakes in the translation of Photo Gallery, please contact us and we will correct it within 3 days.*
|
@@ -160,8 +163,65 @@ If any problem occurs, please contact us at [info@web-dorado.com](mailto:info@w
|
|
160 |
|
161 |
== Changelog ==
|
162 |
|
163 |
-
1.
|
164 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
165 |
|
166 |
|
167 |
==Wordpress Photo Gallery Step by step guide==
|
4 |
Tags: photo, photo gallery, image gallery, video gallery, gallery, galleries, wordpress gallery plugin, images gallery, album, photo albums, Simple gallery, best gallery plugin, free photo gallery, wp gallery, wordpress gallery, website gallery, gallery shortcode, best gallery, picture, pictures, gallery slider, photo album, photogallery, widget gallery, image, images, photos, gallery lightbox, photoset, wordpress photo gallery plugin, wp gallery plugins, responsive wordpress photo gallery, media, image album, filterable gallery, banner rotator, fullscreen gallery, Fotogalerie, Galleria, galerie, galeri
|
5 |
Requires at least: 3.0
|
6 |
Tested up to: 3.9
|
7 |
+
Stable tag: 1.1.15
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
61 |
* WordPress Tag cloud hosted widget
|
62 |
* Photo Gallery Slideshow widget
|
63 |
* Photo Gallery Widget for displaying albums and galleries as widgets
|
64 |
+
* Separate shortcode generator page for the websites using custom pages/custom editors.
|
65 |
+
* Support for YouTube and Vimeo videos within Galleries.
|
66 |
|
67 |
Upgrade to [WordPress Photo Gallery Pro](http://web-dorado.com/products/wordpress-photo-gallery-plugin.html) to add features:
|
68 |
|
72 |
* Editable themes.
|
73 |
* Commenting possibility with Captcha protection possibility.
|
74 |
* Comment-managing possibility to avoid spamming (Unpublish/Delete).
|
75 |
+
* Social sharing possibility (Facebook, Google+, Twitter, Pinterest and Tumblr)
|
76 |
* Dynamic Photo Gallery Tag Cloud widget with image tag cloud and text tag cloud options.
|
77 |
|
78 |
|
79 |
+
|
80 |
+
|
81 |
### Supported languages
|
82 |
|
83 |
*If you need language of Photo Gallery which is not included in this list, please contact us and we will do the translation of Photo Gallery within 3 days. If you find some mistakes in the translation of Photo Gallery, please contact us and we will correct it within 3 days.*
|
163 |
|
164 |
== Changelog ==
|
165 |
|
166 |
+
= 1.1.15 =
|
167 |
+
* added search images in gallery (optional), optional info, resize.
|
168 |
+
|
169 |
+
= 1.1.14 =
|
170 |
+
* added option for show image title/description on lightbox.
|
171 |
+
|
172 |
+
= 1.1.13 =
|
173 |
+
* added tag cloud ordering option, keep aspect ratio.
|
174 |
+
|
175 |
+
= 1.1.12 =
|
176 |
+
* youtube, vimeo.
|
177 |
+
|
178 |
+
= 1.1.11 =
|
179 |
+
* added tag cloud options and zip upload.
|
180 |
+
|
181 |
+
= 1.1.10 =
|
182 |
+
* bug fixed on WP 3.9 editor.
|
183 |
+
|
184 |
+
= 1.1.9 =
|
185 |
+
* gallery alignment bug fixed.
|
186 |
+
|
187 |
+
= 1.1.8 =
|
188 |
+
* corrected album ordering and added slideshow widget filmstrip height option.
|
189 |
+
|
190 |
+
= 1.1.7 =
|
191 |
+
* added swipe effect on lightbox.
|
192 |
+
|
193 |
+
= 1.1.6 =
|
194 |
+
* added option disable/enable right click.
|
195 |
+
|
196 |
+
= 1.1.5 =
|
197 |
+
* bug fixed in slideshow .
|
198 |
+
|
199 |
+
= 1.1.4 =
|
200 |
+
* removed enters from code (conflicts fixed).
|
201 |
+
|
202 |
+
= 1.1.2 =
|
203 |
+
* critical bug with uninstall fixed.
|
204 |
+
|
205 |
+
= 1.0.8 =
|
206 |
+
* improved file upload and save on gallery.
|
207 |
+
|
208 |
+
= 1.0.6 =
|
209 |
+
* improved filemanager functionality, fix bug on widget.
|
210 |
+
|
211 |
+
= 1.0.5 =
|
212 |
+
* bug fixed in file manager.
|
213 |
+
|
214 |
+
= 1.0.4 =
|
215 |
+
* added shortcode generator, thumbnail title, thumb size in filemanager, bug fixed in slideshow.
|
216 |
+
|
217 |
+
= 1.0.3 =
|
218 |
+
* bug fixed in album view .
|
219 |
+
|
220 |
+
= 1.0.2 =
|
221 |
+
* php 5.2 capability.
|
222 |
+
|
223 |
+
= 1.0.1 =
|
224 |
+
* Initial version.
|
225 |
|
226 |
|
227 |
==Wordpress Photo Gallery Step by step guide==
|
update/bwg_update.php
CHANGED
@@ -55,6 +55,14 @@ function bwg_update($version) {
|
|
55 |
$wpdb->query("ALTER TABLE " . $wpdb->prefix . "bwg_theme ADD `lightbox_description_font_weight` varchar(128) NOT NULL DEFAULT 'normal' AFTER `image_browser_full_transparent`");
|
56 |
$wpdb->query("ALTER TABLE " . $wpdb->prefix . "bwg_theme ADD `lightbox_description_font_size` int(4) NOT NULL DEFAULT 14 AFTER `image_browser_full_transparent`");
|
57 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
58 |
return;
|
59 |
}
|
60 |
|
55 |
$wpdb->query("ALTER TABLE " . $wpdb->prefix . "bwg_theme ADD `lightbox_description_font_weight` varchar(128) NOT NULL DEFAULT 'normal' AFTER `image_browser_full_transparent`");
|
56 |
$wpdb->query("ALTER TABLE " . $wpdb->prefix . "bwg_theme ADD `lightbox_description_font_size` int(4) NOT NULL DEFAULT 14 AFTER `image_browser_full_transparent`");
|
57 |
}
|
58 |
+
if (version_compare($version, '1.1.15') == -1) {
|
59 |
+
// Add search box option.
|
60 |
+
$wpdb->query("ALTER TABLE " . $wpdb->prefix . "bwg_option ADD `show_search_box` tinyint(1) NOT NULL DEFAULT 0 AFTER `album_view_type`");
|
61 |
+
// Add search box width option.
|
62 |
+
$wpdb->query("ALTER TABLE " . $wpdb->prefix . "bwg_option ADD `search_box_width` int(4) NOT NULL DEFAULT 180 AFTER `show_search_box`");
|
63 |
+
// Add info enable/disable option.
|
64 |
+
$wpdb->query("ALTER TABLE " . $wpdb->prefix . "bwg_option ADD `popup_enable_info` tinyint(1) NOT NULL DEFAULT 1 AFTER `search_box_width`");
|
65 |
+
}
|
66 |
return;
|
67 |
}
|
68 |
|