WP Photo Album Plus - Version 7.3.13.006

Version Description

= 7.3.13 =

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

Release Info

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

Code changes from version 7.3.13.005 to 7.3.13.006

changelog.txt CHANGED
@@ -4,23 +4,23 @@ WP Photo Album Plus Changelog
4
 
5
  * Various security fixes.
6
  * The nesting level on the album admin page will now only show up when you use the max level limitation in Table VII-B1.0, i.e. the value <> 99.
7
- * You can now add some iptc tags as default for the photo custom datafields.
8
- They will be filled in with the corresponding data at upload/import if available.
9
  For backward compatibility, Table VII-B4,2: Apply New Photodesc, will also fill in the data for existing items if available.
10
 
11
  = 7.3.12 =
12
 
13
  * The cursor on album cover images where cover type is imagefactory(-mcr) and the link is lightbox,
14
  does not change from wait to magnifier when the initialisation of lightbox is complete. Fixed.
15
- * Changes to the cover image selection method: Added 'according to photo sequence'
16
- to the album cover image selection on the album admin and on the settings page;
17
  Added '--- default --- See Table IV-D2' to the cover image selection box on the album admin page.
18
- These changes make it simpler to change the selection method for all -default- albums at once,
19
  provided that the settings on the album admin pages are set to the default, previously being random.
20
  * The album and parent attributes in the wppa shortcodes with type="acount" and type="pcount" can now also be an album enumeration.
21
  * Added class wppa-thumbarea-albdesc for album description on thmbnail area.
22
  * If there is no posterfile for a pdf, there will now be a dummy image as thumbnail, derived from ../uploads/wppa/documentstub.png.
23
- * When the status of a photo is private, it will no longer show up in the topten widget for users not being logged in.
24
  In this case one should not cache the widget.
25
  * If Table IX-D19 and IX-D20 are both unticked, there will now also be no check for utf-8 encoding on filenames during upload/import.
26
 
4
 
5
  * Various security fixes.
6
  * The nesting level on the album admin page will now only show up when you use the max level limitation in Table VII-B1.0, i.e. the value <> 99.
7
+ * You can now add some exif/iptc tags as default for the photo custom datafields.
8
+ They will be filled in with the corresponding data at upload/import if available.
9
  For backward compatibility, Table VII-B4,2: Apply New Photodesc, will also fill in the data for existing items if available.
10
 
11
  = 7.3.12 =
12
 
13
  * The cursor on album cover images where cover type is imagefactory(-mcr) and the link is lightbox,
14
  does not change from wait to magnifier when the initialisation of lightbox is complete. Fixed.
15
+ * Changes to the cover image selection method: Added 'according to photo sequence'
16
+ to the album cover image selection on the album admin and on the settings page;
17
  Added '--- default --- See Table IV-D2' to the cover image selection box on the album admin page.
18
+ These changes make it simpler to change the selection method for all -default- albums at once,
19
  provided that the settings on the album admin pages are set to the default, previously being random.
20
  * The album and parent attributes in the wppa shortcodes with type="acount" and type="pcount" can now also be an album enumeration.
21
  * Added class wppa-thumbarea-albdesc for album description on thmbnail area.
22
  * If there is no posterfile for a pdf, there will now be a dummy image as thumbnail, derived from ../uploads/wppa/documentstub.png.
23
+ * When the status of a photo is private, it will no longer show up in the topten widget for users not being logged in.
24
  In this case one should not cache the widget.
25
  * If Table IX-D19 and IX-D20 are both unticked, there will now also be no check for utf-8 encoding on filenames during upload/import.
26
 
readme.txt CHANGED
@@ -2,7 +2,7 @@
2
  Contributors: opajaap
3
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=OpaJaap@OpaJaap.nl&item_name=WP-Photo-Album-Plus&item_number=Support-Open-Source&currency_code=USD&lc=US
4
  Tags: photo, album, slideshow, video, audio, lightbox, iptc, exif, cloudinary, fotomoto, imagemagick, pdf
5
- Version: 7.3.13.005
6
  Stable tag: 7.3.12.008
7
  Author: J.N. Breetvelt
8
  Author URI: http://www.opajaap.nl/
2
  Contributors: opajaap
3
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=OpaJaap@OpaJaap.nl&item_name=WP-Photo-Album-Plus&item_number=Support-Open-Source&currency_code=USD&lc=US
4
  Tags: photo, album, slideshow, video, audio, lightbox, iptc, exif, cloudinary, fotomoto, imagemagick, pdf
