WP Photo Album Plus - Version 8.2.01.007

Version Description

= 8.1.08 =

  • This version addresses various bug fixes, feature requests and security fixes.
Download this release

Release Info

Developer opajaap
Plugin Icon wp plugin WP Photo Album Plus
Version 8.2.01.007
Comparing to
See all releases

Code changes from version 8.2.01.005 to 8.2.01.007

wppa-admin.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * Contains the admin menu and startups the admin pages
6
- * Version 8.2.01.003
7
  *
8
  */
9
 
@@ -257,13 +257,17 @@ function wppa_edit_sequence() {
257
 
258
  // General purpose admin functions
259
  require_once 'wppa-admin-functions.php';
260
- if ( isset( $_REQUEST['page'] ) && $_REQUEST['page'] != 'wppa_admin_menu' ) {
 
261
  require_once 'wppa-tinymce-shortcodes.php';
262
  require_once 'wppa-tinymce-photo.php';
263
  }
264
 
265
- require_once 'wppa-gutenberg-photo.php';
266
- require_once 'wppa-gutenberg-wppa.php';
 
 
 
267
  require_once 'wppa-privacy-policy.php';
268
 
269
  /* This is for the changelog text when an update is available */
3
  * Package: wp-photo-album-plus
4
  *
5
  * Contains the admin menu and startups the admin pages
6
+ * Version 8.2.01.006
7
  *
8
  */
9
 
257
 
258
  // General purpose admin functions
259
  require_once 'wppa-admin-functions.php';
260
+
261
+ if ( isset( $_REQUEST['page'] ) && $_REQUEST['page'] != 'wppa_options' && $_REQUEST['page'] != 'wppa_admin_menu' ) {
262
  require_once 'wppa-tinymce-shortcodes.php';
263
  require_once 'wppa-tinymce-photo.php';
264
  }
265
 
266
+ if ( strpos( $_SERVER['REQUEST_URI'], 'widgets' ) === false ) {
267
+ require_once 'wppa-gutenberg-photo.php';
268
+ require_once 'wppa-gutenberg-wppa.php';
269
+ }
270
+
271
  require_once 'wppa-privacy-policy.php';
272
 
273
  /* This is for the changelog text when an update is available */
wppa-defaults.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * Contains default settings
6
- * Version 8.2.01.005
7
  *
8
  */
9
 
@@ -321,7 +321,7 @@ horizrailenabled:false,";
321
  'wppa_user_opload_roles' => '',
322
  'wppa_user_create_roles' => '',
323
  'wppa_copyright_on' => 'yes', // 19
324
- 'wppa_copyright_notice' => __('<span style="color:red" >Warning: Do not upload copyrighted material!</span>', 'wp-photo-album-plus' ), // 20
325
  'wppa_watermark_user' => 'no',
326
  'wppa_name_user' => 'yes',
327
  'wppa_name_user_mandatory' => 'no',
@@ -1012,6 +1012,7 @@ horizrailenabled:false,";
1012
  'wppa_upload_limit_time' => '0', // IX-D6b
1013
  'wppa_grant_an_album' => 'no',
1014
  'wppa_grant_name' => 'display',
 
1015
  'wppa_grant_desc' => __( 'Default photo album for $user', 'wp-photo-album-plus' ),
1016
  'wppa_grant_parent_sel_method' => 'selectionbox',
1017
  'wppa_grant_parent' => '-1',
3
  * Package: wp-photo-album-plus
4
  *
5
  * Contains default settings
6
+ * Version 8.2.01.007
7
  *
8
  */
9
 
321
  'wppa_user_opload_roles' => '',
322
  'wppa_user_create_roles' => '',
323
  'wppa_copyright_on' => 'yes', // 19
324
+ 'wppa_copyright_notice' => '<span style="color:red">' . __('Warning: Do not upload copyrighted material!', 'wp-photo-album-plus') . '</span>', // 20
325
  'wppa_watermark_user' => 'no',
326
  'wppa_name_user' => 'yes',
327
  'wppa_name_user_mandatory' => 'no',
1012
  'wppa_upload_limit_time' => '0', // IX-D6b
1013
  'wppa_grant_an_album' => 'no',
1014
  'wppa_grant_name' => 'display',
1015
+ /* translators: Keep $user untranslated. It is a placeholder for user name or id */
1016
  'wppa_grant_desc' => __( 'Default photo album for $user', 'wp-photo-album-plus' ),
1017
  'wppa_grant_parent_sel_method' => 'selectionbox',
1018
  'wppa_grant_parent' => '-1',
wppa-functions.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * Various functions
6
- * Version 8.2.01.005
7
  *
8
  */
9
 
@@ -5692,7 +5692,7 @@ function wppa_have_photos( $xwidth = '0' ) {
5692
  // Display the searchresults. For use in a page template to show the search results. See ./theme/search.php
5693
  function wppa_the_photos() {
5694
 
5695
- if ( wppa( 'any' ) ) echo wppa( 'searchresults' );
5696
  }
5697
 
5698
  // Decide if a thumbnail photo file can be used for a requested display
3
  * Package: wp-photo-album-plus
4
  *
5
  * Various functions
6
+ * Version 8.2.01.006
7
  *
8
  */
9
 
5692
  // Display the searchresults. For use in a page template to show the search results. See ./theme/search.php
5693
  function wppa_the_photos() {
5694
 
5695
+ if ( wppa( 'any' ) ) wppa_echo( wppa( 'searchresults' ) );
5696
  }
5697
 
5698
  // Decide if a thumbnail photo file can be used for a requested display
wppa-search-widget.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * display the search widget
6
- * Version 8.2.01.005
7
  *
8
  */
9
 
@@ -55,8 +55,8 @@ class SearchPhotos extends WP_Widget {
55
  }
56
  $result .= $widget_content . $after_widget;
57
 
58
- echo $result;
59
- echo wppa_widget_timer( 'show', $widget_title );
60
 
61
  wppa( 'in_widget', false );
62
  }
3
  * Package: wp-photo-album-plus
4
  *
5
  * display the search widget
6
+ * Version 8.2.01.006
7
  *
8
  */
9
 
55
  }