5
+ Version: 7.3.13.006
6
  Stable tag: 7.3.12.008
7
  Author: J.N. Breetvelt
8
  Author URI: http://www.opajaap.nl/
wppa-exif-iptc-common.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * exif and iptc common functions
6
- * Version 7.3.06
7
  *
8
  *
9
  */
@@ -82,7 +82,7 @@ global $wppa_iptc_cache;
82
  // Remove untranslated
83
  $pos = strpos($temp, '2#');
84
  while ( $pos !== false ) {
85
- $tmp = substr($temp, 0, $pos).__('n.a.', 'wp-photo-album-plus').substr($temp, $pos+5);
86
  $temp = $tmp;
87
  $pos = strpos($temp, '2#');
88
  }
@@ -4297,7 +4297,7 @@ static $labels;
4297
  }
4298
  }
4299
 
4300
- return __( 'N.A.', 'wp-photo-album-plus' );
4301
  }
4302
 
4303
  // Get gps data from photofile
3
  * Package: wp-photo-album-plus
4
  *
5
  * exif and iptc common functions
6
+ * Version 7.3.13
7
  *
8
  *
9
  */
82
  // Remove untranslated
83
  $pos = strpos($temp, '2#');
84
  while ( $pos !== false ) {
85
+ $tmp = substr($temp, 0, $pos).__( 'n.a.', 'wp-photo-album-plus' ).substr($temp, $pos+5);
86
  $temp = $tmp;
87
  $pos = strpos($temp, '2#');
88
  }
4297
  }
4298
  }
4299
 
4300
+ return __( 'n.a.', 'wp-photo-album-plus' );
4301
  }
4302
 
4303
  // Get gps data from photofile
wppa-import.php CHANGED
@@ -868,7 +868,7 @@ global $wppa_session;
868
  }
869
  echo
870
  '<img src="' . esc_url( $img_url ) . '"' .
871
- ' alt="N.A."' .
872
  ' style="max-height:48px;"' .
873
  ' onmouseover="if (jQuery(\'#wppa-zoom\').attr(\'checked\')) jQuery(this).css(\'max-height\', \'144px\')"' .
874
  ' onmouseout="if (jQuery(\'#wppa-zoom\').attr(\'checked\')) jQuery(this).css(\'max-height\', \'48px\')"' .
868
  }
869
  echo
870
  '<img src="' . esc_url( $img_url ) . '"' .
871
+ ' alt="' . esc_attr( __( 'n.a.', 'wp-photo-album-plus' ) ) . '"' .
872
  ' style="max-height:48px;"' .
873
  ' onmouseover="if (jQuery(\'#wppa-zoom\').attr(\'checked\')) jQuery(this).css(\'max-height\', \'144px\')"' .
874
  ' onmouseout="if (jQuery(\'#wppa-zoom\').attr(\'checked\')) jQuery(this).css(\'max-height\', \'48px\')"' .
wppa-items.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * Contains functions to retrieve album and photo items
6
- * Version 7.3.09
7
  *
8
  */
9
 
@@ -377,6 +377,23 @@ function wppa_translate_photo_keywords( $id, $text ) {
377
  $result = str_replace( 'w#albumdesc', wppa_get_album_desc( $thumb['album'] ), $result );
378
  $result = str_replace( 'w#albumid', $thumb['album'], $result );
379
  $result = str_replace( 'w#owner', wppa_bp_userlink( $thumb['owner'] ), $result );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
380
  $keywords = array( 'name', 'filename', 'id', 'tags', 'views', 'album', 'dlcount' );
381
  foreach ( $keywords as $keyword ) {
382
  $replacement = __( trim( stripslashes( $thumb[$keyword] ) ) , 'wp-photo-album-plus');
@@ -434,9 +451,9 @@ function wppa_translate_photo_keywords( $id, $text ) {
434
  $result = str_replace( 'w#amfs', $amxy['s'], $result );
435
  }
436
  else {
437
- $result = str_replace( 'w#amx', 'N.a.', $result );
438
- $result = str_replace( 'w#amy', 'N.a.', $result );
439
- $result = str_replace( 'w#amfs', 'N.a.', $result );
440
  }
441
  }
442
 
@@ -480,7 +497,7 @@ function wppa_translate_photo_keywords( $id, $text ) {
480
  $result = str_replace( 'w#duration', sprintf( '%s&#39;%s&#34;.', $mins, $secs ), $result );
481
  }
482
  else {
483
- $result = str_replace( 'w#duration', __( 'N.A.', 'wp-photo-album-plus' ), $result );
484
  }
485
  }
486
  return $result;
3
  * Package: wp-photo-album-plus
4
  *
5
  * Contains functions to retrieve album and photo items
6
+ * Version 7.3.13
7
  *
8
  */
9
 
377
  $result = str_replace( 'w#albumdesc', wppa_get_album_desc( $thumb['album'] ), $result );
378
  $result = str_replace( 'w#albumid', $thumb['album'], $result );
379
  $result = str_replace( 'w#owner', wppa_bp_userlink( $thumb['owner'] ), $result );
380
+ if ( $thumb['location'] && strpos( $result, 'w#gpx' ) !== false ) {
381
+ $geo = explode( '/', $thumb['location'] );
382
+ $loc = str_replace( '&deg;', '<sup>o</sup>', $geo['0'].' '.$geo['1'] );
383
+ $result = str_replace( 'w#gpx', htmlspecialchars( $loc ), $result );
384
+ }
385
+ if ( strpos( $result, 'w#mime' ) !== false ) {
386
+ $source = wppa_get_source_path( $id );
387
+ if ( file_exists( $source ) ) {
388
+ $mime = mime_content_type( $source );
389
+ }
390
+ else {
391
+ $mime = __( 'n.a.', 'wp-photo-album-plus' );
392
+ }
393
+ $result = str_replace( 'w#mime', $mime, $result );
394
+ }
395
+ $result = str_replace( 'w#gpx', htmlspecialchars( $thumb['location'] ), $result );
396
+ $result = str_replace( 'w#exifdtm', $thumb['exifdtm'], $result );
397
  $keywords = array( 'name', 'filename', 'id', 'tags', 'views', 'album', 'dlcount' );
398
  foreach ( $keywords as $keyword ) {
399
  $replacement = __( trim( stripslashes( $thumb[$keyword] ) ) , 'wp-photo-album-plus');
451
  $result = str_replace( 'w#amfs', $amxy['s'], $result );
452
  }
453
  else {
454
+ $result = str_replace( 'w#amx', __( 'n.a.', 'wp-photo-album-plus' ), $result );
455
+ $result = str_replace( 'w#amy', __( 'n.a.', 'wp-photo-album-plus' ), $result );
456
+ $result = str_replace( 'w#amfs', __( 'n.a.', 'wp-photo-album-plus' ), $result );
457
  }
458
  }
459
 
497
  $result = str_replace( 'w#duration', sprintf( '%s&#39;%s&#34;.', $mins, $secs ), $result );
498
  }
499
  else {
500
+ $result = str_replace( 'w#duration', __( 'n.a.', 'wp-photo-album-plus' ), $result );
501
  }
502
  }
503
  return $result;
wppa-links.php CHANGED
@@ -3,7 +3,7 @@
3
  * Package: wp-photo-album-plus
4
  *
5
  * Frontend links
6
- * Version 7.3.09
7
  */
8
 
9
  if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
@@ -100,7 +100,7 @@ global $wppa_locale;
100
  else $pl .= 'debug='.wppa( 'debug' ).'&amp;';
101
  }
102
 
103
- if ( wppa_opt( 'add_locale' ) ) {
104
  if ( $key == 'js' ) $pl .= 'wppalocale=' . $wppa_locale . '&';
105
  else $pl .= 'wppalocale=' . $wppa_locale . '&amp;';
106
  }
3
  * Package: wp-photo-album-plus
4
  *
5
  * Frontend links
6
+ * Version 7.3.13
7
  */
8
 
9
  if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
100
  else $pl .= 'debug='.wppa( 'debug' ).'&amp;';
101
  }
102
 
103
+ if ( wppa_switch( 'add_locale' ) ) {
104
  if ( $key == 'js' ) $pl .= 'wppalocale=' . $wppa_locale . '&';
105
  else $pl .= 'wppalocale=' . $wppa_locale . '&amp;';
106
  }