56
  $result .= $widget_content . $after_widget;
57
 
58
+ wppa_echo( $result );
59
+ wppa_echo( wppa_widget_timer( 'show', $widget_title ) );
60
 
61
  wppa( 'in_widget', false );
62
  }
wppa-setting-functions.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * manage all options
6
- * Version 8.2.01.001
7
  *
8
  */
9
 
@@ -758,7 +758,7 @@ global $wppa_setting_error;
758
  if ( ! $no_default ) {
759
  if ( $slugs && wppa_dflt($slugs[0]) ) {
760
  if ( count($slugs) == 1) {
761
- $helptext .= '<br>' . esc_html__( 'The default for this setting is:', 'wp-photo-album-plus' );
762
  if ( $slugs[0] != '' ) {
763
  $helptext .= ' '.htmlspecialchars(wppa_dflt($slugs[0]));
764
  if ( $wppa_opt[$slugs[0]] != $wppa_defaults[$slugs[0]] ) {
@@ -767,10 +767,10 @@ global $wppa_setting_error;
767
  }
768
  }
769
  else {
770
- $helptext .= '<br>' . esc_html__( 'The defaults for this setting are', 'wp-photo-album-plus' );
771
  $first = true;
772
  foreach ( array_keys($slugs) as $slugidx ) {
773
- if ( $slugs[$slugidx] ) $helptext .= ( $first ? ': ' : ', ' ).wppa_dflt($slugs[$slugidx]);
774
  $first = false;
775
  if ( $slugs[$slugidx] && isset($wppa_opt[$slugs[$slugidx]]) && $wppa_opt[$slugs[$slugidx]] != $wppa_defaults[$slugs[$slugidx]] ) {
776
  $is_dflt = false;
@@ -797,10 +797,10 @@ global $wppa_setting_error;
797
  '<td>' . esc_html( $xnum ) . '</td>' .
798
 
799
  // The Item name
800
- '<td>' . strip_tags( wp_check_invalid_utf8( $name ), ["<br>", "<a>", "<b>", "<i>"] ) . '</td>' .
801
 
802
  // The item description
803
- '<td><small>' . strip_tags( wp_check_invalid_utf8( $desc ), ["<br>", "<a>", "<b>", "<i>"] ) . '</small></td>';
804
 
805
  // The html
806
  if ( $htmls ) foreach ( $htmls as $html ) {
3
  * Package: wp-photo-album-plus
4
  *
5
  * manage all options
6
+ * Version 8.2.01.007
7
  *
8
  */
9
 
758
  if ( ! $no_default ) {
759
  if ( $slugs && wppa_dflt($slugs[0]) ) {
760
  if ( count($slugs) == 1) {
761
+ $helptext .= '<br>' . __( 'The default for this setting is:', 'wp-photo-album-plus' );
762
  if ( $slugs[0] != '' ) {
763
  $helptext .= ' '.htmlspecialchars(wppa_dflt($slugs[0]));
764
  if ( $wppa_opt[$slugs[0]] != $wppa_defaults[$slugs[0]] ) {
767
  }
768
  }
769
  else {
770
+ $helptext .= '<br>' . __( 'The defaults for this setting are', 'wp-photo-album-plus' );
771
  $first = true;
772
  foreach ( array_keys($slugs) as $slugidx ) {
773
+ if ( $slugs[$slugidx] ) $helptext .= ( $first ? ': ' : ', ' ).htmlspecialchars(wppa_dflt($slugs[$slugidx]));
774
  $first = false;
775
  if ( $slugs[$slugidx] && isset($wppa_opt[$slugs[$slugidx]]) && $wppa_opt[$slugs[$slugidx]] != $wppa_defaults[$slugs[$slugidx]] ) {
776
  $is_dflt = false;
797
  '<td>' . esc_html( $xnum ) . '</td>' .
798
 
799
  // The Item name
800
+ '<td>' . strip_tags( wp_check_invalid_utf8( $name ), ["<br>", "<a>", "<b>", "<i>", "<span>"] ) . '</td>' .
801
 
802
  // The item description
803
+ '<td><small>' . strip_tags( wp_check_invalid_utf8( $desc ), ["<br>", "<a>", "<b>", "<i>", "<span>"] ) . '</small></td>';
804
 
805
  // The html
806
  if ( $htmls ) foreach ( $htmls as $html ) {
wppa-settings-autosave.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * manage all options
6
- * Version 8.2.01.005
7
  *
8
  */
9
 
@@ -3194,21 +3194,21 @@ global $wppa_subtab_names;
3194
  __('EXIF data', 'wp-photo-album-plus' ),
3195
  __('Share box', 'wp-photo-album-plus' )
3196
  );
3197
- $enabled = '<span style="color:green; float:right;">( '.__('Enabled', 'wp-photo-album-plus' );
3198
- $disabled = '<span style="color:orange; float:right;">( '.__('Disabled', 'wp-photo-album-plus' );
3199
  $descs = array(
3200
- __('Start/Stop & Slower/Faster navigation bar', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_startstop_navigation') ? $enabled : $disabled ) . ' )</span>',
3201
  __('The Slide Frame', 'wp-photo-album-plus' ) . '<span style="float:right;">'.__('( Always )', 'wp-photo-album-plus' ).'</span>',
3202
- __('Photo Name Box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_full_name') ? $enabled : $disabled ) .' )</span>',
3203
- __('Photo Description Box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_full_desc') ? $enabled : $disabled ) .' )</span>',
3204
- __('Custom Box', 'wp-photo-album-plus' ) . ( wppa_switch( 'custom_on') ? $enabled : $disabled ).' )</span>',
3205
- __('Rating Bar', 'wp-photo-album-plus' ) . ( wppa_switch( 'rating_on') ? $enabled : $disabled ).' )</span>',
3206
- __('Film Strip with embedded Start/Stop and Goto functionality', 'wp-photo-album-plus' ) . ( wppa_switch( 'filmstrip') ? $enabled : $disabled ).' )</span>',
3207
- __('Browse Bar with Photo X of Y counter', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_browse_navigation') ? $enabled : $disabled ).' )</span>',
3208
- __('Comments Box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_comments') ? $enabled : $disabled ).' )</span>',
3209
- __('IPTC box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_iptc') ? $enabled : $disabled ).' )</span>',
3210
- __('EXIF box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_exif') ? $enabled : $disabled ).' )</span>',
3211
- __('Social media share box', 'wp-photo-album-plus' ) . ( wppa_switch( 'share_on') ? $enabled : $disabled ).' )</span>'
3212
  );
3213
  $i = '0';
3214
  while ( $i < '12' ) {
@@ -3424,7 +3424,7 @@ global $wppa_subtab_names;
3424
  $opts = array( '1 s.', '1.5 s.', '2.5 s.', '3 s.', '4 s.', '5 s.', '6 s.', '8 s.', '10 s.', '12 s.', '15 s.', '20 s.' );
3425
  $vals = array('1000', '1500', '2500', '3000', '4000', '5000', '6000', '8000', '10000', '12000', '15000', '20000' );
3426
  $html = wppa_select($slug, $opts, $vals);
3427
- wppa_setting_new($slug, '5', $name, $desc, $html, $help);
3428
 
3429
  $name = __('Speed', 'wp-photo-album-plus' );
3430
  $desc = __('Slideshow animation speed.', 'wp-photo-album-plus' );
@@ -4011,8 +4011,7 @@ global $wppa_subtab_names;
4011
 
4012
  $name = __('Rating change', 'wp-photo-album-plus' );
4013
  $desc = __('Users may change their ratings.', 'wp-photo-album-plus' );
4014
- $help = __('Users may change their ratings.', 'wp-photo-album-plus' );
4015
- $help .= '<br>'.(__('If "One button vote" is selected in item 5, this setting has no meaning', 'wp-photo-album-plus' ));
4016
  $slug = 'wppa_rating_change';
4017
  $html = wppa_checkbox($slug);
4018
  wppa_setting_new($slug, '10', $name, $desc, $html, $help, wppa_opt( 'rating_max' ) != '1' );
@@ -7717,6 +7716,7 @@ global $wppa_subtab_names;
7717
  $name = __('Fe Edit Theme CSS', 'wp-photo-album-plus' );
7718
  $desc = __('The front-end edit photo dialog uses the theme CSS.', 'wp-photo-album-plus' );
7719
  $help = __('This setting has effect when Frontend Edit is set to \'Classic\' only.', 'wp-photo-album-plus' );
 
7720
  $slug = 'wppa_upload_edit_theme_css';
7721
  $html = wppa_checkbox($slug);
7722
  wppa_setting_new($slug, '4', $name, $desc, $html, $help);
@@ -8034,7 +8034,7 @@ global $wppa_subtab_names;
8034
  wppa_setting_new($slug, '12', $name, $desc, $html, $help);
8035
 
8036
  $name = __('Max in shortcode generator', 'wp-photo-album-plus' );
8037
- $desc = __('Maximum nuber of selectable photos in the shortcode generators', 'wp-photo-album-plus' );
8038
  $help = '';
8039
  $slug = 'wppa_generator_max';
8040
  $opts = array( '5', '10', '20', '50', '100', '200', '500', '1000', '2000', '5000' );
3
  * Package: wp-photo-album-plus
4
  *
5
  * manage all options
6
+ * Version 8.2.01.007
7
  *
8
  */
9
 
3194
  __('EXIF data', 'wp-photo-album-plus' ),
3195
  __('Share box', 'wp-photo-album-plus' )
3196
  );
3197
+ $enabled = '<span style="color:green; float:right;"> ('.__('Enabled', 'wp-photo-album-plus').')</span>';
3198
+ $disabled = '<span style="color:orange; float:right;"> ('.__('Disabled', 'wp-photo-album-plus').')</span>';
3199
  $descs = array(
3200
+ __('Start/Stop & Slower/Faster navigation bar', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_startstop_navigation') ? $enabled : $disabled ),
3201
  __('The Slide Frame', 'wp-photo-album-plus' ) . '<span style="float:right;">'.__('( Always )', 'wp-photo-album-plus' ).'</span>',
3202
+ __('Photo Name Box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_full_name') ? $enabled : $disabled ),
3203
+ __('Photo Description Box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_full_desc') ? $enabled : $disabled ),
3204
+ __('Custom Box', 'wp-photo-album-plus' ) . ( wppa_switch( 'custom_on') ? $enabled : $disabled ),
3205
+ __('Rating Bar', 'wp-photo-album-plus' ) . ( wppa_switch( 'rating_on') ? $enabled : $disabled ),
3206
+ __('Film Strip with embedded Start/Stop and Goto functionality', 'wp-photo-album-plus' ) . ( wppa_switch( 'filmstrip') ? $enabled : $disabled ),
3207
+ __('Browse Bar with Photo X of Y counter', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_browse_navigation') ? $enabled : $disabled ),
3208
+ __('Comments Box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_comments') ? $enabled : $disabled ),
3209
+ __('IPTC box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_iptc') ? $enabled : $disabled ),
3210
+ __('EXIF box', 'wp-photo-album-plus' ) . ( wppa_switch( 'show_exif') ? $enabled : $disabled ),
3211
+ __('Social media share box', 'wp-photo-album-plus' ) . ( wppa_switch( 'share_on') ? $enabled : $disabled )
3212
  );
3213
  $i = '0';
3214
  while ( $i < '12' ) {
3424
  $opts = array( '1 s.', '1.5 s.', '2.5 s.', '3 s.', '4 s.', '5 s.', '6 s.', '8 s.', '10 s.', '12 s.', '15 s.', '20 s.' );
3425
  $vals = array('1000', '1500', '2500', '3000', '4000', '5000', '6000', '8000', '10000', '12000', '15000', '20000' );
3426
  $html = wppa_select($slug, $opts, $vals);
3427
+ wppa_setting_new($slug, '5a', $name, $desc, $html, $help);
3428
 
3429
  $name = __('Speed', 'wp-photo-album-plus' );
3430
  $desc = __('Slideshow animation speed.', 'wp-photo-album-plus' );
4011
 
4012
  $name = __('Rating change', 'wp-photo-album-plus' );
4013
  $desc = __('Users may change their ratings.', 'wp-photo-album-plus' );
4014
+ $help = __('If "One button vote" is selected in item 5, this setting has no meaning', 'wp-photo-album-plus' );
 
4015
  $slug = 'wppa_rating_change';
4016
  $html = wppa_checkbox($slug);
4017
  wppa_setting_new($slug, '10', $name, $desc, $html, $help, wppa_opt( 'rating_max' ) != '1' );
7716
  $name = __('Fe Edit Theme CSS', 'wp-photo-album-plus' );
7717
  $desc = __('The front-end edit photo dialog uses the theme CSS.', 'wp-photo-album-plus' );
7718
  $help = __('This setting has effect when Frontend Edit is set to \'Classic\' only.', 'wp-photo-album-plus' );
7719
+ $help .= ' ' . __('See item 1 in this table', 'wp-photo-album-plus');
7720
  $slug = 'wppa_upload_edit_theme_css';
7721
  $html = wppa_checkbox($slug);
7722
  wppa_setting_new($slug, '4', $name, $desc, $html, $help);
8034
  wppa_setting_new($slug, '12', $name, $desc, $html, $help);
8035
 
8036
  $name = __('Max in shortcode generator', 'wp-photo-album-plus' );
8037
+ $desc = __('Maximum number of selectable photos in the shortcode generators', 'wp-photo-album-plus' );
8038
  $help = '';
8039
  $slug = 'wppa_generator_max';
8040
  $opts = array( '5', '10', '20', '50', '100', '200', '500', '1000', '2000', '5000' );
wppa-slideshow-widget.php CHANGED
@@ -233,7 +233,6 @@ class SlideshowWidget extends WP_Widget {
233
  wppa_widget_number( $this, 'height', $instance['height'], __( 'Height in pixels', 'wp-photo-album-plus' ), '0', '500', '', 'float' );
234
 
235
  // Portrait only
236
- echo
237
  wppa_widget_checkbox( $this,
238
  'ponly',
239
  $instance['ponly'],
233
  wppa_widget_number( $this, 'height', $instance['height'], __( 'Height in pixels', 'wp-photo-album-plus' ), '0', '500', '', 'float' );
234
 
235
  // Portrait only
 
236
  wppa_widget_checkbox( $this,
237
  'ponly',
238
  $instance['ponly'],
wppa-upload-widget.php CHANGED
@@ -4,7 +4,7 @@
4
  *
5
  * A wppa widget to upload photos
6
  *
7
- * Version 8.2.01.001
8
  */
9
 
10
  class WppaUploadWidget extends WP_Widget {
@@ -77,7 +77,7 @@ class WppaUploadWidget extends WP_Widget {
77
  $result .= $widget_content . $after_widget;
78
 
79
  wppa_echo( $result );
80
- echo wppa_widget_timer( 'show', $widget_title );
81
 
82
  wppa( 'in_widget', false );
83
  }
4
  *
5
  * A wppa widget to upload photos
6
  *
7
+ * Version 8.2.01.006
8
  */
9
 
10
  class WppaUploadWidget extends WP_Widget {
77
  $result .= $widget_content . $after_widget;
78
 
79
  wppa_echo( $result );
80
+ wppa_echo( wppa_widget_timer( 'show', $widget_title ) );
81
 
82
  wppa( 'in_widget', false );
83
  }
wppa.php CHANGED
@@ -2,7 +2,7 @@
2
  /*
3
  * Plugin Name: WP Photo Album Plus
4
  * Description: Easily manage and display your photo albums and slideshows within your WordPress site.
5
- * Version: 8.2.01.005
6
  * Author: J.N. Breetvelt a.k.a. OpaJaap
7
  * Author URI: http://wppa.opajaap.nl/
8
  * Plugin URI: http://wordpress.org/extend/plugins/wp-photo-album-plus/
@@ -24,7 +24,7 @@ global $wp_version;
24
 
25
  /* WPPA GLOBALS */
26
  global $wppa_api_version;
27
- $wppa_api_version = '8.2.01.005'; // WPPA software version
28
  global $wppa_revno;
29
  $wppa_revno = str_replace( '.', '', $wppa_api_version ); // WPPA db version
30
 
2
  /*
3
  * Plugin Name: WP Photo Album Plus
4
  * Description: Easily manage and display your photo albums and slideshows within your WordPress site.
5
+ * Version: 8.2.01.007
6
  * Author: J.N. Breetvelt a.k.a. OpaJaap
7
  * Author URI: http://wppa.opajaap.nl/
8
  * Plugin URI: http://wordpress.org/extend/plugins/wp-photo-album-plus/
24
 
25
  /* WPPA GLOBALS */
26
  global $wppa_api_version;
27
+ $wppa_api_version = '8.2.01.007'; // WPPA software version
28
  global $wppa_revno;
29
  $wppa_revno = str_replace( '.', '', $wppa_api_version ); // WPPA db version
30