wppa-photo-admin-autosave.php CHANGED
@@ -3592,16 +3592,16 @@ function wppa_fe_edit_new_style( $photo ) {
3592
  $types = array( 'text',
3593
  'textarea',
3594
  'text',
3595
- 'text',
3596
- 'text',
3597
- 'text',
3598
- 'text',
3599
- 'text',
3600
- 'text',
3601
- 'text',
3602
- 'text',
3603
- 'text',
3604
- 'text',
3605
  );
3606
  $doit = array( wppa_switch( 'fe_edit_name' ),
3607
  wppa_switch( 'fe_edit_desc' ),
3592
  $types = array( 'text',
3593
  'textarea',
3594
  'text',
3595
+ ( wppa_opt( 'custom_default_0' ) == 'multi' ? 'textarea' : 'text' ),
3596
+ ( wppa_opt( 'custom_default_1' ) == 'multi' ? 'textarea' : 'text' ),
3597
+ ( wppa_opt( 'custom_default_2' ) == 'multi' ? 'textarea' : 'text' ),
3598
+ ( wppa_opt( 'custom_default_3' ) == 'multi' ? 'textarea' : 'text' ),
3599
+ ( wppa_opt( 'custom_default_4' ) == 'multi' ? 'textarea' : 'text' ),
3600
+ ( wppa_opt( 'custom_default_5' ) == 'multi' ? 'textarea' : 'text' ),
3601
+ ( wppa_opt( 'custom_default_6' ) == 'multi' ? 'textarea' : 'text' ),
3602
+ ( wppa_opt( 'custom_default_7' ) == 'multi' ? 'textarea' : 'text' ),
3603
+ ( wppa_opt( 'custom_default_8' ) == 'multi' ? 'textarea' : 'text' ),
3604
+ ( wppa_opt( 'custom_default_9' ) == 'multi' ? 'textarea' : 'text' ),
3605
  );
3606
  $doit = array( wppa_switch( 'fe_edit_name' ),
3607
  wppa_switch( 'fe_edit_desc' ),
wppa-settings-autosave.php CHANGED
@@ -3409,6 +3409,7 @@ global $wppa_supported_camara_brands;
3409
  'City',
3410
  'State',
3411
  'Country',
 
3412
  );
3413
 
3414
  $vals = array( '',
@@ -3419,6 +3420,7 @@ global $wppa_supported_camara_brands;
3419
  '2#090',
3420
  '2#095',
3421
  '2#101',
 
3422
  );
3423
 
3424
  for ( $i = '0'; $i < '10'; $i++ ) {
3409
  'City',
3410
  'State',
3411
  'Country',
3412
+ '--- multiline ---',
3413
  );
3414
 
3415
  $vals = array( '',
3420
  '2#090',
3421
  '2#095',
3422
  '2#101',
3423
+ 'multi',
3424
  );
3425
 
3426
  for ( $i = '0'; $i < '10'; $i++ ) {
wppa-utils.php CHANGED
@@ -2243,9 +2243,10 @@ function wppa_set_default_custom( $id ) {
2243
  $i = 0;
2244
  while ( $i < 10 ) {
2245
  $data = $custom[$i];
2246
- if ( ! $data ) {
2247
  $data = wppa_opt( 'custom_default_' . $i, '' );
2248
  $new_data = wppa_filter_iptc( $data, $id );
 
2249
  if ( $new_data != $data ) {
2250
  $custom[$i] = $new_data;
2251
  $any = true;
2243
  $i = 0;
2244
  while ( $i < 10 ) {
2245
  $data = $custom[$i];
2246
+ if ( ! $data || $data == __( 'n.a.', 'wp-photo-album-plus' ) ) {
2247
  $data = wppa_opt( 'custom_default_' . $i, '' );
2248
  $new_data = wppa_filter_iptc( $data, $id );
2249
+ $new_data = wppa_filter_exif( $new_data, $id );
2250
  if ( $new_data != $data ) {
2251
  $custom[$i] = $new_data;
2252
  $any = true;
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: 7.3.13.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_revno; $wppa_revno = '7313'; // WPPA db version
27
- global $wppa_api_version; $wppa_api_version = '7.3.13.005'; // WPPA software version
28
 
29
  /* Init page js data */
30
  global $wppa_js_page_data; $wppa_js_page_data = '';
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: 7.3.13.006
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_revno; $wppa_revno = '7313'; // WPPA db version
27
+ global $wppa_api_version; $wppa_api_version = '7.3.13.006'; // WPPA software version
28
 
29
  /* Init page js data */
30
  global $wppa_js_page_data; $wppa_js_page_data = '';