WP Photo Album Plus - Version 7.2.00.008

Version Description

= 7.2.00 =

  • This version addresses various bug fixes and feature requests.

= 7.1.11 =

  • This version addresses various bug fixes and feature requests.

= 7.1.10 =

  • This version addresses various bug fixes and feature requests.

= 7.1.09 =

  • This version addresses various bug fixes and feature requests.

= 7.1.08 =

  • This version addresses various bug fixes and feature requests.

= 7.1.07 =

  • This version addresses various bug fixes and feature requests.

= 7.1.06 =

  • This version addresses various bug fixes and feature requests.

= 7.1.05 =

  • This version addresses various security issues.
  • This version addresses various bug fixes.

= 7.1.04 =

  • This version addresses various bug fixes.

= 7.1.03 =

  • This version addresses various security issues.
  • This version addresses various bug fixes.

= 7.1.02 =

  • This version addresses various security issues.
  • This version addresses various bug fixes and feature requests.

= 7.1.01 =

  • This version addresses various bug fixes and feature requests.

= 7.1.00 =

  • This version addresses various bug fixes and feature requests.
  • The Photo Album -> Upload Photos and Import Photos admin pages have been substantially improved. Read the changelog for details.

= 7.0.11 =

  • This version addresses various bug fixes and feature requests.

= 7.0.11 =

  • This version addresses various bug fixes

= 7.0.10 =

  • This version addresses various bug fixes

= 7.0.09 =

  • This version addresses various security issues.
  • This version addresses various bug fixes and feature requests.

= 7.0.08 =

  • This version addresses various security issues.
  • This version addresses various bug fixes

= 7.0.07 =

  • This version addresses various security issues.
  • This version addresses various bug fixes

= 7.0.06 =

  • This version addresses various bug fixes
  • This version addresses various security issues.

= 7.0.05 =

  • This version addresses various minor bug fixes and feature requests.
  • This version addresses various security issues.

= 7.0.04 =

  • This version addresses various bug fixes
  • This version addresses various security issues.

= 7.0.03 =

  • This version addresses various minor bug fixes and feature requests.

= 7.0.02 =

  • This version addresses various bug fixes
  • This version addresses various security issues.

= 7.0.01 =

  • This version addresses various minor bug fixes and feature requests.

= 7.0.00 =

  • Shortcode generators for Gutenberg added.
  • This version addresses various minor bug fixes and feature requests.
  • This version addresses various security issues.
  • To prevent spamming and give the users the opportunity to decide when they want us to email them, the mailing system has been revised. Configure Table IX-M to enable various mailing lists, and use the WPPA+ Notify widget for full user flexibility.

= 6.9.21 =

  • This version addresses various bug fixes
  • This version addresses various security issues.

= 6.9.20 =

  • This version addresses various bug fixes

= 6.9.19 =

  • This version addresses various minor bug fixes

= 6.9.18 =

  • This version addresses various minor bug fixes

= 6.9.17 =

  • This version addresses various minor bug fixes and feature requests.
  • This version addresses various security issues.

= 6.9.16 =

  • This version addresses various minor bug fixes and feature requests.
  • This version addresses various security issues.

= 6.9.15 =

  • This version addresses various minor bug fixes and feature requests.
  • This version addresses various security issues.

= 6.9.14 =

  • This version addresses various minor bug fixes and feature requests.
  • This version addresses various security issues.

= 6.9.13 =

  • Security release.

= 6.9.12 =

  • This version addresses various minor bug fixes and performance improvements.

= 6.9.11 =

  • This version addresses various minor bug fixes and performance improvements.

= 6.9.10 =

  • This version addresses various minor bug fixes and performance improvements.

= 6.9.09 =

  • Panorama support phase III.

= 6.9.08 =

  • This version addresses various minor bug fixes and feature requests.
  • Panorama support phase II.

= 6.9.07 =

  • This version addresses various minor bug fixes and feature requests.
  • Panorama support phase I.

= 6.9.06 =

  • This version addresses various minor bug fixes and feature requests.

= 6.9.05 =

  • This version addresses various minor bug fixes and feature requests.

= 6.9.04 =

  • This version addresses various minor bug fixes and feature requests.
  • Local CDN functionality has been added.

= 6.9.03 =

  • This version addresses various minor bug fixes and feature requests.

= 6.9.02 =

  • This version addresses various minor bug fixes and feature requests.

= 6.9.01 =

  • This version addresses various minor bug fixes and feature requests.

= 6.9.00 =

  • This version includes the code for the privacy policy requirements.

= 6.8.09

  • This version addresses various bug fixes and code edits.

= 6.8.08 =

  • This version addresses various minor bug fixes and feature requests.
  • This version offers substantial performance improvements when the box in Table IV-A13: Defer Javascript is ticked. This setting is now recommended and set ticked as the default.
  • For more info on performance improvements and compatibility with optimizers: see the changelog.txt

= 6.8.07 =

  • This version addresses various minor bug fixes and enhancements, and a new widget: Statistics.

= 6.8.06 =

  • This version addresses various minor bug fixes and improved cache handling.

= 6.8.05 =

  • This version addresses various minor bug fixes and feture requests.

= 6.8.04 =

  • This version addresses various display issues and a few fixes of bugs that seldom affected the plugins behaviour.
Download this release

Release Info

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

Code changes from version 7.1.11.008 to 7.2.00.008

changelog.txt CHANGED
@@ -1,5 +1,19 @@
1
WP Photo Album Plus Changelog
2
3
= 7.1.11 =
4
5
* Added a dummy row to the masonry horizontal thumbnail display to enable custom css to fix specific pluging conflicts.
1
WP Photo Album Plus Changelog
2
3
+ = 7.2.00 =
4
+
5
+ * Changed defaults for Table IX-D19 and IX-D20 as this seems to be the most convenient.
6
+ * The mailing of frontload upload notifications will now combine multiple photos in one notification email for photos that have the same owner and are in the same album,
7
+ and the uploads have been done during a period of max 5 minutes.
8
+ * For users who can create (sub) albums, the uplaod widget and the box created by [wppa type="upload"] will now show a selectionbox of parents where the user can create a subalbum.
9
+ The selectionbox may contain --- none --- and --- separate --- if the user can create toplevel albums.
10
+ * The number of downloads as enabled in Table VI-C1.x is now registered.
11
+ * Added w#dlcount as photo description keyword to display the download count.
12
+ * Added display and sort method 'Download count' to the TopTen widget.
13
+ * For lightbox, multiple single images will now be treated as a set, so you can browse through them.
14
+ There will be separate sets for the three single image types 'photo', 'mphoto' and 'xphoto'.
15
+ * Fixed some ssl issues.
16
+
17
= 7.1.11 =
18
19
* Added a dummy row to the masonry horizontal thumbnail display to enable custom css to fix specific pluging conflicts.
js/wppa.js CHANGED
@@ -1,14 +1,35 @@
1
// wppa.js
2
//
3
- // conatins common vars and functions
4
//
5
- var wppaJsVersion = '7.1.06';
6
7
// Important notice:
8
// All external vars that may be given a value in wppa-non-admin.php must be declared here and not in other front-end js files!!
9
// This will prevent overwriting with default values in case defereed js is activated
10
-
11
- // 'External' variables ( public )
12
var wppaVersion = '0';
13
var wppaIsIe = false;
14
var wppaUseSvg = true;
@@ -34,24 +55,8 @@ var wppaFilmStripAreaDelta = [];
34
var wppaFilmShowGlue = false;
35
var wppaIsMini = [];
36
var wppaPortraitOnly = [];
37
- var wppaSlideShow; // = 'Slideshow' or its translation
38
- var wppaPhoto; // = 'Photo' or its translation
39
- var wppaOf; // = 'of' or its translation
40
- var wppaNextPhoto; // = 'Next photo' or its translation
41
- var wppaPreviousPhoto; // = 'Previous photo' or its translation
42
- var wppaNextP;
43
- var wppaPrevP;
44
- var wppaAvgRating;
45
- var wppaMyRating;
46
- var wppaAvgRat;
47
- var wppaMyRat;
48
- var wppaDislikeMsg;
49
var wppaMiniTreshold = 300;
50
- var wppaStart = 'Start'; // defaults
51
- var wppaStop = 'Stop'; //
52
- var wppaPleaseName;
53
- var wppaPleaseEmail;
54
- var wppaPleaseComment;
55
var wppaRatingOnce = true;
56
var wppaBGcolorNumbar = 'transparent';
57
var wppaBcolorNumbar = 'transparent';
@@ -126,13 +131,12 @@ var wppaFirstOccur = 0;
126
var wppaUsePhotoNamesInUrls = false;
127
var wppaShareHideWhenRunning = false;
128
var wppaCommentRequiredAfterVote = true;
129
- var wppaTopMoc = 0; // Set by wppa_functions.php -> function wppa_container( 'open' );
130
- if ( ! wppaColWidth ) var wppaColWidth = []; // [mocc] Set by wppa_functions.php -> function wppa_container( 'open' );
131
if ( ! wppaMCRWidth ) var wppaMCRWidth = [];
132
var wppaFotomotoHideWhenRunning = false; // Set by wppa-non-admin.php -> wppa_create_wppa_init_js();
133
var wppaFotomotoMinWidth = 400; // Set by wppa-non-admin.php -> wppa_create_wppa_init_js();
134
var wppaPhotoView = []; // [id] Set to true by a bump viewcount to prevent duplicate bumps.
135
-
136
var wppaBackgroundColorImage = '';
137
var wppaPopupLinkType = '';
138
var wppaPopupOnclick = [];
@@ -152,10 +156,6 @@ var wppaCoverImageResponsive = [];
152
var wppaSearchBoxSelItems = [];
153
var wppaSlideWrap = [];
154
var wppaHideRightClick = false;
155
- var wppaProcessing = 'Processing...';
156
- var wppaDone = 'Done!';
157
- var wppaUploadFailed = 'Upload failed';
158
- var wppaServerError = 'Server error';
159
var wppaGeoZoom = 10;
160
var wppaLazyLoad = true;
161
var wppaAreaMaxFrac = 1.0;
@@ -291,7 +291,7 @@ function wppaDoInit() {
291
setTimeout( function() {
292
var i = 1;
293
while( i < wppaTopMoc ) {
294
- if ( jQuery( '#ubb-'+i+'-l' ) ) {
295
wppaUbb(i,'l','hide');
296
wppaUbb(i,'r','hide');
297
}
@@ -336,7 +336,7 @@ var wppaDoAllAutocolsLastI = 0;
336
// Do the auto cols
337
function wppaDoAllAutocols(i) {
338
339
- if ( typeof(i) != 'number' ) i = 1;
340
else i++;
341
if ( wppaDoAllAutocolsLastI >= i ) {
342
wppaDoAllAutocolsLastI = 0; // reset and wait for new event
@@ -369,10 +369,10 @@ function wppaDoAllAutocols(i) {
369
// If disable right mouseclick
370
function wppaProtect() {
371
if ( wppaHideRightClick ) {
372
- jQuery( 'img' ).bind( 'contextmenu', function(e) {
373
return false;
374
});
375
- jQuery( 'video' ).bind( 'contextmenu', function(e) {
376
return false;
377
});
378
}
@@ -387,7 +387,7 @@ jQuery( document ).ready( function( e ) {
387
}
388
389
// Can we do history.pushState ?
390
- if ( typeof( history.pushState ) != 'undefined' ) {
391
392
// Save entire initial page content ( I do not know which container is going to be modified first )
393
var i=1;
@@ -404,13 +404,13 @@ jQuery( document ).ready( function( e ) {
404
function wppaUpdateLightboxes() {
405
406
// Native wppa lightbox
407
- if ( typeof( wppaInitOverlay ) == 'function' ) {
408
wppaInitOverlay();
409
}
410
411
// Lightbox-3
412
- if ( typeof( myLightbox ) != 'undefined' ) {
413
- if ( typeof( myLightbox.updateImageList ) == 'function' ) {
414
myLightbox.updateImageList();
415
}
416
}
@@ -439,9 +439,9 @@ function wppaStopVideo( mocc ) {
439
if ( i != 1 || mocc == 0 ) { // Stop video on lighbox only when mocc = 0, i.e. stop all video
440
video = document.getElementById( id[i] );
441
if ( video ) {
442
- if ( typeof( video.pause ) == 'function' ) {
443
video.pause();
444
- wppaConsoleLog( 'Video '+id[i]+' paused', 'force' );
445
}
446
}
447
}
@@ -452,7 +452,7 @@ function wppaStopVideo( mocc ) {
452
function wppaStopAudio( mocc ) {
453
454
// This mocc only?
455
- if ( typeof( mocc ) == 'number' ) {
456
if ( jQuery( '#audio-' + mocc ).pause ) {
457
jQuery( '#audio-' + mocc ).pause();
458
}
@@ -461,12 +461,12 @@ function wppaStopAudio( mocc ) {
461
// All audio
462
else {
463
464
- var items = jQuery( 'audio' );
465
466
if ( items.length > 0 ) {
467
var i = 0;
468
while ( i < items.length ) {
469
- if ( jQuery( items[i] ).attr( 'data-from' ) == 'wppa' ) {
470
items[i].pause();
471
}
472
i++;
@@ -494,8 +494,8 @@ var temp2;
494
var j = 0;
495
while ( j < temp2.length ) {
496
var chunk = temp2[j];
497
- var w = chunk.split( '_' );
498
- if ( w[0] != 'w' ) {
499
if ( j != 0 ) url += '/';
500
url += chunk;
501
}
@@ -506,7 +506,7 @@ var temp2;
506
507
// Get the width of a container
508
function wppaGetContainerWidth( mocc ) {
509
- var elm = document.getElementById( 'wppa-container-'+mocc );
510
var w = 0;
511
512
if ( ! wppaAutoColumnWidth[mocc] ) return elm.clientWidth;
@@ -545,7 +545,7 @@ function _wppaDoAutocol( mocc, i ) {
545
// Adjust container, only if it differs from current width
546
if ( ! wppaRenderModal ) {
547
old = jQuery( "#wppa-container-"+mocc ).width();
548
- // wppaConsoleLog( 'container old='+old+', new='+w, 'force' );
549
if ( w != old ) {
550
if ( wppaResponseSpeed == 0 ) {
551
jQuery( ".wppa-container-"+mocc ).css( {width:w} );
@@ -556,10 +556,10 @@ function _wppaDoAutocol( mocc, i ) {
556
}
557
}
558
else {
559
- old = jQuery( ".ui-dialog" ).css( 'width' );
560
if ( parseInt( w ) != parseInt( old ) ) {
561
- jQuery( ".ui-dialog" ).css( 'width', w );
562
- jQuery( ".ui-dialog" ).attr( 'height', 'auto' );
563
}
564
}
565
/**/
@@ -586,7 +586,7 @@ function _wppaDoAutocol( mocc, i ) {
586
exists = jQuery( ".wppa-cover-box-mcr-"+mocc );
587
if ( exists.length > 1 ) { // Yes there are
588
589
- var cw = document.getElementById( 'wppa-albumlist-' + mocc ).clientWidth;
590
var nCovers = parseInt( ( cw + 8 )/( wppaMaxCoverWidth+8 ) ) + 1;
591
var coverMax1 = nCovers - 1;
592
var MCRWidth = parseInt( ( ( cw + 8 )/nCovers ) - 8 );
@@ -636,7 +636,7 @@ function _wppaDoAutocol( mocc, i ) {
636
637
// Thumbframes default
638
if ( wppaThumbSpaceAuto ) {
639
- var tfw = parseInt( jQuery( ".thumbnail-frame-"+mocc ).css( 'width' ) );
640
if ( tfw ) {
641
var minspc = wppaMinThumbSpace;
642
var weff = w - wppaThumbnailAreaDelta - 7;
@@ -649,18 +649,18 @@ function _wppaDoAutocol( mocc, i ) {
649
}
650
651
// Comalt thumbmails
652
- jQuery( ".thumbnail-frame-comalt-"+mocc ).css( 'width', w - wppaThumbnailAreaDelta );
653
- jQuery( ".wppa-com-alt-"+mocc ).css( 'width', w - wppaThumbnailAreaDelta - wppaComAltSize - 16 );
654
655
// Masonry thumbnails horizontal
656
var row = 1;
657
var rowHeightPix;
658
- var rowHeightPerc = jQuery( '#wppa-mas-h-'+row+'-'+mocc ).attr( 'data-height-perc' );
659
while ( rowHeightPerc ) {
660
rowHeightPix = rowHeightPerc * ( w - wppaThumbnailAreaDelta ) / 100;
661
- jQuery( '#wppa-mas-h-'+row+'-'+mocc ).css( 'height', rowHeightPix );
662
row++;
663
- rowHeightPerc = jQuery( '#wppa-mas-h-'+row+'-'+mocc ).attr( 'data-height-perc' );
664
}
665
666
// Fix bug in ie and chrome
@@ -670,18 +670,18 @@ function _wppaDoAutocol( mocc, i ) {
670
wppaFormatSlide( mocc );
671
672
// Audio
673
- jQuery( "#audio-slide-"+mocc ).css( 'width', w - wppaBoxDelta - 6 );
674
675
// Comments
676
- jQuery( ".wppa-comment-textarea-"+mocc ).css( 'width',w * 0.7 );
677
678
// Filmstrip
679
wppaFilmStripLength[mocc] = w - wppaFilmStripAreaDelta[mocc];
680
- jQuery( "#filmwindow-"+mocc ).css( 'width',wppaFilmStripLength[mocc] );
681
_wppaAdjustFilmstrip( mocc ); // reposition content
682
683
// Texts in slideshow and browsebar
684
- if ( ! wppaIsMini[mocc] && typeof( _wppaSlides[mocc] ) != 'undefined' ) { // Mini is properly initialized
685
if ( wppaColWidth[mocc] < wppaMiniTreshold ) {
686
jQuery( '#wppa-avg-rat-'+mocc ).html( wppaAvgRat );
687
jQuery( '#wppa-my-rat-'+mocc ).html( wppaMyRat );
@@ -697,30 +697,30 @@ function _wppaDoAutocol( mocc, i ) {
697
}
698
699
// Single photo
700
- jQuery( ".wppa-sphoto-"+mocc ).css( 'width',w );
701
- jQuery( ".wppa-simg-"+mocc ).css( 'width',w - 2*wppaSlideBorderWidth );
702
- jQuery( ".wppa-simg-"+mocc ).css( 'height', '' );
703
704
// Mphoto
705
- jQuery( ".wppa-mphoto-"+mocc ).css( 'width',w + 10 );
706
- jQuery( ".wppa-mimg-"+mocc ).css( 'width',w );
707
- jQuery( ".wppa-mimg-"+mocc ).css( 'height', '' );
708
709
// smxpdf
710
- jQuery( ".smxpdf-"+mocc ).css( 'height', 0.8 * wppaWindowHeight() );
711
712
// Search box
713
if ( wppaSearchBoxSelItems[mocc] > 0 ) {
714
if ( w / wppaSearchBoxSelItems[mocc] < 125 ) {
715
- jQuery( ".wppa-searchsel-item-"+mocc ).css( 'width', '100%' );
716
}
717
else {
718
- jQuery( ".wppa-searchsel-item-"+mocc ).css( 'width', ( 100 / wppaSearchBoxSelItems[mocc] ) + '%' );
719
}
720
}
721
722
// Upload dialog album selectionbox
723
- jQuery( ".wppa-upload-album-"+mocc ).css( 'maxWidth', 0.6 * w );
724
725
// wppa_div
726
// jQuery('.wppa-divnicewrap').trigger('transitioned');
@@ -739,9 +739,9 @@ function wppaSetMasHorFrameWidthsForIeAndChrome(mocc) {
739
740
var img = wppaGetChildI( frames[i] );
741
if ( img ) {
742
- if ( img.nodeName == 'IMG' ) {
743
if ( ! img.complete ) {
744
- setTimeout( 'wppaSetMasHorFrameWidthsForIeAndChrome( '+mocc+' )', 400 ); // Try again after 400 ms.
745
return;
746
}
747
}
@@ -780,28 +780,28 @@ function fotomoto_loaded() {
780
}
781
function wppaFotomotoToolbar( mocc, url ) {
782
if ( wppaColWidth[mocc] >= wppaFotomotoMinWidth ) { // Space enough to show the toolbar
783
- jQuery( '#wppa-fotomoto-container-'+mocc ).css( 'display','inline' );
784
- jQuery( '#wppa-fotomoto-checkout-'+mocc ).css( 'display','inline' );
785
}
786
else {
787
- jQuery( '#wppa-fotomoto-container-'+mocc ).css( 'display','none' );
788
- jQuery( '#wppa-fotomoto-checkout-'+mocc ).css( 'display','none' );
789
return; // Too small
790
}
791
- if ( wppaFotomoto && document.getElementById( 'wppa-fotomoto-container-'+mocc ) ) { // Configured and container present
792
if ( wppaFotomotoLoaded ) {
793
FOTOMOTO.API.checkinImage( url );
794
- wppaFotomotoToolbarIds[mocc] = FOTOMOTO.API.showToolbar( 'wppa-fotomoto-container-'+mocc, url );
795
}
796
else { // Not loaded yet, retry after 200 ms
797
- setTimeout( 'wppaFotomotoToolbar( '+mocc+',"'+url+'" )', 200 );
798
- wppaConsoleLog( 'Waiting for Fotomoto' );
799
}
800
}
801
}
802
function wppaFotomotoHide( mocc ) {
803
- jQuery( '#wppa-fotomoto-container-'+mocc ).css( 'display','none' );
804
- jQuery( '#wppa-fotomoto-checkout-'+mocc ).css( 'display','none' );
805
}
806
807
// Sanitize utility
@@ -862,11 +862,11 @@ window.onpopstate = function( event ) {
862
/* */
863
}
864
// If it is a slideshow, stop it
865
- if ( document.getElementById( 'theslide0-'+occ ) ) {
866
_wppaStop( occ );
867
}
868
}
869
- if ( typeof( wppaQRUpdate ) != 'undefined' ) wppaQRUpdate( document.location.href );
870
// wppaQRData = document.location.href; //????
871
};
872
@@ -878,10 +878,10 @@ function wppaPushStateSlide( mocc, slide, url ) {
878
if ( url != '' ) {
879
try {
880
history.pushState( {page: wppaHis, occur: mocc, type: 'slide', slide: slide}, "---", url );
881
- wppaConsoleLog( 'Slide history stack updated' );
882
}
883
catch( err ) {
884
- wppaConsoleLog( 'Slide history stack update failed' );
885
}
886
}
887
}
@@ -894,12 +894,12 @@ var temp;
894
var newtext;
895
896
// Just to be sure we do not run into undefined error
897
- if ( typeof( text ) == 'undefined' ) return '';
898
899
- while ( text.indexOf( '[script' ) != -1 ) {
900
text = text.replace( '[script', '<script' );
901
}
902
- while ( text.indexOf( '[/script' ) != -1 ) {
903
text = text.replace( '[/script', '</script' );
904
}
905
@@ -913,7 +913,7 @@ function wppaRepairBrTags( text ) {
913
var newtext;
914
915
// Just to be sure we do not run into undefined error
916
- if ( typeof(text) == 'undefined' ) return '';
917
918
newtext = text;
919
newtext = newtext.replace( '[br /]', '<br />' );
@@ -930,7 +930,7 @@ function wppaTrimAlt( text ) {
930
var newtext;
931
932
// Just to be sure we do not run into undefined error
933
- if ( typeof(text) == 'undefined' ) return '';
934
935
if ( text.length > 13 ) {
936
newtext = text.substr( 0,10 ) + '...';
@@ -943,17 +943,17 @@ var newtext;
943
var wppaFbInitBusy = false;
944
function wppaFbInit() {
945
if ( ! wppaFbInitBusy ) {
946
- if ( typeof( FB ) != 'undefined' ) {
947
wppaFbInitBusy = true; // set busy
948
- setTimeout( '_wppaFbInit()', 10 ); // do it async over 10 ms
949
}
950
else {
951
- wppaConsoleLog( 'Fb wait' );
952
- setTimeout( 'wppaFbInit()', 200 );
953
}
954
}
955
else {
956
- wppaConsoleLog( 'Fb Init busy' );
957
}
958
}
959
function _wppaFbInit() {
@@ -970,7 +970,7 @@ function wppaInsertAtCursor( elm, value ) {
970
sel.text = value;
971
}
972
//MOZILLA and others
973
- else if ( elm.selectionStart || elm.selectionStart == '0' ) {
974
var startPos = elm.selectionStart;
975
var endPos = elm.selectionEnd;
976
elm.value = elm.value.substring( 0, startPos )
@@ -1022,7 +1022,7 @@ function wppaGeoInit( mocc, lat, lon ) {
1022
function wppaEncode( xtext ) {
1023
var text, result;
1024
1025
- if ( typeof( xtext )=='undefined' ) return;
1026
1027
text = String(xtext);
1028
result = text.replace( /#/g, '||HASH||' );
@@ -1099,7 +1099,7 @@ function wppaSuperSearchSelect( mocc, go ) {
1099
data = '';
1100
var i;
1101
for ( i = 0; i < set.length; i++ ) {
1102
- if ( jQuery( set[i] ).attr( 'selected' ) == 'selected' ) {
1103
data += '.' + jQuery( set[i] ).val();
1104
}
1105
}
@@ -1122,7 +1122,7 @@ function wppaSuperSearchSelect( mocc, go ) {
1122
data = '';
1123
var i;
1124
for ( i = 0; i < set.length; i++ ) {
1125
- if ( jQuery( set[i] ).attr( 'selected' ) == 'selected' ) {
1126
data += '.' + jQuery( set[i] ).val();
1127
}
1128
}
@@ -1159,7 +1159,7 @@ function wppaSuperSearchSelect( mocc, go ) {
1159
data = '';
1160
var i;
1161
for ( i=0; i<set.length; i++ ) {
1162
- if ( jQuery( set[i] ).attr( 'selected' ) == 'selected' ) {
1163
data += '.' + jQuery( set[i] ).val();
1164
}
1165
}
@@ -1175,7 +1175,7 @@ function wppaSuperSearchSelect( mocc, go ) {
1175
data = '';
1176
var i;
1177
for ( i=0; i<set.length; i++ ) {
1178
- if ( jQuery( set[i] ).attr( 'selected' ) == 'selected' ) {
1179
data += '.' + jQuery( set[i] ).val();
1180
}
1181
}
@@ -1266,10 +1266,10 @@ function wppaAjaxGetSsIptcList( mocc, s3, selid ) {
1266
jQuery( '#'+selid ).html( result );
1267
jQuery( '#wppa-ss-iptcopts-'+mocc ).css('display', '');
1268
wppaSuperSearchSelect( mocc );
1269
- setTimeout( 'wppaSetIptcExifSize( ".wppa-iptclist-'+mocc+'", "#'+selid+'" )', 10 );
1270
},
1271
error: function( xhr, status, error ) {
1272
- wppaConsoleLog( 'wppaAjaxGetSsIptcList failed. Error = ' + error + ', status = ' + status, 'force' );
1273
},
1274
complete: function( xhr, status, newurl ) {
1275
jQuery( '#wppa-ss-spinner-'+mocc ).css('display', 'none');
@@ -1296,10 +1296,10 @@ function wppaAjaxGetSsExifList( mocc, s3, selid ) {
1296
jQuery( '#'+selid ).html( result );
1297
jQuery( '#wppa-ss-exifopts-'+mocc ).css('display', '');
1298
wppaSuperSearchSelect( mocc );
1299
- setTimeout( 'wppaSetIptcExifSize( ".wppa-exiflist-'+mocc+'", "#'+selid+'" )', 10 );
1300
},
1301
error: function( xhr, status, error ) {
1302
- wppaConsoleLog( 'wppaAjaxGetSsExifList failed. Error = ' + error + ', status = ' + status, 'force' );
1303
},
1304
complete: function( xhr, status, newurl ) {
1305
jQuery( '#wppa-ss-spinner-'+mocc ).css('display', 'none');
@@ -1314,7 +1314,7 @@ function wppaSetIptcExifSize( clas, selid ) {
1314
var n = t.length;
1315
if ( n > 6 ) n = 6;
1316
if ( n < 2 ) n = 2;
1317
- jQuery( selid ).attr( 'size', n );
1318
}
1319
1320
function wppaUpdateSearchRoot( text, root ) {
@@ -1328,12 +1328,12 @@ function wppaUpdateSearchRoot( text, root ) {
1328
i = 0;
1329
while ( i < items.length ) {
1330
if ( root ) {
1331
- jQuery( items[i] ).prop( 'checked', false );
1332
- jQuery( items[i] ).prop( 'disabled', false );
1333
}
1334
else {
1335
- jQuery( items[i] ).prop( 'checked', true );
1336
- jQuery( items[i] ).prop( 'disabled', true );
1337
}
1338
i++;
1339
}
@@ -1346,7 +1346,7 @@ function wppaUpdateSearchRoot( text, root ) {
1346
}
1347
1348
function wppaSubboxChange( elm ) {
1349
- if ( jQuery( elm ).prop( 'checked' ) ) {
1350
jQuery( ".wppa-rootbox" ).each(function(index) {
1351
jQuery(this).prop('checked',true);
1352
});
@@ -1355,7 +1355,7 @@ function wppaSubboxChange( elm ) {
1355
var items = jQuery( ".wppa-rootbox" );
1356
var i = 0;
1357
while ( i < items.length ) {
1358
- jQuery( items[i] ).prop( 'checked', true );
1359
i++;
1360
}
1361
*/
@@ -1372,7 +1372,7 @@ function wppaClearSubsearch() {
1372
items = jQuery( ".wppa-search-sub-box" );
1373
i = 0;
1374
while ( i < items.length ) {
1375
- jQuery( items[i] ).attr( 'disabled', 'disabled' );
1376
i++;
1377
}
1378
}
@@ -1381,7 +1381,7 @@ function wppaEnableSubsearch() {
1381
var items = jQuery( ".wppa-search-sub-box" );
1382
var i = 0;
1383
while ( i < items.length ) {
1384
- jQuery( items[i] ).removeAttr( 'disabled' );
1385
i++;
1386
}
1387
}
@@ -1401,7 +1401,7 @@ function wppaDisplaySelectedFiles(id) {
1401
1402
function wppaIsEmpty( str ) {
1403
if ( str == null ) return true;
1404
- if ( typeof( str ) == 'undefined' ) return true;
1405
if ( str == '' ) return true;
1406
if ( str == false ) return true;
1407
if ( str == 0 ) return true;
@@ -1439,7 +1439,7 @@ function wppaGetUploadOptions( yalb, mocc, where, onComplete ) {
1439
}
1440
else {
1441
jQuery('#message-'+yalb+'-'+mocc).html( '<span style="font-size: 10px;" >'+response.responseText+'</span>' );
1442
- if ( where == 'thumb' || where == 'cover' ) {
1443
eval(onComplete);
1444
}
1445
}
@@ -1455,4 +1455,4 @@ function wppaGetUploadOptions( yalb, mocc, where, onComplete ) {
1455
}
1456
1457
// Say we're in
1458
- wppaConsoleLog( 'wppa.js version '+wppaJsVersion+' loaded.', 'force' );
1
// wppa.js
2
//
3
+ // contains common vars and functions
4
//
5
+ var wppaJsVersion = '7.2.00';
6
+
7
+ // Language dependant vars. i18n for js does not work. Values are filled in by wppa_add_page_specific_urls_and_language() in wppa-non-admin.php
8
+ var wppaSlideShow;
9
+ var wppaPhoto;
10
+ var wppaOf;
11
+ var wppaNextPhoto;
12
+ var wppaPreviousPhoto;
13
+ var wppaNextP;
14
+ var wppaPrevP;
15
+ var wppaAvgRating;
16
+ var wppaMyRating;
17
+ var wppaAvgRat;
18
+ var wppaMyRat;
19
+ var wppaDislikeMsg;
20
+ var wppaStart;
21
+ var wppaStop;
22
+ var wppaPleaseName;
23
+ var wppaPleaseEmail;
24
+ var wppaPleaseComment;
25
+ var wppaProcessing;
26
+ var wppaDone;
27
+ var wppaUploadFailed;
28
+ var wppaServerError;
29
30
// Important notice:
31
// All external vars that may be given a value in wppa-non-admin.php must be declared here and not in other front-end js files!!
32
// This will prevent overwriting with default values in case defereed js is activated
33
var wppaVersion = '0';
34
var wppaIsIe = false;
35
var wppaUseSvg = true;
55
var wppaFilmShowGlue = false;
56
var wppaIsMini = [];
57
var wppaPortraitOnly = [];
58
var wppaMiniTreshold = 300;
59
+
60
var wppaRatingOnce = true;
61
var wppaBGcolorNumbar = 'transparent';
62
var wppaBcolorNumbar = 'transparent';
131
var wppaUsePhotoNamesInUrls = false;
132
var wppaShareHideWhenRunning = false;
133
var wppaCommentRequiredAfterVote = true;
134
+ var wppaTopMoc = 0; // Set by wppa_functions.php -> function wppa_container('open' );
135
+ if ( ! wppaColWidth ) var wppaColWidth = []; // [mocc] Set by wppa_functions.php -> function wppa_container('open' );
136
if ( ! wppaMCRWidth ) var wppaMCRWidth = [];
137
var wppaFotomotoHideWhenRunning = false; // Set by wppa-non-admin.php -> wppa_create_wppa_init_js();
138
var wppaFotomotoMinWidth = 400; // Set by wppa-non-admin.php -> wppa_create_wppa_init_js();
139
var wppaPhotoView = []; // [id] Set to true by a bump viewcount to prevent duplicate bumps.
140
var wppaBackgroundColorImage = '';
141
var wppaPopupLinkType = '';
142
var wppaPopupOnclick = [];
156
var wppaSearchBoxSelItems = [];
157
var wppaSlideWrap = [];
158
var wppaHideRightClick = false;
159
var wppaGeoZoom = 10;
160
var wppaLazyLoad = true;
161
var wppaAreaMaxFrac = 1.0;
291
setTimeout( function() {
292
var i = 1;
293
while( i < wppaTopMoc ) {
294
+ if ( jQuery( '#ubb-'+i+'-l') ) {
295
wppaUbb(i,'l','hide');
296
wppaUbb(i,'r','hide');
297
}
336
// Do the auto cols
337
function wppaDoAllAutocols(i) {
338
339
+ if ( typeof(i) != 'number') i = 1;
340
else i++;
341
if ( wppaDoAllAutocolsLastI >= i ) {
342
wppaDoAllAutocolsLastI = 0; // reset and wait for new event
369
// If disable right mouseclick
370
function wppaProtect() {
371
if ( wppaHideRightClick ) {
372
+ jQuery('img' ).bind('contextmenu', function(e) {
373
return false;
374
});
375
+ jQuery('video' ).bind('contextmenu', function(e) {
376
return false;
377
});
378
}
387
}
388
389
// Can we do history.pushState ?
390
+ if ( typeof( history.pushState ) != 'undefined') {
391
392
// Save entire initial page content ( I do not know which container is going to be modified first )
393
var i=1;
404
function wppaUpdateLightboxes() {
405
406
// Native wppa lightbox
407
+ if ( typeof( wppaInitOverlay ) == 'function') {
408
wppaInitOverlay();
409
}
410
411
// Lightbox-3
412
+ if ( typeof( myLightbox ) != 'undefined') {
413
+ if ( typeof( myLightbox.updateImageList ) == 'function') {
414
myLightbox.updateImageList();
415
}
416
}
439
if ( i != 1 || mocc == 0 ) { // Stop video on lighbox only when mocc = 0, i.e. stop all video
440
video = document.getElementById( id[i] );
441
if ( video ) {
442
+ if ( typeof( video.pause ) == 'function') {
443
video.pause();
444
+ wppaConsoleLog('Video '+id[i]+' paused', 'force' );
445
}
446
}
447
}
452
function wppaStopAudio( mocc ) {
453
454
// This mocc only?
455
+ if ( typeof( mocc ) == 'number') {
456
if ( jQuery( '#audio-' + mocc ).pause ) {
457
jQuery( '#audio-' + mocc ).pause();
458
}
461
// All audio
462
else {
463
464
+ var items = jQuery('audio' );
465
466
if ( items.length > 0 ) {
467
var i = 0;
468
while ( i < items.length ) {
469
+ if ( jQuery( items[i] ).attr('data-from') == 'wppa') {
470
items[i].pause();
471
}
472
i++;
494
var j = 0;
495
while ( j < temp2.length ) {
496
var chunk = temp2[j];
497
+ var w = chunk.split('_' );
498
+ if ( w[0] != 'w') {
499
if ( j != 0 ) url += '/';
500
url += chunk;
501
}
506
507
// Get the width of a container
508
function wppaGetContainerWidth( mocc ) {
509
+ var elm = document.getElementById('wppa-container-'+mocc );
510
var w = 0;
511
512
if ( ! wppaAutoColumnWidth[mocc] ) return elm.clientWidth;
545
// Adjust container, only if it differs from current width
546
if ( ! wppaRenderModal ) {
547
old = jQuery( "#wppa-container-"+mocc ).width();
548
+ // wppaConsoleLog('container old='+old+', new='+w, 'force' );
549
if ( w != old ) {
550
if ( wppaResponseSpeed == 0 ) {
551
jQuery( ".wppa-container-"+mocc ).css( {width:w} );
556
}
557
}
558
else {
559
+ old = jQuery( ".ui-dialog" ).css('width' );
560
if ( parseInt( w ) != parseInt( old ) ) {
561
+ jQuery( ".ui-dialog" ).css('width', w );
562
+ jQuery( ".ui-dialog" ).attr('height', 'auto' );
563
}
564
}
565
/**/
586
exists = jQuery( ".wppa-cover-box-mcr-"+mocc );
587
if ( exists.length > 1 ) { // Yes there are
588
589
+ var cw = document.getElementById('wppa-albumlist-' + mocc ).clientWidth;
590
var nCovers = parseInt( ( cw + 8 )/( wppaMaxCoverWidth+8 ) ) + 1;
591
var coverMax1 = nCovers - 1;
592
var MCRWidth = parseInt( ( ( cw + 8 )/nCovers ) - 8 );
636
637
// Thumbframes default
638
if ( wppaThumbSpaceAuto ) {
639
+ var tfw = parseInt( jQuery( ".thumbnail-frame-"+mocc ).css('width') );
640
if ( tfw ) {
641
var minspc = wppaMinThumbSpace;
642
var weff = w - wppaThumbnailAreaDelta - 7;
649
}
650
651
// Comalt thumbmails
652
+ jQuery( ".thumbnail-frame-comalt-"+mocc ).css('width', w - wppaThumbnailAreaDelta );
653
+ jQuery( ".wppa-com-alt-"+mocc ).css('width', w - wppaThumbnailAreaDelta - wppaComAltSize - 16 );
654
655
// Masonry thumbnails horizontal
656
var row = 1;
657
var rowHeightPix;
658
+ var rowHeightPerc = jQuery( '#wppa-mas-h-'+row+'-'+mocc ).attr('data-height-perc' );
659
while ( rowHeightPerc ) {
660
rowHeightPix = rowHeightPerc * ( w - wppaThumbnailAreaDelta ) / 100;
661
+ jQuery( '#wppa-mas-h-'+row+'-'+mocc ).css('height', rowHeightPix );
662
row++;
663
+ rowHeightPerc = jQuery( '#wppa-mas-h-'+row+'-'+mocc ).attr('data-height-perc' );
664
}
665
666
// Fix bug in ie and chrome
670
wppaFormatSlide( mocc );
671
672
// Audio
673
+ jQuery( "#audio-slide-"+mocc ).css('width', w - wppaBoxDelta - 6 );
674
675
// Comments
676
+ jQuery( ".wppa-comment-textarea-"+mocc ).css('width',w * 0.7 );
677
678
// Filmstrip
679
wppaFilmStripLength[mocc] = w - wppaFilmStripAreaDelta[mocc];
680
+ jQuery( "#filmwindow-"+mocc ).css('width',wppaFilmStripLength[mocc] );
681
_wppaAdjustFilmstrip( mocc ); // reposition content
682
683
// Texts in slideshow and browsebar
684
+ if ( ! wppaIsMini[mocc] && typeof( _wppaSlides[mocc] ) != 'undefined') { // Mini is properly initialized
685
if ( wppaColWidth[mocc] < wppaMiniTreshold ) {
686
jQuery( '#wppa-avg-rat-'+mocc ).html( wppaAvgRat );
687
jQuery( '#wppa-my-rat-'+mocc ).html( wppaMyRat );
697
}
698
699
// Single photo
700
+ jQuery( ".wppa-sphoto-"+mocc ).css('width',w );
701
+ jQuery( ".wppa-simg-"+mocc ).css('width',w - 2*wppaSlideBorderWidth );
702
+ jQuery( ".wppa-simg-"+mocc ).css('height', '' );
703
704
// Mphoto
705
+ jQuery( ".wppa-mphoto-"+mocc ).css('width',w + 10 );
706
+ jQuery( ".wppa-mimg-"+mocc ).css('width',w );
707
+ jQuery( ".wppa-mimg-"+mocc ).css('height', '' );
708
709
// smxpdf
710
+ jQuery( ".smxpdf-"+mocc ).css('height', 0.8 * wppaWindowHeight() );
711
712
// Search box
713
if ( wppaSearchBoxSelItems[mocc] > 0 ) {
714
if ( w / wppaSearchBoxSelItems[mocc] < 125 ) {
715
+ jQuery( ".wppa-searchsel-item-"+mocc ).css('width', '100%' );
716
}
717
else {
718
+ jQuery( ".wppa-searchsel-item-"+mocc ).css('width', ( 100 / wppaSearchBoxSelItems[mocc] ) + '%' );
719
}
720
}
721
722
// Upload dialog album selectionbox
723
+ jQuery( ".wppa-upload-album-"+mocc ).css('maxWidth', 0.6 * w );
724
725
// wppa_div
726
// jQuery('.wppa-divnicewrap').trigger('transitioned');
739
740
var img = wppaGetChildI( frames[i] );
741
if ( img ) {
742
+ if ( img.nodeName == 'IMG') {
743
if ( ! img.complete ) {
744
+ setTimeout('wppaSetMasHorFrameWidthsForIeAndChrome( '+mocc+' )', 400 ); // Try again after 400 ms.
745
return;
746
}
747
}
780
}
781
function wppaFotomotoToolbar( mocc, url ) {
782
if ( wppaColWidth[mocc] >= wppaFotomotoMinWidth ) { // Space enough to show the toolbar
783
+ jQuery( '#wppa-fotomoto-container-'+mocc ).css('display','inline' );
784
+ jQuery( '#wppa-fotomoto-checkout-'+mocc ).css('display','inline' );
785
}
786
else {
787
+ jQuery( '#wppa-fotomoto-container-'+mocc ).css('display','none' );
788
+ jQuery( '#wppa-fotomoto-checkout-'+mocc ).css('display','none' );
789
return; // Too small
790
}
791
+ if ( wppaFotomoto && document.getElementById('wppa-fotomoto-container-'+mocc ) ) { // Configured and container present
792
if ( wppaFotomotoLoaded ) {
793
FOTOMOTO.API.checkinImage( url );
794
+ wppaFotomotoToolbarIds[mocc] = FOTOMOTO.API.showToolbar('wppa-fotomoto-container-'+mocc, url );
795
}
796
else { // Not loaded yet, retry after 200 ms
797
+ setTimeout('wppaFotomotoToolbar( '+mocc+',"'+url+'" )', 200 );
798
+ wppaConsoleLog('Waiting for Fotomoto' );
799
}
800
}
801
}
802
function wppaFotomotoHide( mocc ) {
803
+ jQuery( '#wppa-fotomoto-container-'+mocc ).css('display','none' );
804
+ jQuery( '#wppa-fotomoto-checkout-'+mocc ).css('display','none' );
805
}
806
807
// Sanitize utility
862
/* */
863
}
864
// If it is a slideshow, stop it
865
+ if ( document.getElementById('theslide0-'+occ ) ) {
866
_wppaStop( occ );
867
}
868
}
869
+ if ( typeof( wppaQRUpdate ) != 'undefined') wppaQRUpdate( document.location.href );
870
// wppaQRData = document.location.href; //????
871
};
872
878
if ( url != '' ) {
879
try {
880
history.pushState( {page: wppaHis, occur: mocc, type: 'slide', slide: slide}, "---", url );
881
+ wppaConsoleLog('Slide history stack updated' );
882
}
883
catch( err ) {
884
+ wppaConsoleLog('Slide history stack update failed' );
885
}
886
}
887
}
894
var newtext;
895
896
// Just to be sure we do not run into undefined error
897
+ if ( typeof( text ) == 'undefined') return '';
898
899
+ while ( text.indexOf( '[script') != -1 ) {
900
text = text.replace( '[script', '<script' );
901
}
902
+ while ( text.indexOf( '[/script') != -1 ) {
903
text = text.replace( '[/script', '</script' );
904
}
905
913
var newtext;
914
915
// Just to be sure we do not run into undefined error
916
+ if ( typeof(text) == 'undefined') return '';
917
918
newtext = text;
919
newtext = newtext.replace( '[br /]', '<br />' );
930
var newtext;
931
932
// Just to be sure we do not run into undefined error
933
+ if ( typeof(text) == 'undefined') return '';
934
935
if ( text.length > 13 ) {
936
newtext = text.substr( 0,10 ) + '...';
943
var wppaFbInitBusy = false;
944
function wppaFbInit() {
945
if ( ! wppaFbInitBusy ) {
946
+ if ( typeof( FB ) != 'undefined') {
947
wppaFbInitBusy = true; // set busy
948
+ setTimeout('_wppaFbInit()', 10 ); // do it async over 10 ms
949
}
950
else {
951
+ wppaConsoleLog('Fb wait' );
952
+ setTimeout('wppaFbInit()', 200 );
953
}
954
}
955
else {
956
+ wppaConsoleLog('Fb Init busy' );
957
}
958
}
959
function _wppaFbInit() {
970
sel.text = value;
971
}
972
//MOZILLA and others
973
+ else if ( elm.selectionStart || elm.selectionStart == '0') {
974
var startPos = elm.selectionStart;
975
var endPos = elm.selectionEnd;
976
elm.value = elm.value.substring( 0, startPos )
1022
function wppaEncode( xtext ) {
1023
var text, result;
1024
1025
+ if ( typeof( xtext )=='undefined') return;
1026
1027
text = String(xtext);
1028
result = text.replace( /#/g, '||HASH||' );
1099
data = '';
1100
var i;
1101
for ( i = 0; i < set.length; i++ ) {
1102
+ if ( jQuery( set[i] ).attr('selected') == 'selected') {
1103
data += '.' + jQuery( set[i] ).val();
1104
}
1105
}
1122
data = '';
1123
var i;
1124
for ( i = 0; i < set.length; i++ ) {
1125
+ if ( jQuery( set[i] ).attr('selected') == 'selected') {
1126
data += '.' + jQuery( set[i] ).val();
1127
}
1128
}
1159
data = '';
1160
var i;
1161
for ( i=0; i<set.length; i++ ) {
1162
+ if ( jQuery( set[i] ).attr('selected') == 'selected') {
1163
data += '.' + jQuery( set[i] ).val();
1164
}
1165
}
1175
data = '';
1176
var i;
1177
for ( i=0; i<set.length; i++ ) {
1178
+ if ( jQuery( set[i] ).attr('selected') == 'selected') {
1179
data += '.' + jQuery( set[i] ).val();
1180
}
1181
}
1266
jQuery( '#'+selid ).html( result );
1267
jQuery( '#wppa-ss-iptcopts-'+mocc ).css('display', '');
1268
wppaSuperSearchSelect( mocc );
1269
+ setTimeout('wppaSetIptcExifSize( ".wppa-iptclist-'+mocc+'", "#'+selid+'" )', 10 );
1270
},
1271
error: function( xhr, status, error ) {
1272
+ wppaConsoleLog('wppaAjaxGetSsIptcList failed. Error = ' + error + ', status = ' + status, 'force' );
1273
},
1274
complete: function( xhr, status, newurl ) {
1275
jQuery( '#wppa-ss-spinner-'+mocc ).css('display', 'none');
1296
jQuery( '#'+selid ).html( result );
1297
jQuery( '#wppa-ss-exifopts-'+mocc ).css('display', '');
1298
wppaSuperSearchSelect( mocc );
1299
+ setTimeout('wppaSetIptcExifSize( ".wppa-exiflist-'+mocc+'", "#'+selid+'" )', 10 );
1300
},
1301
error: function( xhr, status, error ) {
1302
+ wppaConsoleLog('wppaAjaxGetSsExifList failed. Error = ' + error + ', status = ' + status, 'force' );
1303
},
1304
complete: function( xhr, status, newurl ) {
1305
jQuery( '#wppa-ss-spinner-'+mocc ).css('display', 'none');
1314
var n = t.length;
1315
if ( n > 6 ) n = 6;
1316
if ( n < 2 ) n = 2;
1317
+ jQuery( selid ).attr('size', n );
1318
}
1319
1320
function wppaUpdateSearchRoot( text, root ) {
1328
i = 0;
1329
while ( i < items.length ) {
1330
if ( root ) {
1331
+ jQuery( items[i] ).prop('checked', false );
1332
+ jQuery( items[i] ).prop('disabled', false );
1333
}
1334
else {
1335
+ jQuery( items[i] ).prop('checked', true );
1336
+ jQuery( items[i] ).prop('disabled', true );
1337
}
1338
i++;
1339
}
1346
}
1347
1348
function wppaSubboxChange( elm ) {
1349
+ if ( jQuery( elm ).prop('checked') ) {
1350
jQuery( ".wppa-rootbox" ).each(function(index) {
1351
jQuery(this).prop('checked',true);
1352
});
1355
var items = jQuery( ".wppa-rootbox" );
1356
var i = 0;
1357
while ( i < items.length ) {
1358
+ jQuery( items[i] ).prop('checked', true );
1359
i++;
1360
}
1361
*/
1372
items = jQuery( ".wppa-search-sub-box" );
1373
i = 0;
1374
while ( i < items.length ) {
1375
+ jQuery( items[i] ).attr('disabled', 'disabled' );
1376
i++;
1377
}
1378
}
1381
var items = jQuery( ".wppa-search-sub-box" );
1382
var i = 0;
1383
while ( i < items.length ) {
1384
+ jQuery( items[i] ).removeAttr('disabled' );
1385
i++;
1386
}
1387
}
1401
1402
function wppaIsEmpty( str ) {
1403
if ( str == null ) return true;
1404
+ if ( typeof( str ) == 'undefined') return true;
1405
if ( str == '' ) return true;
1406
if ( str == false ) return true;
1407
if ( str == 0 ) return true;
1439
}
1440
else {
1441
jQuery('#message-'+yalb+'-'+mocc).html( '<span style="font-size: 10px;" >'+response.responseText+'</span>' );
1442
+ if ( where == 'thumb' || where == 'cover') {
1443
eval(onComplete);
1444
}
1445
}
1455
}
1456
1457
// Say we're in
1458
+ wppaConsoleLog('wppa.js version '+wppaJsVersion+' loaded.', 'force' );
js/wppa.min.js CHANGED
@@ -1 +1 @@
1
- var wppaJsVersion="7.1.06",wppaVersion="0",wppaIsIe=!1,wppaUseSvg=!0,wppaDebug,wppaFullValign=[],wppaFullHalign=[],wppaFullFrameDelta=[],wppaAnimationSpeed,wppaImageDirectory,wppaThumbnailAreaDelta;if(!wppaAutoColumnWidth)var wppaAutoColumnWidth=[];if(!wppaAutoColumnFrac)var wppaAutoColumnFrac=[];var wppaSlideShowTimeOut=2500,wppaFadeInAfterFadeOut=!1,wppaTextFrameDelta=0,wppaBoxDelta=0,wppaPreambule=[],wppaHideWhenEmpty=!1,wppaThumbnailPitch=[],wppaFilmStripLength=[],wppaFilmStripMargin=[],wppaFilmStripAreaDelta=[],wppaFilmShowGlue=!1,wppaIsMini=[],wppaPortraitOnly=[],wppaSlideShow,wppaPhoto,wppaOf,wppaNextPhoto,wppaPreviousPhoto,wppaNextP,wppaPrevP,wppaAvgRating,wppaMyRating,wppaAvgRat,wppaMyRat,wppaDislikeMsg,wppaMiniTreshold=300,wppaStart="Start",wppaStop="Stop",wppaPleaseName,wppaPleaseEmail,wppaPleaseComment,wppaRatingOnce=!0,wppaBGcolorNumbar="transparent",wppaBcolorNumbar="transparent",wppaBGcolorNumbarActive="transparent",wppaBcolorNumbarActive="transparent",wppaFontFamilyNumbar="",wppaFontSizeNumbar="",wppaFontColorNumbar="",wppaFontWeightNumbar="",wppaFontFamilyNumbarActive="",wppaFontSizeNumbarActive="",wppaFontColorNumbarActive="",wppaFontWeightNumbarActive="",wppaNumbarMax="10",wppaAjaxUrl="",wppaLang="",wppaNextOnCallback=!1,wppaStarOpacity=.2,wppaLightBox=[],wppaEmailRequired="required",wppaSlideBorderWidth=0,wppaSlideInitRunning=[],wppaAnimationType="fadeover",wppaSlidePause=[],wppaSlideBlank=[],wppaRatingMax=5,wppaRatingDisplayType="graphic",wppaRatingPrec=2,wppaFilmPageSize=[],wppaAspectRatio=[],wppaFullSize=[],wppaStretch=!1,wppaThumbSpaceAuto=!1,wppaMinThumbSpace=4,wppaMagnifierCursor="",wppaArtMonkyLink="none",wppaAutoOpenComments=!1,wppaUpdateAddressLine=!1,wppaFilmThumbTitle="",wppaClickToView="",wppaUploadUrl="",wppaVoteForMe="",wppaVotedForMe="",wppaSlideSwipe=!0,wppaLightboxSingle=[],wppaMaxCoverWidth=300,wppaDownLoad="Download",wppaSiteUrl="",wppaWppaUrl="",wppaIncludeUrl="",wppaSlideToFullpopup=!1,wppaComAltSize=75,wppaBumpViewCount=!0,wppaBumpClickCount=!1,wppaFotomoto=!1,wppaArtMonkeyButton=!0,wppaShortQargs=!1,wppaOvlHires=!1,wppaMasonryCols=[],wppaVideoPlaying=[],wppaAudioPlaying=[],wppaSlideVideoStart=!1,wppaSlideAudioStart=!1,wppaAudioHeight=28,wppaHis=0,wppaStartHtml=[],wppaCanAjaxRender=!1,wppaCanPushState=!1,wppaAllowAjax=!0,wppaMaxOccur=0,wppaFirstOccur=0,wppaUsePhotoNamesInUrls=!1,wppaShareHideWhenRunning=!1,wppaCommentRequiredAfterVote=!0,wppaTopMoc=0;if(!wppaColWidth)var wppaColWidth=[];if(!wppaMCRWidth)var wppaMCRWidth=[];var wppaFotomotoHideWhenRunning=!1,wppaFotomotoMinWidth=400,wppaPhotoView=[],wppaBackgroundColorImage="",wppaPopupLinkType="",wppaPopupOnclick=[],wppaThumbTargetBlank=!1,wppaRel="rel",wppaEditPhotoWidth="960",wppaThemeStyles="",wppaStickyHeaderHeight=0,wppaRenderModal=!1,wppaModalBgColor="#ffffff",wppaBoxRadius=0,wppaModalQuitImg,wppaUploadEdit="none",wppaPageArg="",wppaSlideshowNavigationType="icons",wppaCoverImageResponsive=[],wppaSearchBoxSelItems=[],wppaSlideWrap=[],wppaHideRightClick=!1,wppaProcessing="Processing...",wppaDone="Done!",wppaUploadFailed="Upload failed",wppaServerError="Server error",wppaGeoZoom=10,wppaLazyLoad=!0,wppaAreaMaxFrac=1,wppaNiceScroll=!1,wppaIconSizeNormal="default",wppaIconSizeSlide=48,wppaIconSizeStars=24,wppaResponseSpeed=500,wppaExtendedResizeCount=0,wppaExtendedResizeDelay=200,_wppaId=[],_wppaAvg=[],_wppaDisc=[],_wppaMyr=[],_wppaVRU=[],_wppaLinkUrl=[],_wppaLinkTitle=[],_wppaLinkTarget=[],_wppaCommentHtml=[],_wppaIptcHtml=[],_wppaExifHtml=[],_wppaToTheSame=!1,_wppaSlides=[],_wppaNames=[],_wppaFullNames=[],_wppaDsc=[],_wppaOgDsc=[],_wppaCurIdx=[],_wppaNxtIdx=[],_wppaTimeOut=[],_wppaSSRuns=[],_wppaFg=[],_wppaTP=[],_wppaIsBusy=[],_wppaFirst=[],_wppaVoteInProgress=!1,_wppaTextDelay,_wppaUrl=[],_wppaSkipRated=[],_wppaLbTitle=[],_wppaStateCount=0,_wppaDidGoto=[],_wppaShareUrl=[],_wppaShareHtml=[],_wppaFilmNoMove=[],_wppaHiresUrl=[],_wppaIsVideo=[],_wppaVideoHtml=[],_wppaAudioHtml=[],_wppaVideoNatWidth=[],_wppaVideoNatHeight=[],_wppaWaitTexts=[],_wppaImageAlt=[],__wppaOverruleRun=!1,wppaOvlUrls,wppaOvlTitles,wppaOvlAlts,wppaOvlIdx=0,wppaOvlFirst=!0,wppaOvlKbHandler="",wppaOvlSizeHandler="",wppaOvlPadTop=5,wppaOvlIsSingle,wppaOvlRunning=!1,wppaOvlVideoHtmls,wppaOvlAudioHtmls,wppaOvlPdfHtmls,wppaOvlVideoNaturalWidths,wppaOvlVideoNaturalHeights,wppaOvlModeInitial="normal",wppaOvlVideoPlaying=!1,wppaOvlAudioPlaying=!1,wppaOvlShowLegenda=!0,wppaOvlShowStartStop=!0,wppaOvlRadius=0,wppaOvlBorderWidth=16,wppaOvlOpen=!1,wppaOvlTxtHeight=36,wppaOvlOpacity=.8,wppaOvlOnclickType="none",wppaOvlTheme="black",wppaOvlAnimSpeed=300,wppaOvlSlideSpeed=3e3,wppaVer4WindowWidth=800,wppaVer4WindowHeight=600,wppaOvlFontFamily="Helvetica",wppaOvlFontSize="10",wppaOvlFontColor="",wppaOvlFontWeight="bold",wppaOvlLineHeight="12",wppaOvlShowCounter=!0,wppaOvlIsVideo=!1,wppaShowLegenda="",wppaOvlFsPhotoId=0,wppaPhotoId=0,wppaOvlVideoStart=!1,wppaOvlAudioStart=!1,wppaLastIptc="",wppaLastExif="",wppaIsMobile=!1,wppaSvgFillcolor="gray",wppaSvgBgcolor="transparent",wppaSvgCornerStyle="light";function wppaDoInit(){_wppaTextDelay=wppaAnimationSpeed,wppaFadeInAfterFadeOut&&(_wppaTextDelay*=2),jQuery(".wppa-ajax-spin").stop().fadeOut(),jQuery(".wppa-ovl-spin").hide(),setTimeout(function(){for(var p=1;p<wppaTopMoc;)jQuery("#ubb-"+p+"-l")&&(wppaUbb(p,"l","hide"),wppaUbb(p,"r","hide")),p++},3e3),jQuery(window).on("DOMContentLoaded load resize orientationchange",wppaDoAllAutocols),jQuery(window).on("DOMContentLoaded load resize scroll wheel",wppaSizeArea),jQuery(window).on("DOMContentLoaded load resize scroll wheel",wppaMakeLazyVisible),jQuery(".wppa-divnicewrap").on("resize scroll wheel",wppaMakeLazyVisible),jQuery(window).trigger("resize"),wppaProtect()}function wppaSizeAutoDiv(){jQuery(".wppa-autodiv").each(function(p){var a=jQuery(window).height(),e=jQuery(this).attr("data-max-height");jQuery(this).css({maxHeight:a*e})})}jQuery(document).ready(function(){wppaDoInit()}),jQuery(document).ready(function(){jQuery(window).on("DOMContentLoaded load resize scroll",wppaSizeAutoDiv)});var wppaDoAllAutocolsLastI=0;function wppaDoAllAutocols(p){if("number"!=typeof p?p=1:p++,!(p<=wppaDoAllAutocolsLastI)){wppaDoAllAutocolsLastI=p,wppaConsoleLog("Doing wppaDoAllAutocols("+p+")");for(var a=1;a<=wppaAutoColumnWidth.length;)wppaAutoColumnWidth[a]&&_wppaDoAutocol(a,p),a++;return wppaMakeLazyVisible(),(p<wppaExtendedResizeCount||-1==wppaExtendedResizeCount)&&setTimeout(function(){wppaDoAllAutocols(p)},wppaExtendedResizeDelay),!0}wppaDoAllAutocolsLastI=0}function wppaProtect(){wppaHideRightClick&&(jQuery("img").bind("contextmenu",function(p){return!1}),jQuery("video").bind("contextmenu",function(p){return!1}))}function wppaUpdateLightboxes(){"function"==typeof wppaInitOverlay&&wppaInitOverlay(),"undefined"!=typeof myLightbox&&"function"==typeof myLightbox.updateImageList&&myLightbox.updateImageList(),jQuery().prettyPhoto&&jQuery("a[rel^='prettyPhoto']").prettyPhoto({deeplinking:!1})}function wppaStopVideo(p){var a,e,t=[];for(t[1]="wppa-overlay-img",t[2]="theimg0-"+p,t[3]="theimg1-"+p,e=0;e<3;)1==++e&&0!=p||(a=document.getElementById(t[e]))&&"function"==typeof a.pause&&(a.pause(),wppaConsoleLog("Video "+t[e]+" paused","force"))}function wppaStopAudio(p){if("number"==typeof p)jQuery("#audio-"+p).pause&&jQuery("#audio-"+p).pause();else{var a=jQuery("audio");if(0<a.length)for(var e=0;e<a.length;)"wppa"==jQuery(a[e]).attr("data-from")&&a[e].pause(),e++}}function wppaMakeFullsizeUrl(p){var a,e;p=(a=(p=p.replace("/thumbs/","/")).split("//"))[1]?(e=a[1].split("/"),a[0]+"//"):(e=a[0].split("/"),"");for(var t=0;t<e.length;){var o=e[t];"w"!=o.split("_")[0]&&(0!=t&&(p+="/"),p+=o),t++}return p}function wppaGetContainerWidth(p){var a=document.getElementById("wppa-container-"+p),e=0;if(!wppaAutoColumnWidth[p])return a.clientWidth;for(;0==e;)a=a.parentNode,e=jQuery(a).width();return parseInt(e*wppaAutoColumnFrac[p])}function _wppaDoAutocol(p,a){if(wppaConsoleLog("Enter auto. mocc = "+p+" retry = "+a),!wppaAutoColumnWidth[p])return!0;var e,t;if(e=jQuery("#wppa-container-"+p).width(),wppaCoverImageResponsive[p]||1<(t=jQuery(".wppa-asym-text-frame-"+p)).length&&(jQuery(t[0]).width(),0==wppaResponseSpeed?(jQuery(".wppa-asym-text-frame-"+p).css({width:e-wppaTextFrameDelta}),jQuery(".wppa-cover-box-"+p).css({width:e})):(jQuery(".wppa-asym-text-frame-"+p).stop().animate({width:e-wppaTextFrameDelta},wppaResponseSpeed),jQuery(".wppa-cover-box-"+p).stop().animate({width:e},wppaResponseSpeed))),1<(t=jQuery(".wppa-cover-box-mcr-"+p)).length){var o=document.getElementById("wppa-albumlist-"+p).clientWidth,r=parseInt((o+8)/(wppaMaxCoverWidth+8))+1,s=r-1,i=parseInt((o+8)/r-8);if(wppaColWidth[p]!=o||wppaMCRWidth[p]!=i){wppaColWidth[p]=o,wppaMCRWidth[p]=i;for(var n=0;n<t.length;){switch(n%r){case 0:jQuery(t[n]).css({marginLeft:"0px",clear:"both",float:"left"});break;case s:jQuery(t[n]).css({marginLeft:"0px",clear:"none",float:"right"});break;default:jQuery(t[n]).css({marginLeft:"8px",clear:"none",float:"left"})}n++}wppaCoverImageResponsive[p]||jQuery(".wppa-asym-text-frame-mcr-"+p).stop().animate({width:i-wppaTextFrameDelta},wppaResponseSpeed),jQuery(t[0]).width(),jQuery(".wppa-cover-box-mcr-"+p).stop().animate({width:i},wppaResponseSpeed)}}else if(1==t.length)if(wppaCoverImageResponsive[p]);else{jQuery(".wppa-asym-text-frame-mcr-"+p).stop().animate({width:e-wppaTextFrameDelta},wppaResponseSpeed);jQuery(".wppa-cover-box-mcr-"+p).css({marginLeft:"0px",float:"left"})}if(wppaThumbSpaceAuto){var w=parseInt(jQuery(".thumbnail-frame-"+p).css("width"));if(w){var l=wppaMinThumbSpace,u=e-wppaThumbnailAreaDelta-7,c=Math.max(1,parseInt(u/(w+l))),d=parseInt(.5+(u-c*w)/(c+1));jQuery(".thumbnail-frame-"+p).css({marginLeft:d})}}jQuery(".thumbnail-frame-comalt-"+p).css("width",e-wppaThumbnailAreaDelta),jQuery(".wppa-com-alt-"+p).css("width",e-wppaThumbnailAreaDelta-wppaComAltSize-16);for(var y,m=1,h=jQuery("#wppa-mas-h-"+m+"-"+p).attr("data-height-perc");h;)y=h*(e-wppaThumbnailAreaDelta)/100,jQuery("#wppa-mas-h-"+m+"-"+p).css("height",y),m++,h=jQuery("#wppa-mas-h-"+m+"-"+p).attr("data-height-perc");return wppaSetMasHorFrameWidthsForIeAndChrome(p),wppaFormatSlide(p),jQuery("#audio-slide-"+p).css("width",e-wppaBoxDelta-6),jQuery(".wppa-comment-textarea-"+p).css("width",.7*e),wppaFilmStripLength[p]=e-wppaFilmStripAreaDelta[p],jQuery("#filmwindow-"+p).css("width",wppaFilmStripLength[p]),_wppaAdjustFilmstrip(p),wppaIsMini[p]||void 0===_wppaSlides[p]||(wppaColWidth[p]<wppaMiniTreshold?(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRat),jQuery("#wppa-my-rat-"+p).html(wppaMyRat),jQuery("#counter-"+p).html(_wppaCurIdx[p]+1+" / "+_wppaSlides[p].length)):(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRating),jQuery("#wppa-my-rat-"+p).html(wppaMyRating),jQuery("#counter-"+p).html(wppaPhoto+" "+(_wppaCurIdx[p]+1)+" "+wppaOf+" "+_wppaSlides[p].length))),jQuery(".wppa-sphoto-"+p).css("width",e),jQuery(".wppa-simg-"+p).css("width",e-2*wppaSlideBorderWidth),jQuery(".wppa-simg-"+p).css("height",""),jQuery(".wppa-mphoto-"+p).css("width",e+10),jQuery(".wppa-mimg-"+p).css("width",e),jQuery(".wppa-mimg-"+p).css("height",""),jQuery(".smxpdf-"+p).css("height",.8*wppaWindowHeight()),0<wppaSearchBoxSelItems[p]&&(e/wppaSearchBoxSelItems[p]<125?jQuery(".wppa-searchsel-item-"+p).css("width","100%"):jQuery(".wppa-searchsel-item-"+p).css("width",100/wppaSearchBoxSelItems[p]+"%")),jQuery(".wppa-upload-album-"+p).css("maxWidth",.6*e),!0}function wppaSetMasHorFrameWidthsForIeAndChrome(p){for(var a=jQuery(".wppa-mas-h-"+p),e=wppaMinThumbSpace,t=0;t<a.length;t++){var o=wppaGetChildI(a[t]);if(o){if("IMG"==o.nodeName&&!o.complete)return void setTimeout("wppaSetMasHorFrameWidthsForIeAndChrome( "+p+" )",400);var r=o.naturalWidth/o.naturalHeight*o.height+e;jQuery(a[t]).css({width:r})}}}function wppaGetChildI(p){var a,e=p.childNodes;for(a=0;a<e.length;a++){var t=e[a];if(t.id&&"i-"==t.id.substr(0,2))return t;var o=wppaGetChildI(t);if(o)return o}return!1}jQuery(document).ready(function(p){if(wppaAllowAjax&&jQuery.ajax&&(wppaCanAjaxRender=!0),void 0!==history.pushState){for(var a=1;a<=wppaMaxOccur;)wppaStartHtml[a]=jQuery("#wppa-container-"+a).html(),a++;wppaCanPushState=!0}});var wppaFotomotoLoaded=!1,wppaFotomotoToolbarIds=[];function fotomoto_loaded(){wppaFotomotoLoaded=!0}function wppaFotomotoToolbar(p,a){if(!(wppaColWidth[p]>=wppaFotomotoMinWidth))return jQuery("#wppa-fotomoto-container-"+p).css("display","none"),void jQuery("#wppa-fotomoto-checkout-"+p).css("display","none");jQuery("#wppa-fotomoto-container-"+p).css("display","inline"),jQuery("#wppa-fotomoto-checkout-"+p).css("display","inline"),wppaFotomoto&&document.getElementById("wppa-fotomoto-container-"+p)&&(wppaFotomotoLoaded?(FOTOMOTO.API.checkinImage(a),wppaFotomotoToolbarIds[p]=FOTOMOTO.API.showToolbar("wppa-fotomoto-container-"+p,a)):(setTimeout("wppaFotomotoToolbar( "+p+',"'+a+'" )',200),wppaConsoleLog("Waiting for Fotomoto")))}function wppaFotomotoHide(p){jQuery("#wppa-fotomoto-container-"+p).css("display","none"),jQuery("#wppa-fotomoto-checkout-"+p).css("display","none")}function wppaStringContainsForbiddenChars(p){for(var a=["?","&","#","/",'"',"'"],e=0;e<a.length;){if(-1!=p.indexOf(a[e]))return!0;e++}return!1}function wppaPushStateSlide(p,a,e){if(!wppaIsMini[p]&&wppaCanPushState&&wppaUpdateAddressLine&&""!=e)try{history.pushState({page:wppaHis,occur:p,type:"slide",slide:a},"---",e),wppaConsoleLog("Slide history stack updated")}catch(p){wppaConsoleLog("Slide history stack update failed")}}function wppaRepairScriptTags(p){if(void 0===p)return"";for(;-1!=p.indexOf("[script");)p=p.replace("[script","<script");for(;-1!=p.indexOf("[/script");)p=p.replace("[/script","</script");return p}function wppaRepairBrTags(p){return void 0===p?"":p.replace("[br /]","<br />").replace("[a","<a").replace("&quot;",'"').replace('"]','">').replace("[/a]","</a>")}function wppaTrimAlt(p){return void 0===p?"":13<p.length?p.substr(0,10)+"...":p}window.onpopstate=function(p){var a=0;if(wppaCanPushState){if(p.state)switch(a=p.state.occur,p.state.type){case"html":jQuery("#wppa-container-"+a).html(p.state.html);break;case"slide":_wppaGoto(a,p.state.slide)}else if(wppaUpdateAddressLine){if(a=wppaFirstOccur,jQuery("#wppa-container-"+a).html(wppaStartHtml[a]),(wppaFirstOccur=0)==a){var e=document.location.href.split("&wppa-occur=");a=parseInt(e[1])}e=document.location.href.split("&wppa-photo=");var t=parseInt(e[1]);if(0<t){for(var o=0;o<_wppaId[a].length&&_wppaId[a][o]!=t;)o++;o<_wppaId[a].length&&_wppaGoto(a,o)}}document.getElementById("theslide0-"+a)&&_wppaStop(a)}"undefined"!=typeof wppaQRUpdate&&wppaQRUpdate(document.location.href)};var wppaFbInitBusy=!1;function wppaFbInit(){wppaFbInitBusy?wppaConsoleLog("Fb Init busy"):"undefined"!=typeof FB?(wppaFbInitBusy=!0,setTimeout("_wppaFbInit()",10)):(wppaConsoleLog("Fb wait"),setTimeout("wppaFbInit()",200))}function _wppaFbInit(){FB.init({status:!0,xfbml:!0}),wppaFbInitBusy=!1}function wppaInsertAtCursor(p,a){if(document.selection)p.focus(),sel=document.selection.createRange(),sel.text=a;else if(p.selectionStart||"0"==p.selectionStart){var e=p.selectionStart,t=p.selectionEnd;p.value=p.value.substring(0,e)+a+p.value.substring(t,p.value.length),p.selectionStart=e+a.length,p.selectionEnd=e+a.length}else p.value+=a}function wppaGeoInit(p,a,e){var t=new google.maps.LatLng(a,e),o={disableDefaultUI:!1,panControl:!1,zoomControl:!0,mapTypeControl:!0,scaleControl:!0,streetViewControl:!0,overviewMapControl:!0,zoom:wppaGeoZoom,center:t},r=new google.maps.Map(document.getElementById("map-canvas-"+p),o),s=new google.maps.Marker({position:t,map:r,title:""});google.maps.event.addListener(r,"center_changed",function(){window.setTimeout(function(){r.panTo(s.getPosition())},1e3)})}function wppaEncode(p){var a;if(void 0!==p){var e=(a=(a=String(p).replace(/#/g,"||HASH||")).replace(/&/g,"||AMP||")).split("+"),t=0;for(a="";t<e.length;)a+=e[t],++t<e.length&&(a+="||PLUS||");return a}}function wppaUrlToId(p){var a=p.split("/wppa/");return 1==a.length&&(a=p.split("/upload/")),1==a.length?0:a=(a=(a=(a=(a=(a=(a=a[1]).split("."))[0].replace("/","")).replace("/","")).replace("/","")).replace("/","")).replace("/","")}function wppaSuperSearchSelect(p,a){jQuery("#wppa-ss-albumopt-"+p).css("display","none"),jQuery("#wppa-ss-albumcat-"+p).css("display","none"),jQuery("#wppa-ss-albumname-"+p).css("display","none"),jQuery("#wppa-ss-albumtext-"+p).css("display","none"),jQuery("#wppa-ss-photoopt-"+p).css("display","none"),jQuery("#wppa-ss-photoname-"+p).css("display","none"),jQuery("#wppa-ss-photoowner-"+p).css("display","none"),jQuery("#wppa-ss-phototag-"+p).css("display","none"),jQuery("#wppa-ss-phototext-"+p).css("display","none"),jQuery("#wppa-ss-photoexif-"+p).css("display","none"),jQuery("#wppa-ss-photoiptc-"+p).css("display","none"),jQuery("#wppa-ss-exifopts-"+p).css("display","none"),jQuery("#wppa-ss-iptcopts-"+p).css("display","none"),jQuery("#wppa-ss-spinner-"+p).css("display","none"),jQuery("#wppa-ss-button-"+p).css("display","none");var e=jQuery("#wppa-ss-pa-"+p).val(),t="",o="",r="";switch(e){case"a":switch(jQuery("#wppa-ss-albumopt-"+p).css("display",""),t=jQuery("#wppa-ss-albumopt-"+p).val()){case"c":jQuery("#wppa-ss-albumcat-"+p).css("display","");var s=jQuery(".wppa-ss-albumcat-"+p);for(r="",i=0;i<s.length;i++)"selected"==jQuery(s[i]).attr("selected")&&(r+="."+jQuery(s[i]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"n":jQuery("#wppa-ss-albumname-"+p).css("display",""),null!=(r=jQuery("#wppa-ss-albumname-"+p).val())&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"t":jQuery("#wppa-ss-albumtext-"+p).css("display","");s=jQuery(".wppa-ss-albumtext-"+p);for(r="",i=0;i<s.length;i++)"selected"==jQuery(s[i]).attr("selected")&&(r+="."+jQuery(s[i]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+p).css("display","")}break;case"p":switch(jQuery("#wppa-ss-photoopt-"+p).css("display",""),t=jQuery("#wppa-ss-photoopt-"+p).val()){case"n":jQuery("#wppa-ss-photoname-"+p).css("display",""),null!=(r=jQuery("#wppa-ss-photoname-"+p).val())&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"o":jQuery("#wppa-ss-photoowner-"+p).css("display",""),null!=(r=jQuery("#wppa-ss-photoowner-"+p).val())&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"g":jQuery("#wppa-ss-phototag-"+p).css("display","");s=jQuery(".wppa-ss-phototag-"+p);for(r="",i=0;i<s.length;i++)"selected"==jQuery(s[i]).attr("selected")&&(r+="."+jQuery(s[i]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"t":jQuery("#wppa-ss-phototext-"+p).css("display","");var i;s=jQuery(".wppa-ss-phototext-"+p);for(r="",i=0;i<s.length;i++)"selected"==jQuery(s[i]).attr("selected")&&(r+="."+jQuery(s[i]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"i":jQuery("#wppa-ss-photoiptc-"+p).css("display",""),(o=jQuery("#wppa-ss-photoiptc-"+p).val())&&(2<o.length&&(o=o.replace("#","H")),""!=o&&(jQuery("#wppa-ss-iptcopts-"+p).css("display",""),wppaLastIptc!=o?(wppaAjaxGetSsIptcList(p,o,"wppa-ss-iptcopts-"+p),wppaLastIptc=o):null!=(r=jQuery("#wppa-ss-iptcopts-"+p).val())&&""!=r&&jQuery("#wppa-ss-button-"+p).css("display","")));break;case"e":jQuery("#wppa-ss-photoexif-"+p).css("display",""),(o=jQuery("#wppa-ss-photoexif-"+p).val())&&(2<o.length&&(o=o.replace("#","H")),""!=o&&(jQuery("#wppa-ss-exifopts-"+p).css("display",""),wppaLastExif!=o?(wppaAjaxGetSsExifList(p,o,"wppa-ss-exifopts-"+p),wppaLastExif=o):null!=(r=jQuery("#wppa-ss-exifopts-"+p).val())&&""!=r&&jQuery("#wppa-ss-button-"+p).css("display","")))}}if(a){var n=jQuery("#wppa-ss-pageurl-"+p).val();-1==n.indexOf("?")?n+="?":n+="&",n+="occur=1&wppa-supersearch="+e+","+t+","+o+","+r,document.location.href=n}}function wppaAjaxGetSsIptcList(t,p,o){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=getssiptclist&tag="+p+"&moccur="+t,async:!0,type:"GET",timeout:1e4,beforeSend:function(p){jQuery("#wppa-ss-spinner-"+t).css("display","")},success:function(p,a,e){jQuery("#"+o).html(p),jQuery("#wppa-ss-iptcopts-"+t).css("display",""),wppaSuperSearchSelect(t),setTimeout('wppaSetIptcExifSize( ".wppa-iptclist-'+t+'", "#'+o+'" )',10)},error:function(p,a,e){wppaConsoleLog("wppaAjaxGetSsIptcList failed. Error = "+e+", status = "+a,"force")},complete:function(p,a,e){jQuery("#wppa-ss-spinner-"+t).css("display","none")}})}function wppaAjaxGetSsExifList(t,p,o){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=getssexiflist&tag="+p+"&moccur="+t,async:!0,type:"GET",timeout:1e4,beforeSend:function(p){jQuery("#wppa-ss-spinner-"+t).css("display","")},success:function(p,a,e){jQuery("#"+o).html(p),jQuery("#wppa-ss-exifopts-"+t).css("display",""),wppaSuperSearchSelect(t),setTimeout('wppaSetIptcExifSize( ".wppa-exiflist-'+t+'", "#'+o+'" )',10)},error:function(p,a,e){wppaConsoleLog("wppaAjaxGetSsExifList failed. Error = "+e+", status = "+a,"force")},complete:function(p,a,e){jQuery("#wppa-ss-spinner-"+t).css("display","none")}})}function wppaSetIptcExifSize(p,a){var e=jQuery(p).length;6<e&&(e=6),e<2&&(e=2),jQuery(a).attr("size",e)}function wppaUpdateSearchRoot(p,a){for(var e=jQuery(".wppa-search-root"),t=0;t<e.length;)jQuery(e[t]).html(p),t++;for(e=jQuery(".wppa-rootbox"),t=0;t<e.length;)a?(jQuery(e[t]).prop("checked",!1),jQuery(e[t]).prop("disabled",!1)):(jQuery(e[t]).prop("checked",!0),jQuery(e[t]).prop("disabled",!0)),t++;for(e=jQuery(".wppa-search-root-id"),t=0;t<e.length;)jQuery(e[t]).val(a),t++}function wppaSubboxChange(p){jQuery(p).prop("checked")&&jQuery(".wppa-rootbox").each(function(p){jQuery(this).prop("checked",!0)})}function wppaClearSubsearch(){for(var p=jQuery(".wppa-display-searchstring"),a=0;a<p.length;)jQuery(p[a]).html(""),a++;for(p=jQuery(".wppa-search-sub-box"),a=0;a<p.length;)jQuery(p[a]).attr("disabled","disabled"),a++}function wppaEnableSubsearch(){for(var p=jQuery(".wppa-search-sub-box"),a=0;a<p.length;)jQuery(p[a]).removeAttr("disabled"),a++}function wppaDisplaySelectedFiles(p){for(var a=jQuery("#"+p),e=0,t="";e<a[0].files.length;)t+=a[0].files[e].name+" ",e++;jQuery("#"+p+"-display").val(t)}function wppaIsEmpty(p){return null==p||(void 0===p||(""==p||(0==p||(0==p||void 0))))}function wppaGetUploadOptions(yalb,mocc,where,onComplete){var options={beforeSend:function(){jQuery("#progress-"+yalb+"-"+mocc).show(),jQuery("#bar-"+yalb+"-"+mocc).width("0%"),jQuery("#message-"+yalb+"-"+mocc).html(""),jQuery("#percent-"+yalb+"-"+mocc).html("")},uploadProgress:function(p,a,e,t){jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#7F7"),jQuery("#bar-"+yalb+"-"+mocc).width(t+"%"),t<95?jQuery("#percent-"+yalb+"-"+mocc).html(t+"%"):jQuery("#percent-"+yalb+"-"+mocc).html(wppaProcessing)},success:function(){jQuery("#bar-"+yalb+"-"+mocc).width("100%"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaDone),jQuery(".wppa-upload-button").val(wppaUploadButtonText)},complete:function(response){-1!=response.responseText.indexOf(wppaUploadFailed)?(jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#F77"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaUploadFailed),jQuery("#message-"+yalb+"-"+mocc).html('<span style="font-size: 10px;" >'+response.responseText+"</span>")):(jQuery("#message-"+yalb+"-"+mocc).html('<span style="font-size: 10px;" >'+response.responseText+"</span>"),"thumb"!=where&&"cover"!=where||eval(onComplete))},error:function(){jQuery("#message-"+yalb+"-"+mocc).html('<span style="color: red;" >'+wppaServerError+"</span>"),jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#F77"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaUploadFailed)}};return options}wppaConsoleLog("wppa.js version "+wppaJsVersion+" loaded.","force");
1
+ var wppaJsVersion="7.2.00",wppaSlideShow,wppaPhoto,wppaOf,wppaNextPhoto,wppaPreviousPhoto,wppaNextP,wppaPrevP,wppaAvgRating,wppaMyRating,wppaAvgRat,wppaMyRat,wppaDislikeMsg,wppaStart,wppaStop,wppaPleaseName,wppaPleaseEmail,wppaPleaseComment,wppaProcessing,wppaDone,wppaUploadFailed,wppaServerError,wppaVersion="0",wppaIsIe=!1,wppaUseSvg=!0,wppaDebug,wppaFullValign=[],wppaFullHalign=[],wppaFullFrameDelta=[],wppaAnimationSpeed,wppaImageDirectory,wppaThumbnailAreaDelta;if(!wppaAutoColumnWidth)var wppaAutoColumnWidth=[];if(!wppaAutoColumnFrac)var wppaAutoColumnFrac=[];var wppaSlideShowTimeOut=2500,wppaFadeInAfterFadeOut=!1,wppaTextFrameDelta=0,wppaBoxDelta=0,wppaPreambule=[],wppaHideWhenEmpty=!1,wppaThumbnailPitch=[],wppaFilmStripLength=[],wppaFilmStripMargin=[],wppaFilmStripAreaDelta=[],wppaFilmShowGlue=!1,wppaIsMini=[],wppaPortraitOnly=[],wppaMiniTreshold=300,wppaRatingOnce=!0,wppaBGcolorNumbar="transparent",wppaBcolorNumbar="transparent",wppaBGcolorNumbarActive="transparent",wppaBcolorNumbarActive="transparent",wppaFontFamilyNumbar="",wppaFontSizeNumbar="",wppaFontColorNumbar="",wppaFontWeightNumbar="",wppaFontFamilyNumbarActive="",wppaFontSizeNumbarActive="",wppaFontColorNumbarActive="",wppaFontWeightNumbarActive="",wppaNumbarMax="10",wppaAjaxUrl="",wppaLang="",wppaNextOnCallback=!1,wppaStarOpacity=.2,wppaLightBox=[],wppaEmailRequired="required",wppaSlideBorderWidth=0,wppaSlideInitRunning=[],wppaAnimationType="fadeover",wppaSlidePause=[],wppaSlideBlank=[],wppaRatingMax=5,wppaRatingDisplayType="graphic",wppaRatingPrec=2,wppaFilmPageSize=[],wppaAspectRatio=[],wppaFullSize=[],wppaStretch=!1,wppaThumbSpaceAuto=!1,wppaMinThumbSpace=4,wppaMagnifierCursor="",wppaArtMonkyLink="none",wppaAutoOpenComments=!1,wppaUpdateAddressLine=!1,wppaFilmThumbTitle="",wppaClickToView="",wppaUploadUrl="",wppaVoteForMe="",wppaVotedForMe="",wppaSlideSwipe=!0,wppaLightboxSingle=[],wppaMaxCoverWidth=300,wppaDownLoad="Download",wppaSiteUrl="",wppaWppaUrl="",wppaIncludeUrl="",wppaSlideToFullpopup=!1,wppaComAltSize=75,wppaBumpViewCount=!0,wppaBumpClickCount=!1,wppaFotomoto=!1,wppaArtMonkeyButton=!0,wppaShortQargs=!1,wppaOvlHires=!1,wppaMasonryCols=[],wppaVideoPlaying=[],wppaAudioPlaying=[],wppaSlideVideoStart=!1,wppaSlideAudioStart=!1,wppaAudioHeight=28,wppaHis=0,wppaStartHtml=[],wppaCanAjaxRender=!1,wppaCanPushState=!1,wppaAllowAjax=!0,wppaMaxOccur=0,wppaFirstOccur=0,wppaUsePhotoNamesInUrls=!1,wppaShareHideWhenRunning=!1,wppaCommentRequiredAfterVote=!0,wppaTopMoc=0;if(!wppaColWidth)var wppaColWidth=[];if(!wppaMCRWidth)var wppaMCRWidth=[];var wppaFotomotoHideWhenRunning=!1,wppaFotomotoMinWidth=400,wppaPhotoView=[],wppaBackgroundColorImage="",wppaPopupLinkType="",wppaPopupOnclick=[],wppaThumbTargetBlank=!1,wppaRel="rel",wppaEditPhotoWidth="960",wppaThemeStyles="",wppaStickyHeaderHeight=0,wppaRenderModal=!1,wppaModalBgColor="#ffffff",wppaBoxRadius=0,wppaModalQuitImg,wppaUploadEdit="none",wppaPageArg="",wppaSlideshowNavigationType="icons",wppaCoverImageResponsive=[],wppaSearchBoxSelItems=[],wppaSlideWrap=[],wppaHideRightClick=!1,wppaGeoZoom=10,wppaLazyLoad=!0,wppaAreaMaxFrac=1,wppaNiceScroll=!1,wppaIconSizeNormal="default",wppaIconSizeSlide=48,wppaIconSizeStars=24,wppaResponseSpeed=500,wppaExtendedResizeCount=0,wppaExtendedResizeDelay=200,_wppaId=[],_wppaAvg=[],_wppaDisc=[],_wppaMyr=[],_wppaVRU=[],_wppaLinkUrl=[],_wppaLinkTitle=[],_wppaLinkTarget=[],_wppaCommentHtml=[],_wppaIptcHtml=[],_wppaExifHtml=[],_wppaToTheSame=!1,_wppaSlides=[],_wppaNames=[],_wppaFullNames=[],_wppaDsc=[],_wppaOgDsc=[],_wppaCurIdx=[],_wppaNxtIdx=[],_wppaTimeOut=[],_wppaSSRuns=[],_wppaFg=[],_wppaTP=[],_wppaIsBusy=[],_wppaFirst=[],_wppaVoteInProgress=!1,_wppaTextDelay,_wppaUrl=[],_wppaSkipRated=[],_wppaLbTitle=[],_wppaStateCount=0,_wppaDidGoto=[],_wppaShareUrl=[],_wppaShareHtml=[],_wppaFilmNoMove=[],_wppaHiresUrl=[],_wppaIsVideo=[],_wppaVideoHtml=[],_wppaAudioHtml=[],_wppaVideoNatWidth=[],_wppaVideoNatHeight=[],_wppaWaitTexts=[],_wppaImageAlt=[],__wppaOverruleRun=!1,wppaOvlUrls,wppaOvlTitles,wppaOvlAlts,wppaOvlIdx=0,wppaOvlFirst=!0,wppaOvlKbHandler="",wppaOvlSizeHandler="",wppaOvlPadTop=5,wppaOvlIsSingle,wppaOvlRunning=!1,wppaOvlVideoHtmls,wppaOvlAudioHtmls,wppaOvlPdfHtmls,wppaOvlVideoNaturalWidths,wppaOvlVideoNaturalHeights,wppaOvlModeInitial="normal",wppaOvlVideoPlaying=!1,wppaOvlAudioPlaying=!1,wppaOvlShowLegenda=!0,wppaOvlShowStartStop=!0,wppaOvlRadius=0,wppaOvlBorderWidth=16,wppaOvlOpen=!1,wppaOvlTxtHeight=36,wppaOvlOpacity=.8,wppaOvlOnclickType="none",wppaOvlTheme="black",wppaOvlAnimSpeed=300,wppaOvlSlideSpeed=3e3,wppaVer4WindowWidth=800,wppaVer4WindowHeight=600,wppaOvlFontFamily="Helvetica",wppaOvlFontSize="10",wppaOvlFontColor="",wppaOvlFontWeight="bold",wppaOvlLineHeight="12",wppaOvlShowCounter=!0,wppaOvlIsVideo=!1,wppaShowLegenda="",wppaOvlFsPhotoId=0,wppaPhotoId=0,wppaOvlVideoStart=!1,wppaOvlAudioStart=!1,wppaLastIptc="",wppaLastExif="",wppaIsMobile=!1,wppaSvgFillcolor="gray",wppaSvgBgcolor="transparent",wppaSvgCornerStyle="light";function wppaDoInit(){_wppaTextDelay=wppaAnimationSpeed,wppaFadeInAfterFadeOut&&(_wppaTextDelay*=2),jQuery(".wppa-ajax-spin").stop().fadeOut(),jQuery(".wppa-ovl-spin").hide(),setTimeout(function(){for(var p=1;p<wppaTopMoc;)jQuery("#ubb-"+p+"-l")&&(wppaUbb(p,"l","hide"),wppaUbb(p,"r","hide")),p++},3e3),jQuery(window).on("DOMContentLoaded load resize orientationchange",wppaDoAllAutocols),jQuery(window).on("DOMContentLoaded load resize scroll wheel",wppaSizeArea),jQuery(window).on("DOMContentLoaded load resize scroll wheel",wppaMakeLazyVisible),jQuery(".wppa-divnicewrap").on("resize scroll wheel",wppaMakeLazyVisible),jQuery(window).trigger("resize"),wppaProtect()}function wppaSizeAutoDiv(){jQuery(".wppa-autodiv").each(function(p){var a=jQuery(window).height(),e=jQuery(this).attr("data-max-height");jQuery(this).css({maxHeight:a*e})})}jQuery(document).ready(function(){wppaDoInit()}),jQuery(document).ready(function(){jQuery(window).on("DOMContentLoaded load resize scroll",wppaSizeAutoDiv)});var wppaDoAllAutocolsLastI=0;function wppaDoAllAutocols(p){if("number"!=typeof p?p=1:p++,!(p<=wppaDoAllAutocolsLastI)){wppaDoAllAutocolsLastI=p,wppaConsoleLog("Doing wppaDoAllAutocols("+p+")");for(var a=1;a<=wppaAutoColumnWidth.length;)wppaAutoColumnWidth[a]&&_wppaDoAutocol(a,p),a++;return wppaMakeLazyVisible(),(p<wppaExtendedResizeCount||-1==wppaExtendedResizeCount)&&setTimeout(function(){wppaDoAllAutocols(p)},wppaExtendedResizeDelay),!0}wppaDoAllAutocolsLastI=0}function wppaProtect(){wppaHideRightClick&&(jQuery("img").bind("contextmenu",function(p){return!1}),jQuery("video").bind("contextmenu",function(p){return!1}))}function wppaUpdateLightboxes(){"function"==typeof wppaInitOverlay&&wppaInitOverlay(),"undefined"!=typeof myLightbox&&"function"==typeof myLightbox.updateImageList&&myLightbox.updateImageList(),jQuery().prettyPhoto&&jQuery("a[rel^='prettyPhoto']").prettyPhoto({deeplinking:!1})}function wppaStopVideo(p){var a,e,t=[];for(t[1]="wppa-overlay-img",t[2]="theimg0-"+p,t[3]="theimg1-"+p,e=0;e<3;)1==++e&&0!=p||(a=document.getElementById(t[e]))&&"function"==typeof a.pause&&(a.pause(),wppaConsoleLog("Video "+t[e]+" paused","force"))}function wppaStopAudio(p){if("number"==typeof p)jQuery("#audio-"+p).pause&&jQuery("#audio-"+p).pause();else{var a=jQuery("audio");if(0<a.length)for(var e=0;e<a.length;)"wppa"==jQuery(a[e]).attr("data-from")&&a[e].pause(),e++}}function wppaMakeFullsizeUrl(p){var a,e;p=(a=(p=p.replace("/thumbs/","/")).split("//"))[1]?(e=a[1].split("/"),a[0]+"//"):(e=a[0].split("/"),"");for(var t=0;t<e.length;){var o=e[t];"w"!=o.split("_")[0]&&(0!=t&&(p+="/"),p+=o),t++}return p}function wppaGetContainerWidth(p){var a=document.getElementById("wppa-container-"+p),e=0;if(!wppaAutoColumnWidth[p])return a.clientWidth;for(;0==e;)a=a.parentNode,e=jQuery(a).width();return parseInt(e*wppaAutoColumnFrac[p])}function _wppaDoAutocol(p,a){if(wppaConsoleLog("Enter auto. mocc = "+p+" retry = "+a),!wppaAutoColumnWidth[p])return!0;var e,t;if(e=jQuery("#wppa-container-"+p).width(),wppaCoverImageResponsive[p]||1<(t=jQuery(".wppa-asym-text-frame-"+p)).length&&(jQuery(t[0]).width(),0==wppaResponseSpeed?(jQuery(".wppa-asym-text-frame-"+p).css({width:e-wppaTextFrameDelta}),jQuery(".wppa-cover-box-"+p).css({width:e})):(jQuery(".wppa-asym-text-frame-"+p).stop().animate({width:e-wppaTextFrameDelta},wppaResponseSpeed),jQuery(".wppa-cover-box-"+p).stop().animate({width:e},wppaResponseSpeed))),1<(t=jQuery(".wppa-cover-box-mcr-"+p)).length){var o=document.getElementById("wppa-albumlist-"+p).clientWidth,r=parseInt((o+8)/(wppaMaxCoverWidth+8))+1,s=r-1,i=parseInt((o+8)/r-8);if(wppaColWidth[p]!=o||wppaMCRWidth[p]!=i){wppaColWidth[p]=o,wppaMCRWidth[p]=i;for(var n=0;n<t.length;){switch(n%r){case 0:jQuery(t[n]).css({marginLeft:"0px",clear:"both",float:"left"});break;case s:jQuery(t[n]).css({marginLeft:"0px",clear:"none",float:"right"});break;default:jQuery(t[n]).css({marginLeft:"8px",clear:"none",float:"left"})}n++}wppaCoverImageResponsive[p]||jQuery(".wppa-asym-text-frame-mcr-"+p).stop().animate({width:i-wppaTextFrameDelta},wppaResponseSpeed),jQuery(t[0]).width(),jQuery(".wppa-cover-box-mcr-"+p).stop().animate({width:i},wppaResponseSpeed)}}else if(1==t.length)if(wppaCoverImageResponsive[p]);else{jQuery(".wppa-asym-text-frame-mcr-"+p).stop().animate({width:e-wppaTextFrameDelta},wppaResponseSpeed);jQuery(".wppa-cover-box-mcr-"+p).css({marginLeft:"0px",float:"left"})}if(wppaThumbSpaceAuto){var w=parseInt(jQuery(".thumbnail-frame-"+p).css("width"));if(w){var l=wppaMinThumbSpace,u=e-wppaThumbnailAreaDelta-7,c=Math.max(1,parseInt(u/(w+l))),d=parseInt(.5+(u-c*w)/(c+1));jQuery(".thumbnail-frame-"+p).css({marginLeft:d})}}jQuery(".thumbnail-frame-comalt-"+p).css("width",e-wppaThumbnailAreaDelta),jQuery(".wppa-com-alt-"+p).css("width",e-wppaThumbnailAreaDelta-wppaComAltSize-16);for(var y,m=1,h=jQuery("#wppa-mas-h-"+m+"-"+p).attr("data-height-perc");h;)y=h*(e-wppaThumbnailAreaDelta)/100,jQuery("#wppa-mas-h-"+m+"-"+p).css("height",y),m++,h=jQuery("#wppa-mas-h-"+m+"-"+p).attr("data-height-perc");return wppaSetMasHorFrameWidthsForIeAndChrome(p),wppaFormatSlide(p),jQuery("#audio-slide-"+p).css("width",e-wppaBoxDelta-6),jQuery(".wppa-comment-textarea-"+p).css("width",.7*e),wppaFilmStripLength[p]=e-wppaFilmStripAreaDelta[p],jQuery("#filmwindow-"+p).css("width",wppaFilmStripLength[p]),_wppaAdjustFilmstrip(p),wppaIsMini[p]||void 0===_wppaSlides[p]||(wppaColWidth[p]<wppaMiniTreshold?(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRat),jQuery("#wppa-my-rat-"+p).html(wppaMyRat),jQuery("#counter-"+p).html(_wppaCurIdx[p]+1+" / "+_wppaSlides[p].length)):(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRating),jQuery("#wppa-my-rat-"+p).html(wppaMyRating),jQuery("#counter-"+p).html(wppaPhoto+" "+(_wppaCurIdx[p]+1)+" "+wppaOf+" "+_wppaSlides[p].length))),jQuery(".wppa-sphoto-"+p).css("width",e),jQuery(".wppa-simg-"+p).css("width",e-2*wppaSlideBorderWidth),jQuery(".wppa-simg-"+p).css("height",""),jQuery(".wppa-mphoto-"+p).css("width",e+10),jQuery(".wppa-mimg-"+p).css("width",e),jQuery(".wppa-mimg-"+p).css("height",""),jQuery(".smxpdf-"+p).css("height",.8*wppaWindowHeight()),0<wppaSearchBoxSelItems[p]&&(e/wppaSearchBoxSelItems[p]<125?jQuery(".wppa-searchsel-item-"+p).css("width","100%"):jQuery(".wppa-searchsel-item-"+p).css("width",100/wppaSearchBoxSelItems[p]+"%")),jQuery(".wppa-upload-album-"+p).css("maxWidth",.6*e),!0}function wppaSetMasHorFrameWidthsForIeAndChrome(p){for(var a=jQuery(".wppa-mas-h-"+p),e=wppaMinThumbSpace,t=0;t<a.length;t++){var o=wppaGetChildI(a[t]);if(o){if("IMG"==o.nodeName&&!o.complete)return void setTimeout("wppaSetMasHorFrameWidthsForIeAndChrome( "+p+" )",400);var r=o.naturalWidth/o.naturalHeight*o.height+e;jQuery(a[t]).css({width:r})}}}function wppaGetChildI(p){var a,e=p.childNodes;for(a=0;a<e.length;a++){var t=e[a];if(t.id&&"i-"==t.id.substr(0,2))return t;var o=wppaGetChildI(t);if(o)return o}return!1}jQuery(document).ready(function(p){if(wppaAllowAjax&&jQuery.ajax&&(wppaCanAjaxRender=!0),void 0!==history.pushState){for(var a=1;a<=wppaMaxOccur;)wppaStartHtml[a]=jQuery("#wppa-container-"+a).html(),a++;wppaCanPushState=!0}});var wppaFotomotoLoaded=!1,wppaFotomotoToolbarIds=[];function fotomoto_loaded(){wppaFotomotoLoaded=!0}function wppaFotomotoToolbar(p,a){if(!(wppaColWidth[p]>=wppaFotomotoMinWidth))return jQuery("#wppa-fotomoto-container-"+p).css("display","none"),void jQuery("#wppa-fotomoto-checkout-"+p).css("display","none");jQuery("#wppa-fotomoto-container-"+p).css("display","inline"),jQuery("#wppa-fotomoto-checkout-"+p).css("display","inline"),wppaFotomoto&&document.getElementById("wppa-fotomoto-container-"+p)&&(wppaFotomotoLoaded?(FOTOMOTO.API.checkinImage(a),wppaFotomotoToolbarIds[p]=FOTOMOTO.API.showToolbar("wppa-fotomoto-container-"+p,a)):(setTimeout("wppaFotomotoToolbar( "+p+',"'+a+'" )',200),wppaConsoleLog("Waiting for Fotomoto")))}function wppaFotomotoHide(p){jQuery("#wppa-fotomoto-container-"+p).css("display","none"),jQuery("#wppa-fotomoto-checkout-"+p).css("display","none")}function wppaStringContainsForbiddenChars(p){for(var a=["?","&","#","/",'"',"'"],e=0;e<a.length;){if(-1!=p.indexOf(a[e]))return!0;e++}return!1}function wppaPushStateSlide(p,a,e){if(!wppaIsMini[p]&&wppaCanPushState&&wppaUpdateAddressLine&&""!=e)try{history.pushState({page:wppaHis,occur:p,type:"slide",slide:a},"---",e),wppaConsoleLog("Slide history stack updated")}catch(p){wppaConsoleLog("Slide history stack update failed")}}function wppaRepairScriptTags(p){if(void 0===p)return"";for(;-1!=p.indexOf("[script");)p=p.replace("[script","<script");for(;-1!=p.indexOf("[/script");)p=p.replace("[/script","</script");return p}function wppaRepairBrTags(p){return void 0===p?"":p.replace("[br /]","<br />").replace("[a","<a").replace("&quot;",'"').replace('"]','">').replace("[/a]","</a>")}function wppaTrimAlt(p){return void 0===p?"":13<p.length?p.substr(0,10)+"...":p}window.onpopstate=function(p){var a=0;if(wppaCanPushState){if(p.state)switch(a=p.state.occur,p.state.type){case"html":jQuery("#wppa-container-"+a).html(p.state.html);break;case"slide":_wppaGoto(a,p.state.slide)}else if(wppaUpdateAddressLine){if(a=wppaFirstOccur,jQuery("#wppa-container-"+a).html(wppaStartHtml[a]),(wppaFirstOccur=0)==a){var e=document.location.href.split("&wppa-occur=");a=parseInt(e[1])}e=document.location.href.split("&wppa-photo=");var t=parseInt(e[1]);if(0<t){for(var o=0;o<_wppaId[a].length&&_wppaId[a][o]!=t;)o++;o<_wppaId[a].length&&_wppaGoto(a,o)}}document.getElementById("theslide0-"+a)&&_wppaStop(a)}"undefined"!=typeof wppaQRUpdate&&wppaQRUpdate(document.location.href)};var wppaFbInitBusy=!1;function wppaFbInit(){wppaFbInitBusy?wppaConsoleLog("Fb Init busy"):"undefined"!=typeof FB?(wppaFbInitBusy=!0,setTimeout("_wppaFbInit()",10)):(wppaConsoleLog("Fb wait"),setTimeout("wppaFbInit()",200))}function _wppaFbInit(){FB.init({status:!0,xfbml:!0}),wppaFbInitBusy=!1}function wppaInsertAtCursor(p,a){if(document.selection)p.focus(),sel=document.selection.createRange(),sel.text=a;else if(p.selectionStart||"0"==p.selectionStart){var e=p.selectionStart,t=p.selectionEnd;p.value=p.value.substring(0,e)+a+p.value.substring(t,p.value.length),p.selectionStart=e+a.length,p.selectionEnd=e+a.length}else p.value+=a}function wppaGeoInit(p,a,e){var t=new google.maps.LatLng(a,e),o={disableDefaultUI:!1,panControl:!1,zoomControl:!0,mapTypeControl:!0,scaleControl:!0,streetViewControl:!0,overviewMapControl:!0,zoom:wppaGeoZoom,center:t},r=new google.maps.Map(document.getElementById("map-canvas-"+p),o),s=new google.maps.Marker({position:t,map:r,title:""});google.maps.event.addListener(r,"center_changed",function(){window.setTimeout(function(){r.panTo(s.getPosition())},1e3)})}function wppaEncode(p){var a;if(void 0!==p){var e=(a=(a=String(p).replace(/#/g,"||HASH||")).replace(/&/g,"||AMP||")).split("+"),t=0;for(a="";t<e.length;)a+=e[t],++t<e.length&&(a+="||PLUS||");return a}}function wppaUrlToId(p){var a=p.split("/wppa/");return 1==a.length&&(a=p.split("/upload/")),1==a.length?0:a=(a=(a=(a=(a=(a=(a=a[1]).split("."))[0].replace("/","")).replace("/","")).replace("/","")).replace("/","")).replace("/","")}function wppaSuperSearchSelect(p,a){jQuery("#wppa-ss-albumopt-"+p).css("display","none"),jQuery("#wppa-ss-albumcat-"+p).css("display","none"),jQuery("#wppa-ss-albumname-"+p).css("display","none"),jQuery("#wppa-ss-albumtext-"+p).css("display","none"),jQuery("#wppa-ss-photoopt-"+p).css("display","none"),jQuery("#wppa-ss-photoname-"+p).css("display","none"),jQuery("#wppa-ss-photoowner-"+p).css("display","none"),jQuery("#wppa-ss-phototag-"+p).css("display","none"),jQuery("#wppa-ss-phototext-"+p).css("display","none"),jQuery("#wppa-ss-photoexif-"+p).css("display","none"),jQuery("#wppa-ss-photoiptc-"+p).css("display","none"),jQuery("#wppa-ss-exifopts-"+p).css("display","none"),jQuery("#wppa-ss-iptcopts-"+p).css("display","none"),jQuery("#wppa-ss-spinner-"+p).css("display","none"),jQuery("#wppa-ss-button-"+p).css("display","none");var e=jQuery("#wppa-ss-pa-"+p).val(),t="",o="",r="";switch(e){case"a":switch(jQuery("#wppa-ss-albumopt-"+p).css("display",""),t=jQuery("#wppa-ss-albumopt-"+p).val()){case"c":jQuery("#wppa-ss-albumcat-"+p).css("display","");var s=jQuery(".wppa-ss-albumcat-"+p);for(r="",i=0;i<s.length;i++)"selected"==jQuery(s[i]).attr("selected")&&(r+="."+jQuery(s[i]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"n":jQuery("#wppa-ss-albumname-"+p).css("display",""),null!=(r=jQuery("#wppa-ss-albumname-"+p).val())&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"t":jQuery("#wppa-ss-albumtext-"+p).css("display","");s=jQuery(".wppa-ss-albumtext-"+p);for(r="",i=0;i<s.length;i++)"selected"==jQuery(s[i]).attr("selected")&&(r+="."+jQuery(s[i]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+p).css("display","")}break;case"p":switch(jQuery("#wppa-ss-photoopt-"+p).css("display",""),t=jQuery("#wppa-ss-photoopt-"+p).val()){case"n":jQuery("#wppa-ss-photoname-"+p).css("display",""),null!=(r=jQuery("#wppa-ss-photoname-"+p).val())&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"o":jQuery("#wppa-ss-photoowner-"+p).css("display",""),null!=(r=jQuery("#wppa-ss-photoowner-"+p).val())&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"g":jQuery("#wppa-ss-phototag-"+p).css("display","");s=jQuery(".wppa-ss-phototag-"+p);for(r="",i=0;i<s.length;i++)"selected"==jQuery(s[i]).attr("selected")&&(r+="."+jQuery(s[i]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"t":jQuery("#wppa-ss-phototext-"+p).css("display","");var i;s=jQuery(".wppa-ss-phototext-"+p);for(r="",i=0;i<s.length;i++)"selected"==jQuery(s[i]).attr("selected")&&(r+="."+jQuery(s[i]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+p).css("display","");break;case"i":jQuery("#wppa-ss-photoiptc-"+p).css("display",""),(o=jQuery("#wppa-ss-photoiptc-"+p).val())&&(2<o.length&&(o=o.replace("#","H")),""!=o&&(jQuery("#wppa-ss-iptcopts-"+p).css("display",""),wppaLastIptc!=o?(wppaAjaxGetSsIptcList(p,o,"wppa-ss-iptcopts-"+p),wppaLastIptc=o):null!=(r=jQuery("#wppa-ss-iptcopts-"+p).val())&&""!=r&&jQuery("#wppa-ss-button-"+p).css("display","")));break;case"e":jQuery("#wppa-ss-photoexif-"+p).css("display",""),(o=jQuery("#wppa-ss-photoexif-"+p).val())&&(2<o.length&&(o=o.replace("#","H")),""!=o&&(jQuery("#wppa-ss-exifopts-"+p).css("display",""),wppaLastExif!=o?(wppaAjaxGetSsExifList(p,o,"wppa-ss-exifopts-"+p),wppaLastExif=o):null!=(r=jQuery("#wppa-ss-exifopts-"+p).val())&&""!=r&&jQuery("#wppa-ss-button-"+p).css("display","")))}}if(a){var n=jQuery("#wppa-ss-pageurl-"+p).val();-1==n.indexOf("?")?n+="?":n+="&",n+="occur=1&wppa-supersearch="+e+","+t+","+o+","+r,document.location.href=n}}function wppaAjaxGetSsIptcList(t,p,o){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=getssiptclist&tag="+p+"&moccur="+t,async:!0,type:"GET",timeout:1e4,beforeSend:function(p){jQuery("#wppa-ss-spinner-"+t).css("display","")},success:function(p,a,e){jQuery("#"+o).html(p),jQuery("#wppa-ss-iptcopts-"+t).css("display",""),wppaSuperSearchSelect(t),setTimeout('wppaSetIptcExifSize( ".wppa-iptclist-'+t+'", "#'+o+'" )',10)},error:function(p,a,e){wppaConsoleLog("wppaAjaxGetSsIptcList failed. Error = "+e+", status = "+a,"force")},complete:function(p,a,e){jQuery("#wppa-ss-spinner-"+t).css("display","none")}})}function wppaAjaxGetSsExifList(t,p,o){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=getssexiflist&tag="+p+"&moccur="+t,async:!0,type:"GET",timeout:1e4,beforeSend:function(p){jQuery("#wppa-ss-spinner-"+t).css("display","")},success:function(p,a,e){jQuery("#"+o).html(p),jQuery("#wppa-ss-exifopts-"+t).css("display",""),wppaSuperSearchSelect(t),setTimeout('wppaSetIptcExifSize( ".wppa-exiflist-'+t+'", "#'+o+'" )',10)},error:function(p,a,e){wppaConsoleLog("wppaAjaxGetSsExifList failed. Error = "+e+", status = "+a,"force")},complete:function(p,a,e){jQuery("#wppa-ss-spinner-"+t).css("display","none")}})}function wppaSetIptcExifSize(p,a){var e=jQuery(p).length;6<e&&(e=6),e<2&&(e=2),jQuery(a).attr("size",e)}function wppaUpdateSearchRoot(p,a){for(var e=jQuery(".wppa-search-root"),t=0;t<e.length;)jQuery(e[t]).html(p),t++;for(e=jQuery(".wppa-rootbox"),t=0;t<e.length;)a?(jQuery(e[t]).prop("checked",!1),jQuery(e[t]).prop("disabled",!1)):(jQuery(e[t]).prop("checked",!0),jQuery(e[t]).prop("disabled",!0)),t++;for(e=jQuery(".wppa-search-root-id"),t=0;t<e.length;)jQuery(e[t]).val(a),t++}function wppaSubboxChange(p){jQuery(p).prop("checked")&&jQuery(".wppa-rootbox").each(function(p){jQuery(this).prop("checked",!0)})}function wppaClearSubsearch(){for(var p=jQuery(".wppa-display-searchstring"),a=0;a<p.length;)jQuery(p[a]).html(""),a++;for(p=jQuery(".wppa-search-sub-box"),a=0;a<p.length;)jQuery(p[a]).attr("disabled","disabled"),a++}function wppaEnableSubsearch(){for(var p=jQuery(".wppa-search-sub-box"),a=0;a<p.length;)jQuery(p[a]).removeAttr("disabled"),a++}function wppaDisplaySelectedFiles(p){for(var a=jQuery("#"+p),e=0,t="";e<a[0].files.length;)t+=a[0].files[e].name+" ",e++;jQuery("#"+p+"-display").val(t)}function wppaIsEmpty(p){return null==p||(void 0===p||(""==p||(0==p||(0==p||void 0))))}function wppaGetUploadOptions(yalb,mocc,where,onComplete){var options={beforeSend:function(){jQuery("#progress-"+yalb+"-"+mocc).show(),jQuery("#bar-"+yalb+"-"+mocc).width("0%"),jQuery("#message-"+yalb+"-"+mocc).html(""),jQuery("#percent-"+yalb+"-"+mocc).html("")},uploadProgress:function(p,a,e,t){jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#7F7"),jQuery("#bar-"+yalb+"-"+mocc).width(t+"%"),t<95?jQuery("#percent-"+yalb+"-"+mocc).html(t+"%"):jQuery("#percent-"+yalb+"-"+mocc).html(wppaProcessing)},success:function(){jQuery("#bar-"+yalb+"-"+mocc).width("100%"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaDone),jQuery(".wppa-upload-button").val(wppaUploadButtonText)},complete:function(response){-1!=response.responseText.indexOf(wppaUploadFailed)?(jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#F77"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaUploadFailed),jQuery("#message-"+yalb+"-"+mocc).html('<span style="font-size: 10px;" >'+response.responseText+"</span>")):(jQuery("#message-"+yalb+"-"+mocc).html('<span style="font-size: 10px;" >'+response.responseText+"</span>"),"thumb"!=where&&"cover"!=where||eval(onComplete))},error:function(){jQuery("#message-"+yalb+"-"+mocc).html('<span style="color: red;" >'+wppaServerError+"</span>"),jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#F77"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaUploadFailed)}};return options}wppaConsoleLog("wppa.js version "+wppaJsVersion+" loaded.","force");
readme.txt CHANGED
@@ -2,12 +2,12 @@
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.1.11.008
6
- Stable tag: 7.1.10.007
7
Author: J.N. Breetvelt
8
Author URI: http://www.opajaap.nl/
9
Requires at least: 3.9
10
- Tested up to: 5.2.1
11
Requires PHP: 5.5
12
License: GPLv2 or later
13
License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -137,6 +137,10 @@ See for the full changelog: <a href="http://www.wppa.nl/changelog/" >The documen
137
138
== Upgrade Notice ==
139
140
= 7.1.11 =
141
142
* This version addresses various bug fixes and feature requests.
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.2.00.008
6
+ Stable tag: 7.1.11.008
7
Author: J.N. Breetvelt
8
Author URI: http://www.opajaap.nl/
9
Requires at least: 3.9
10
+ Tested up to: 5.2.2
11
Requires PHP: 5.5
12
License: GPLv2 or later
13
License URI: http://www.gnu.org/licenses/gpl-2.0.html
137
138
== Upgrade Notice ==
139
140
+ = 7.2.00 =
141
+
142
+ * This version addresses various bug fixes and feature requests.
143
+
144
= 7.1.11 =
145
146
* This version addresses various bug fixes and feature requests.
wppa-adminbar.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* enhances the admin bar with wppa+ menu
6
- * Version 7.0.06
7
*
8
*/
9
@@ -101,7 +101,7 @@ function wppa_admin_bar_menu() {
101
$menu_items['opajaap'] = array(
102
'parent' => $wppaplus,
103
'title' => __( 'Documentation', 'wp-photo-album-plus' ),
104
- 'href' => 'http://wppa.nl'
105
);
106
107
if ( current_user_can( 'administrator' ) ) {
3
* Package: wp-photo-album-plus
4
*
5
* enhances the admin bar with wppa+ menu
6
+ * Version 7.2.00
7
*
8
*/
9
101
$menu_items['opajaap'] = array(
102
'parent' => $wppaplus,
103
'title' => __( 'Documentation', 'wp-photo-album-plus' ),
104
+ 'href' => 'https://wppa.nl'
105
);
106
107
if ( current_user_can( 'administrator' ) ) {
wppa-ajax.php CHANGED
@@ -2,7 +2,7 @@
2
/* wppa-ajax.php
3
*
4
* Functions used in ajax requests
5
- * Version 7.1.11
6
*
7
*/
8
@@ -850,6 +850,9 @@ global $wppa_log_file;
850
wppa_exit();
851
}
852
853
$desturl = WPPA_UPLOAD_URL.'/temp/'.$name.'.'.$ext;
854
echo '||0||' . esc_url( $desturl ); // No error: return url
855
wppa_exit();
2
/* wppa-ajax.php
3
*
4
* Functions used in ajax requests
5
+ * Version 7.2.00
6
*
7
*/
8
850
wppa_exit();
851
}
852
853
+ // Update download counter
854
+ wppa_bump_dlcount( $photo );
855
+
856
$desturl = WPPA_UPLOAD_URL.'/temp/'.$name.'.'.$ext;
857
echo '||0||' . esc_url( $desturl ); // No error: return url
858
wppa_exit();
wppa-boxes-html.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* Various wppa boxes
6
- * Version 7.1.08
7
*
8
*/
9
@@ -2148,9 +2148,9 @@ function wppa_get_user_create_html( $alb, $width, $where = '', $mcr = false ) {
2148
}
2149
2150
// Can create album?
2151
- if ( ! $parent && ! wppa_can_create_top_album() ) {
2152
- return '';
2153
- }
2154
if ( $parent && ! wppa_can_create_album() ) {
2155
return '';
2156
}
@@ -2234,10 +2234,66 @@ function wppa_get_user_create_html( $alb, $width, $where = '', $mcr = false ) {
2234
' method="post"' .
2235
' >' .
2236
wppa_nonce_field( 'wppa-album-check' , 'wppa-nonce', false, false, $alb ) .
2237
- '<input type="hidden" name="wppa-album-parent" value="'.$parent.'" />' .
2238
- '<input type="hidden" name="wppa-fe-create" value="yes" />' .
2239
2240
// Name
2241
'<div'.
2242
' class="wppa-box-text wppa-td"' .
2243
' style="' .
3
* Package: wp-photo-album-plus
4
*
5
* Various wppa boxes
6
+ * Version 7.2.00
7
*
8
*/
9
2148
}
2149
2150
// Can create album?
2151
+ // if ( ! $parent && ! wppa_can_create_top_album() ) {
2152
+ // return '';
2153
+ // }
2154
if ( $parent && ! wppa_can_create_album() ) {
2155
return '';
2156
}
2234
' method="post"' .
2235
' >' .
2236
wppa_nonce_field( 'wppa-album-check' , 'wppa-nonce', false, false, $alb ) .
2237
+ // '<input type="hidden" name="wppa-album-parent" value="'.$parent.'" />' .
2238
+ '<input type="hidden" name="wppa-fe-create" value="yes" />';
2239
+
2240
+ // Parent
2241
+ if ( ( $where == 'widget' || wppa( 'is_upload' ) ) && ! wppa_switch( 'default_parent_always' ) ) {
2242
+
2243
+ $head = __( 'Parent album', 'wp-photo-album-plus' );
2244
+ $body = '';
2245
+ $result .= wppa_get_dlg_item( $head, $body, false );
2246
+
2247
+ $result .=
2248
+ '<select' .
2249
+ ' id="wppa-create-parent-'.$mocc.'"' .
2250
+ ' name="wppa-album-parent"' .
2251
+ ' class="wppa-upload-album-'.$mocc.'"' .
2252
+ ' style="max-width: 100%;"' .
2253
+ // ' onchange="jQuery( \'#wppa-sel-'.$yalb.'-'.$mocc.'\' ).trigger( \'onchange\' )"' .
2254
+ ' >' .
2255
+ wppa_album_select_a( array ( 'exclude' => '',
2256
+ 'selected' => '',
2257
+ 'disabled' => '',
2258
+ 'addpleaseselect' => false,
2259
+ 'addnone' => wppa_can_create_top_album(),
2260
+ 'addall' => false,
2261
+ 'addgeneric' => false,
2262
+ 'addblank' => false,
2263
+ 'addselected' => false,
2264
+ 'addseparate' => wppa_can_create_top_album(),
2265
+ 'addselbox' => false,
2266
+ 'addowner' => false,
2267
+ 'disableancestors' => false,
2268
+ 'checkaccess' => true,
2269
+ 'checkowner' => false,
2270
+ 'checkupload' => false,
2271
+ 'addmultiple' => false,
2272
+ 'addnumbers' => false,
2273
+ 'path' => wppa_switch( 'hier_albsel' ),
2274
+ 'root' => false,
2275
+ 'content' => false,
2276
+ 'sort' => true,
2277
+ 'checkarray' => false,
2278
+ 'array' => array(),
2279
+ 'optionclass' => '',
2280
+ 'tagopen' => '',
2281
+ 'tagname' => '',
2282
+ 'tagid' => '',
2283
+ 'tagonchange' => '',
2284
+ 'multiple' => false,
2285
+ 'tagstyle' => '',
2286
+ ) ) .
2287
+ '</select>' .
2288
+ '<div style="clear:both;" ></div>';
2289
+ }
2290
+ else {
2291
+ $result .=
2292
+ '<input type="hidden" name="wppa-album-parent" value="'.$parent.'" />';
2293
+ }
2294
2295
// Name
2296
+ $result .=
2297
'<div'.
2298
' class="wppa-box-text wppa-td"' .
2299
' style="' .
wppa-functions.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* Various functions
6
- * Version 7.1.11
7
*
8
*/
9
@@ -1223,6 +1223,9 @@ global $wppa_session;
1223
case 'views':
1224
$sortby = "views DESC, mean_rating DESC, rating_count DESC";
1225
break;
1226
default:
1227
wppa_error_message( 'Unimplemented sorting method' );
1228
$sortby = '';
@@ -1241,6 +1244,9 @@ global $wppa_session;
1241
if ( wppa_opt( 'topten_sortby' ) == 'views' ) {
1242
$non_zero = "AND views > 0 ";
1243
}
1244
else {
1245
$non_zero = "AND rating_count > 0 ";
1246
}
@@ -2007,7 +2013,7 @@ global $wpdb;
2007
// Log query
2008
wppa_dbg_msg( $query, 'red' ); // , 'force' ); /**/
2009
wppa_log( 'dbg', htmlspecialchars( $query ) );
2010
-
2011
// Process extended duplicate removal
2012
if ( $exduprem ) {
2013
wppa_extended_duplicate_remove( $thumbs );
@@ -4883,7 +4889,7 @@ global $wppa_alert;
4883
wppa_schedule_mailinglist( 'moderatephoto', 0, $id );
4884
}
4885
else {
4886
- wppa_schedule_mailinglist( 'feuploadnotify', 0, $id );
4887
}
4888
4889
// Do pdf postprocessing
3
* Package: wp-photo-album-plus
4
*
5
* Various functions
6
+ * Version 7.2.00
7
*
8
*/
9
1223
case 'views':
1224
$sortby = "views DESC, mean_rating DESC, rating_count DESC";
1225
break;
1226
+ case 'dlcount':
1227
+ $sortby = "dlcount DESC, mean_rating DESC, rating_count DESC, views DESC";
1228
+ break;
1229
default:
1230
wppa_error_message( 'Unimplemented sorting method' );
1231
$sortby = '';
1244
if ( wppa_opt( 'topten_sortby' ) == 'views' ) {
1245
$non_zero = "AND views > 0 ";
1246
}
1247
+ elseif ( wppa_opt( 'topten_sortby' ) == 'dlcount' ) {
1248
+ $non_xero = "AND dlcount > 0";
1249
+ }
1250
else {
1251
$non_zero = "AND rating_count > 0 ";
1252
}
2013
// Log query
2014
wppa_dbg_msg( $query, 'red' ); // , 'force' ); /**/
2015
wppa_log( 'dbg', htmlspecialchars( $query ) );
2016
+
2017
// Process extended duplicate removal
2018
if ( $exduprem ) {
2019
wppa_extended_duplicate_remove( $thumbs );
4889
wppa_schedule_mailinglist( 'moderatephoto', 0, $id );
4890
}
4891
else {
4892
+ wppa_schedule_mailinglist( 'feuploadnotify', 0, $id, 0, '', 0, 300 );
4893
}
4894
4895
// Do pdf postprocessing
wppa-help.php CHANGED
@@ -3,7 +3,7 @@
3
* Pachkage: wp-photo-album-plus
4
*
5
* admin help page
6
- * version 6.4.20
7
*/
8
9
function _wppa_page_help() {
@@ -13,7 +13,7 @@ global $wppa_revno;
13
?>
14
<div class="wrap">
15
16
- <h3><?php echo sprintf(__('You will find all information and examples on the new %s%s%s site', 'wp-photo-album-plus'), '<a href="http://wppa.nl/" target="_blank" >', esc_attr( __( 'Docs & Demos', 'wp-photo-album-plus' ) ), '</a>' ) ?></h3>
17
18
<h3><?php _e('About and credits', 'wp-photo-album-plus'); ?></h3>
19
<p>
3
* Pachkage: wp-photo-album-plus
4
*
5
* admin help page
6
+ * version 7.2.00
7
*/
8
9
function _wppa_page_help() {
13
?>
14
<div class="wrap">
15
16
+ <h3><?php echo sprintf(__('You will find all information and examples on the new %s%s%s site', 'wp-photo-album-plus'), '<a href="https://wppa.nl/" target="_blank" >', esc_attr( __( 'Docs & Demos', 'wp-photo-album-plus' ) ), '</a>' ) ?></h3>
17
18
<h3><?php _e('About and credits', 'wp-photo-album-plus'); ?></h3>
19
<p>
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.0.01
7
*
8
*/
9
@@ -366,7 +366,7 @@ function wppa_translate_photo_keywords( $id, $text ) {
366
$result = str_replace( 'w#albumname', wppa_get_album_name( $thumb['album'] ), $result );
367
$result = str_replace( 'w#albumid', $thumb['album'], $result );
368
$result = str_replace( 'w#owner', wppa_bp_userlink( $thumb['owner'] ), $result );
369
- $keywords = array( 'name', 'filename', 'id', 'tags', 'views', 'album' );
370
foreach ( $keywords as $keyword ) {
371
$replacement = __( trim( stripslashes( $thumb[$keyword] ) ) , 'wp-photo-album-plus');
372
if ( $keyword == 'tags' ) {
3
* Package: wp-photo-album-plus
4
*
5
* Contains functions to retrieve album and photo items
6
+ * Version 7.2.00
7
*
8
*/
9
366
$result = str_replace( 'w#albumname', wppa_get_album_name( $thumb['album'] ), $result );
367
$result = str_replace( 'w#albumid', $thumb['album'], $result );
368
$result = str_replace( 'w#owner', wppa_bp_userlink( $thumb['owner'] ), $result );
369
+ $keywords = array( 'name', 'filename', 'id', 'tags', 'views', 'album', 'dlcount' );
370
foreach ( $keywords as $keyword ) {
371
$replacement = __( trim( stripslashes( $thumb[$keyword] ) ) , 'wp-photo-album-plus');
372
if ( $keyword == 'tags' ) {
wppa-mailing.php CHANGED
@@ -4,7 +4,7 @@
4
*
5
* Contains mailing functions
6
*
7
- * Version 7.1.07
8
*
9
*/
10
@@ -24,6 +24,24 @@ add_action( 'wppa_do_mailinglist_cron', 'wppa_do_mailinglist', 10, 6 );
24
// Call this function to schedule a mailinglist emission
25
function wppa_schedule_mailinglist( $type, $alb = 0, $pho = 0, $com = 0, $url = '', $start = 0, $delay = 120 ) {
26
27
wp_schedule_single_event( time() + $delay, 'wppa_do_mailinglist_cron', array( $type, $alb, $pho, $com, $url, $start ) );
28
wppa_log( 'Eml', 'Mailinglist {b}' . $type . '{/b} ' . ( $start ? 're-' : '' ) . 'scheduled for run in ' . $delay . ' seconds. Args: ' . $alb . ', ' . $pho . ', ' . $com . ', ' . $url . ', ' . $start );
29
@@ -169,8 +187,31 @@ global $wpdb;
169
wppa_exit();
170
}
171
172
// The subject
173
- $subj = sprintf( __( 'New photo uploaded: %s' , 'wp-photo-album-plus'), wppa_get_photo_item( $pho, 'name' ) );
174
175
// The photo owner
176
$owner = get_user_by( 'login', wppa_get_photo_item( $pho, 'owner' ) );
@@ -184,7 +225,12 @@ global $wpdb;
184
$link = get_option( 'wppa_mailinglist_callback_url', '' );
185
186
// The content
187
- $cont = sprintf( __( 'User %1$s uploaded photo %2$s into album %3$s' , 'wp-photo-album-plus' ), $owner->display_name, $pho, wppa_get_album_name( $alb ) );
188
189
// Preview
190
if ( $link ) {
@@ -204,7 +250,7 @@ global $wpdb;
204
wppa_send_mail( array( 'to' => $user->user_email,
205
'subj' => $subj,
206
'cont' => $cont,
207
- 'photo' => $pho,
208
'listtype' => $type,
209
'unsubscribe' => wppa_unsubscribe_link( $usr, $type ),
210
));
@@ -220,6 +266,8 @@ global $wpdb;
220
}
221
}
222
}
223
}
224
break;
225
@@ -847,45 +895,67 @@ function wppa_send_mail( $args ) {
847
'Content-Type: text/html; charset=UTF-8'
848
);
849
850
- $message_part_1 .=
851
- '<html>' .
852
- '<head>' .
853
- '<title>'.$subj.'</title>' .
854
- '</head>' .
855
- '<body>' .
856
- '<h3>'.$subj.'</h3>' .
857
- ( $photo ? '<p><img src="'.wppa_get_thumb_url($photo).'" '.wppa_get_imgalt($photo).'/></p>' : '' );
858
- if ( is_array($cont) ) {
859
- foreach ( $cont as $c ) if ( $c ) {
860
- $message_part_1 .= '<p>'.$c.'</p>';
861
- }
862
- }
863
- else {
864
- $message_part_1 .= '<p>'.$cont.'</p>';
865
- }
866
867
- // Tell the moderator the email address of the originator of the photo/comment
868
- if ( $email && substr( $listtype, 0, 8 ) == 'moderate' ) {
869
870
- $eml = sprintf(__('The visitors email address is: <a href="mailto:%s">%s</a>', 'wp-photo-album-plus'), $email, $email);
871
- $message_part_2 .= '<p>'.$eml.'</p>';
872
- }
873
874
- if ( $replyurl ) {
875
- $message_part_2 .= '<a href="' . $replyurl . '" >' . __( 'Reply' , 'wp-photo-album-plus') . '</a>';
876
- }
877
878
- if ( $unsubscribe ) {
879
- $message_part_2 .= '<br />' . $unsubscribe;
880
- }
881
882
- $message_part_3 .=
883
- '<p>' .
884
- '<small>' .
885
- sprintf(__('This message is automatically generated at %s. It is useless to respond to it.', 'wp-photo-album-plus'), '<a href="'.home_url().'" >'.home_url().'</a>') .
886
- '</small>' .
887
- ( defined( 'WP_DEBUG' ) ? ' <small>(' . $listtype . ')</small>' : '' ) .
888
- '</p>' .
889
'</body>' .
890
'</html>';
891
@@ -898,7 +968,7 @@ function wppa_send_mail( $args ) {
898
$headers,
899
'' );
900
if ( $iret ) {
901
- wppa_log( 'eml', 'Mail send to: ' . $to . ' (' . $id . ') subject: ' . $subject . ', photo: ' . ( $photo ? $photo : 'not supplied.' ) );
902
return;
903
}
904
4
*
5
* Contains mailing functions
6
*
7
+ * Version 7.2.00
8
*
9
*/
10
24
// Call this function to schedule a mailinglist emission
25
function wppa_schedule_mailinglist( $type, $alb = 0, $pho = 0, $com = 0, $url = '', $start = 0, $delay = 120 ) {
26
27
+ // If feuploadnotify, see if one is pending, if so, do nothing
28
+ if ( $type == 'feuploadnotify' ) {
29
+
30
+ if ( ! $alb ) {
31
+ $alb = wppa_get_photo_item( $pho, 'album' );
32
+ }
33
+ $owner = wppa_get_photo_item( $pho, 'owner' );
34
+
35
+ $pending = get_option( 'last_feuploadnotify_scheduled-' . $owner . '-' . $alb, false );
36
+
37
+ if ( $pending ) {
38
+ return;
39
+ }
40
+
41
+ // Save this one to signal next that this one is pending
42
+ update_option( 'last_feuploadnotify_scheduled-' . $owner . '-' . $alb, $pho );
43
+ }
44
+
45
wp_schedule_single_event( time() + $delay, 'wppa_do_mailinglist_cron', array( $type, $alb, $pho, $com, $url, $start ) );
46
wppa_log( 'Eml', 'Mailinglist {b}' . $type . '{/b} ' . ( $start ? 're-' : '' ) . 'scheduled for run in ' . $delay . ' seconds. Args: ' . $alb . ', ' . $pho . ', ' . $com . ', ' . $url . ', ' . $start );
47
187
wppa_exit();
188
}
189
190
+ // See if there are more directly uploaded
191
+ wppa_log( 'dbg', 'last_sched='.get_option( 'last_feuploadnotify_scheduled',0));
192
+ $timestamp = wppa_get_photo_item( get_option( 'last_feuploadnotify_scheduled', $pho ), 'timestamp' );
193
+ $owner = wppa_get_photo_item( $pho, 'owner' );
194
+ $photos = $wpdb->get_col( "SELECT id
195
+ FROM $wpdb->wppa_photos
196
+ WHERE timestamp >= $timestamp
197
+ AND owner = '$owner'"
198
+ );
199
+ wppa_log('dbg', "query=SELECT id FROM $wpdb->wppa_photos WHERE timestamp >= $timestamp AND owner = $owner" );
200
+ wppa_log('dbg', 'photos='.serialize($photos));
201
+ $multi = count( $photos ) > 1;
202
+ wppa_log('dbg', 'multi='.$multi);
203
+
204
// The subject
205
+ if ( $multi ) {
206
+ $photonames = array();
207
+ foreach( $photos as $photo ) {
208
+ $photonames[] = wppa_get_photo_item( $photo, 'name' );
209
+ }
210
+ $subj = sprintf( __( 'New photos uploaded: %s', 'wp-photo-album-plus' ), implode( ', ', $photonames ) );
211
+ }
212
+ else {
213
+ $subj = sprintf( __( 'New photo uploaded: %s' , 'wp-photo-album-plus' ), wppa_get_photo_item( $pho, 'name' ) );
214
+ }
215
216
// The photo owner
217
$owner = get_user_by( 'login', wppa_get_photo_item( $pho, 'owner' ) );
225
$link = get_option( 'wppa_mailinglist_callback_url', '' );
226
227
// The content
228
+ if ( $multi ) {
229
+ $cont = sprintf( __( 'User %1$s uploaded photos %2$s into album %3$s' , 'wp-photo-album-plus' ), $owner->display_name, implode( ', ', $photos ), wppa_get_album_name( $alb ) );
230
+ }
231
+ else {
232
+ $cont = sprintf( __( 'User %1$s uploaded photo %2$s into album %3$s' , 'wp-photo-album-plus' ), $owner->display_name, $pho, wppa_get_album_name( $alb ) );
233
+ }
234
235
// Preview
236
if ( $link ) {
250
wppa_send_mail( array( 'to' => $user->user_email,
251
'subj' => $subj,
252
'cont' => $cont,
253
+ 'photo' => ( $multi ? $photos : $pho ),
254
'listtype' => $type,
255
'unsubscribe' => wppa_unsubscribe_link( $usr, $type ),
256
));
266
}
267
}
268
}
269
+ wppa_log('dbg', 'deleting option:' .'last_feuploadnotify_scheduled-' . $owner->user_login . '-' . $alb);
270
+ delete_option( 'last_feuploadnotify_scheduled-' . $owner->user_login . '-' . $alb );
271
}
272
break;
273
895
'Content-Type: text/html; charset=UTF-8'
896
);
897
898
+ $colspan = '1';
899
+ if ( is_array( $photo ) ) {
900
+ $colspan = count( $photo );
901
+ }
902
903
+ $message_part_1 .= '
904
+ <html>
905
+ <head>
906
+ </head>
907
+ <body>
908
+ <table>
909
+ <tbody>
910
+ <tr><td colspan="'.$colspan.'" ><h3>'.$subj.'</h3></td></tr>
911
+ <tr>';
912
+ if ( is_array( $photo ) ) {
913
+ $message_part_1 .= '<tr><td colspan="'.$colspan.'" >';
914
+ foreach( $photo as $p ) {
915
+ $message_part_1 .= '<img src="'.wppa_get_thumb_url($p).'" '.wppa_get_imgalt($p).' style="margin:auto 4px;" />';
916
+ }
917
+ $message_part_1 .= '</td></tr>';
918
+ }
919
+ elseif ( $photo ) {
920
+ $message_part_1 .= '<tr><td colspan="'.$colspan.'" ><img src="'.wppa_get_thumb_url($photo).'" '.wppa_get_imgalt($photo).'/></td></tr>';
921
+ }
922
923
+ if ( is_array( $cont ) ) {
924
+ foreach ( $cont as $c ) if ( $c ) {
925
+ $message_part_1 .= '<tr><td colspan="'.$colspan.'" >'.$c.'</td></tr>';
926
+ }
927
+ }
928
+ else {
929
+ $message_part_1 .= '<tr><td colspan="'.$colspan.'" >'.$cont.'</td></tr>';
930
+ }
931
932
+ // Tell the moderator the email address of the originator of the photo/comment
933
+ if ( $email && substr( $listtype, 0, 8 ) == 'moderate' ) {
934
935
+ $eml = sprintf(__('The visitors email address is: <a href="mailto:%s">%s</a>', 'wp-photo-album-plus'), $email, $email);
936
+ $message_part_2 .= '<tr><td colspan="'.$colspan.'" >'.$eml.'</td></tr>';
937
+ }
938
+
939
+ // Reply link
940
+ if ( $replyurl ) {
941
+ $message_part_2 .= '<tr><td colspan="'.$colspan.'" ><a href="' . $replyurl . '" >' . __( 'Reply' , 'wp-photo-album-plus') . '</a></td></tr>';
942
+ }
943
+
944
+ // Unsubscribe link
945
+ if ( $unsubscribe ) {
946
+ $message_part_2 .= '<tr><td colspan="'.$colspan.'" >' . $unsubscribe . '</td></tr>';
947
+ }
948
949
+ // Generic message
950
+ $message_part_3 .=
951
+ '<tr><td colspan="'.$colspan.'" >
952
+ <small>' .
953
+ sprintf(__('This message is automatically generated at %s. It is useless to respond to it.', 'wp-photo-album-plus'), '<a href="'.home_url().'" >'.home_url().'</a>') .
954
+ '</small>' .
955
+ ( defined( 'WP_DEBUG' ) ? ' <small>(' . $listtype . ')</small>' : '' ) . '
956
+ </td></tr>
957
+ </tbody>
958
+ </table>' .
959
'</body>' .
960
'</html>';
961
968
$headers,
969
'' );
970
if ( $iret ) {
971
+ wppa_log( 'eml', 'Mail send to: ' . $to . ' (' . $id . ') subject: ' . $subject . ', photo: ' . ( $photo ? ( is_array( $photo ) ? serialize( $photo ) : $photo ) : 'not supplied.' ) );
972
return;
973
}
974
wppa-non-admin.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* Contains all the non admin stuff
6
- * Version 7.1.06
7
*
8
*/
9
@@ -768,10 +768,11 @@ function wppa_redirect() {
768
}
769
770
/* ADD PAGE SPECIFIC ( http or https ) URLS */
771
- add_action( 'wp_head', 'wppa_add_page_specific_urls', '99' );
772
773
- function wppa_add_page_specific_urls() {
774
global $wppa_js_page_data;
775
776
$result = '
777
wppaImageDirectory = "' . wppa_get_imgdir() . '";
@@ -784,6 +785,33 @@ wppaIsSafari = ' . ( wppa_is_safari() ? 'true' : 'false' ) . ';
784
wppaUseSvg = ' . ( wppa_use_svg() ? 'true' : 'false' ) . ';
785
wppaSlideshowNavigationType = "' . wppa_get_navigation_type() . '";
786
wppaAudioHeight = '.wppa_get_audio_control_height().';
787
';
788
789
// Relative urls?
@@ -791,15 +819,15 @@ wppaAudioHeight = '.wppa_get_audio_control_height().';
791
792
if ( wppa_js_in_footer() ) {
793
$wppa_js_page_data .=
794
- "\n/* START Page specific urls and browser dependant data */" .
795
$result .
796
- "\n/* END Page specific urls and browser dependant data */\n";
797
}
798
else {
799
echo '
800
- <!-- WPPA+ START Page specific urls and browser dependant data -->
801
<script type="text/javascript" >' . $result . '</script>
802
- <!-- WPPA+ END Page specific urls -->';
803
}
804
}
805
@@ -938,127 +966,98 @@ global $wppa_init_js_data;
938
';
939
if ( ( WPPA_DEBUG || wppa_get_get( 'debug' ) || WP_DEBUG ) && ! wppa_switch( 'defer_javascript' ) ) {
940
$content .= '
941
- /* Check if wppa.js and jQuery are present */
942
- if (typeof(_wppaSlides) == \'undefined\') alert(\'There is a problem with your theme. The file wppa.js is not loaded when it is expected (Errloc = wppa_kickoff).\');
943
- if (typeof(jQuery) == \'undefined\') alert(\'There is a problem with your theme. The jQuery library is not loaded when it is expected (Errloc = wppa_kickoff).\');
944
'; }
945
/* This goes into wppa.js */
946
$content .= '
947
- wppaVersion = "'.$wppa_api_version.'";
948
- wppaDebug = '.( wppa_switch( 'allow_debug' ) ? 'true' : 'false' ).';
949
- wppaBackgroundColorImage = "'.wppa_opt( 'bgcolor_img' ).'";
950
- wppaPopupLinkType = "'.wppa_opt( 'thumb_linktype' ).'";
951
- wppaAnimationType = "'.wppa_opt( 'animation_type' ).'";
952
- wppaAnimationSpeed = '.wppa_opt( 'animation_speed' ).';
953
- wppaThumbnailAreaDelta = '.wppa_get_thumbnail_area_delta().';
954
- wppaTextFrameDelta = '.wppa_get_textframe_delta().';
955
- wppaBoxDelta = '.wppa_get_box_delta().';
956
- wppaSlideShowTimeOut = '.wppa_opt( 'slideshow_timeout' ).';
957
- wppaFilmShowGlue = '.( wppa_switch( 'film_show_glue') ? 'true' : 'false' ).';
958
- wppaSlideShow = "'.__('Slideshow', 'wp-photo-album-plus').'";
959
- wppaStart = "'.__('Start', 'wp-photo-album-plus').'";
960
- wppaStop = "'.__('Stop', 'wp-photo-album-plus').'";
961
- wppaSlower = "'.__('Slower', 'wp-photo-album-plus').'";
962
- wppaFaster = "'.__('Faster', 'wp-photo-album-plus').'";
963
- wppaPhoto = "'.__('Photo', 'wp-photo-album-plus').'";
964
- wppaOf = "'.__('of', 'wp-photo-album-plus').'";
965
- wppaPreviousPhoto = "'.__('Previous photo', 'wp-photo-album-plus').'";
966
- wppaNextPhoto = "'.__('Next photo', 'wp-photo-album-plus').'";
967
- wppaPrevP = "'.__('Prev.', 'wp-photo-album-plus').'";
968
- wppaNextP = "'.__('Next', 'wp-photo-album-plus').'";
969
- wppaAvgRating = "'.__('Average&nbsp;rating', 'wp-photo-album-plus').'";
970
- wppaMyRating = "'.__('My&nbsp;rating', 'wp-photo-album-plus').'";
971
- wppaAvgRat = "'.__('Avg.', 'wp-photo-album-plus').'";
972
- wppaMyRat = "'.__('Mine', 'wp-photo-album-plus').'";
973
- wppaDislikeMsg = "'.__('You marked this image as inappropriate.', 'wp-photo-album-plus').'";
974
- wppaMiniTreshold = '.( wppa_opt( 'mini_treshold' ) ? wppa_opt( 'mini_treshold' ) : '0' ).';
975
- wppaRatingOnce = '.( wppa_switch( 'rating_change') || wppa_switch( 'rating_multi') ? 'false' : 'true' ).';
976
- wppaPleaseName = "'.__('Please enter your name', 'wp-photo-album-plus').'";
977
- wppaPleaseEmail = "'.__('Please enter a valid email address', 'wp-photo-album-plus').'";
978
- wppaPleaseComment = "'.__('Please enter a comment', 'wp-photo-album-plus').'";
979
- wppaHideWhenEmpty = '.( wppa_switch( 'hide_when_empty') ? 'true' : 'false' ).';
980
- wppaBGcolorNumbar = "'.wppa_opt( 'bgcolor_numbar' ).'";
981
- wppaBcolorNumbar = "'.wppa_opt( 'bcolor_numbar' ).'";
982
- wppaBGcolorNumbarActive = "'.wppa_opt( 'bgcolor_numbar_active' ).'";
983
- wppaBcolorNumbarActive = "'.wppa_opt( 'bcolor_numbar_active' ).'";
984
- wppaFontFamilyNumbar = "'.wppa_opt( 'fontfamily_numbar' ).'";
985
- wppaFontSizeNumbar = "'.wppa_opt( 'fontsize_numbar' ).'px";
986
- wppaFontColorNumbar = "'.wppa_opt( 'fontcolor_numbar' ).'";
987
- wppaFontWeightNumbar = "'.wppa_opt( 'fontweight_numbar' ).'";
988
- wppaFontFamilyNumbarActive = "'.wppa_opt( 'fontfamily_numbar_active' ).'";
989
- wppaFontSizeNumbarActive = "'.wppa_opt( 'fontsize_numbar_active' ).'px";
990
- wppaFontColorNumbarActive = "'.wppa_opt( 'fontcolor_numbar_active' ).'";
991
- wppaFontWeightNumbarActive = "'.wppa_opt( 'fontweight_numbar_active' ).'";
992
- wppaNumbarMax = "'.wppa_opt( 'numbar_max' ).'";
993
- wppaLang = "'.$wppa_lang.'";
994
- wppaNextOnCallback = '.( wppa_switch( 'next_on_callback') ? 'true' : 'false' ).';
995
- wppaStarOpacity = '.str_replace(',', '.',( wppa_opt( 'star_opacity' )/'100' )).';
996
- wppaEmailRequired = "'.wppa_opt( 'comment_email_required').'";
997
- wppaSlideBorderWidth = '.$fbw.';
998
- wppaAllowAjax = '.( wppa_switch( 'allow_ajax') ? 'true' : 'false' ).';
999
- wppaUsePhotoNamesInUrls = '.( wppa_switch( 'use_photo_names_in_urls') ? 'true' : 'false' ).';
1000
- wppaThumbTargetBlank = '.( wppa_switch( 'thumb_blank') ? 'true' : 'false' ).';
1001
- wppaRatingMax = '.wppa_opt( 'rating_max' ).';
1002
- wppaRatingDisplayType = "'.wppa_opt( 'rating_display_type' ).'";
1003
- wppaRatingPrec = '.wppa_opt( 'rating_prec' ).';
1004
- wppaStretch = '.( wppa_switch( 'enlarge') ? 'true' : 'false' ).';
1005
- wppaMinThumbSpace = '.wppa_opt( 'tn_margin' ).';
1006
- wppaThumbSpaceAuto = '.( wppa_switch( 'thumb_auto') ? 'true' : 'false' ).';
1007
- wppaMagnifierCursor = "'.wppa_opt( 'magnifier' ).'";
1008
- wppaArtMonkyLink = "'.wppa_opt( 'art_monkey_link' ).'";
1009
- wppaAutoOpenComments = '.( wppa_switch( 'auto_open_comments') ? 'true' : 'false' ).';
1010
- wppaUpdateAddressLine = '.( wppa_switch( 'update_addressline') ? 'true' : 'false' ).';
1011
- wppaFilmThumbTitle = "'.( wppa_opt( 'film_linktype' ) == 'lightbox' ? wppa_zoom_in( false ) : __('Double click to start/stop slideshow running', 'wp-photo-album-plus') ).'";
1012
- wppaClickToView = "'.( wppa_opt( 'film_linktype' ) == 'lightbox' ? wppa_zoom_in( false ) : __('Click to view', 'wp-photo-album-plus') ).'";
1013
- wppaVoteForMe = "'.__(wppa_opt( 'vote_button_text' ), 'wp-photo-album-plus').'";
1014
- wppaVotedForMe = "'.__(wppa_opt( 'voted_button_text' ), 'wp-photo-album-plus').'";
1015
- wppaSlideSwipe = '.( wppa_switch( 'slide_swipe') ? 'true' : 'false' ).';
1016
- wppaMaxCoverWidth = '.wppa_opt( 'max_cover_width' ).';
1017
- wppaDownLoad = "'.__('Download', 'wp-photo-album-plus').'";
1018
- wppaSlideToFullpopup = '.( wppa_opt( 'slideshow_linktype' ) == 'fullpopup' ? 'true' : 'false' ).';
1019
- wppaComAltSize = '.wppa_opt( 'comten_alt_thumbsize' ).';
1020
- wppaBumpViewCount = '.( wppa_switch( 'track_viewcounts') ? 'true' : 'false' ).';
1021
- wppaBumpClickCount = '.( wppa_switch( 'track_clickcounts') ? 'true' : 'false' ).';
1022
- wppaShareHideWhenRunning = '.( wppa_switch( 'share_hide_when_running') ? 'true' : 'false' ).';
1023
- wppaFotomoto = '.( wppa_switch( 'fotomoto_on') ? 'true' : 'false' ).';
1024
- wppaArtMonkeyButton = '.( wppa_opt( 'art_monkey_display' ) == 'button' ? 'true' : 'false' ).';
1025
- wppaFotomotoHideWhenRunning = '.( wppa_switch( 'fotomoto_hide_when_running') ? 'true' : 'false' ).';
1026
- wppaCommentRequiredAfterVote = '.( wppa_switch( 'vote_needs_comment') ? 'true' : 'false' ).';
1027
- wppaFotomotoMinWidth = '.wppa_opt( 'fotomoto_min_width' ).';
1028
- wppaShortQargs = '.( wppa_switch( 'use_short_qargs') ? 'true' : 'false' ).';
1029
- wppaOvlHires = '.( wppa_switch( 'lb_hres' ) ? 'true' : 'false' ).';
1030
- wppaSlideVideoStart = '.( wppa_switch( 'start_slide_video' ) ? 'true' : 'false' ).';
1031
- wppaSlideAudioStart = '.( wppa_switch( 'start_slide_audio' ) ? 'true' : 'false' ).';
1032
- wppaRel = "'.( wppa_opt( 'lightbox_name' ) == 'wppa' ? 'data-rel' : 'rel' ).'";
1033
- wppaOvlRadius = '.wppa_opt( 'ovl_border_radius' ).';
1034
- wppaOvlBorderWidth = '.wppa_opt( 'ovl_border_width' ).';
1035
- wppaEditPhotoWidth = "'.(wppa_opt( 'upload_edit' ) == 'new' ? 500 : 960).'";
1036
- wppaThemeStyles = "'.(wppa_switch( 'upload_edit_theme_css') ? get_stylesheet_uri() : '' ).'";
1037
- wppaStickyHeaderHeight = '.wppa_opt( 'sticky_header_size' ).';
1038
- wppaRenderModal = ' . ( wppa_switch( 'ajax_render_modal' ) ? 'true' : 'false' ) . ';
1039
- wppaModalQuitImg = "url(' . wppa_get_imgdir( 'smallcross-' . wppa_opt( 'ovl_theme') . '.gif' ) . ')";
1040
- wppaBoxRadius = "' . wppa_opt( 'bradius' ) . '";
1041
- wppaModalBgColor = "' . wppa_opt( 'bgcolor_modal' ) . '";
1042
- wppaUploadEdit = "' . wppa_opt( 'upload_edit' ) . '";
1043
- wppaSvgFillcolor = "' . wppa_opt( 'svg_color' ) . '";
1044
- wppaSvgBgcolor = "' . wppa_opt( 'svg_bg_color' ) . '";
1045
- wppaOvlSvgFillcolor = "' . wppa_opt( 'ovl_svg_color' ) . '";
1046
- wppaOvlSvgBgcolor = "' . wppa_opt( 'ovl_svg_bg_color' ) . '";
1047
- wppaSvgCornerStyle = "' . wppa_opt( 'icon_corner_style' ) . '";
1048
- wppaHideRightClick = ' . ( wppa_switch( 'no_rightclick' ) ? 'true' : 'false' ) . ';
1049
- wppaProcessing = "' . __( 'Processing...', 'wp-photo-album-plus' ) . '";
1050
- wppaDone = "' . __( 'Done!', 'wp-photo-album-plus' ) . '";
1051
- wppaUploadFailed = "' . __( 'Upload failed', 'wp-photo-album-plus' ) . '";
1052
- wppaServerError = "' . __( 'Server error.', 'wp-photo-album-plus' ) . '";
1053
- wppaGeoZoom = ' . wppa_opt( 'geo_zoom' ) . ';
1054
- wppaLazyLoad = ' . ( wppa_switch( 'lazy' ) ? 'true' : 'false' ) . ';
1055
- wppaAreaMaxFrac = ' . ( wppa_opt( 'area_size' ) < 1 ? wppa_opt( 'area_size' ) : 1.0 ) . ';
1056
- wppaNiceScroll = ' . ( wppa_switch( 'nicescroll' ) ? 'true' : 'false' ) . ';
1057
- wppaIconSizeNormal = "' . wppa_opt( 'nav_icon_size' ) . '";
1058
- wppaIconSizeSlide = "' . wppa_opt( 'nav_icon_size_slide' ) . '";
1059
- wppaResponseSpeed = ' . wppa_opt( 'response_speed' ) . ';
1060
- wppaExtendedResizeCount = ' . wppa_opt( 'extended_resize_count' ) . ';
1061
- wppaExtendedResizeDelay = ' . wppa_opt( 'extended_resize_delay' ) . ';
1062
';
1063
1064
// Open file
3
* Package: wp-photo-album-plus
4
*
5
* Contains all the non admin stuff
6
+ * Version 7.2.00
7
*
8
*/
9
768
}
769
770
/* ADD PAGE SPECIFIC ( http or https ) URLS */
771
+ add_action( 'wp_head', 'wppa_add_page_specific_urls_and_language', '99' );
772
773
+ function wppa_add_page_specific_urls_and_language() {
774
global $wppa_js_page_data;
775
+ global $wppa_lang;
776
777
$result = '
778
wppaImageDirectory = "' . wppa_get_imgdir() . '";
785
wppaUseSvg = ' . ( wppa_use_svg() ? 'true' : 'false' ) . ';
786
wppaSlideshowNavigationType = "' . wppa_get_navigation_type() . '";
787
wppaAudioHeight = '.wppa_get_audio_control_height().';
788
+ wppaFilmThumbTitle = "'.( wppa_opt( 'film_linktype' ) == 'lightbox' ? wppa_zoom_in( false ) : __('Double click to start/stop slideshow running', 'wp-photo-album-plus') ).'";
789
+ wppaClickToView = "'.( wppa_opt( 'film_linktype' ) == 'lightbox' ? wppa_zoom_in( false ) : __('Click to view', 'wp-photo-album-plus') ).'";
790
+ wppaLang = "'.$wppa_lang.'";
791
+ wppaVoteForMe = "'.__(wppa_opt( 'vote_button_text' ), 'wp-photo-album-plus').'";
792
+ wppaVotedForMe = "'.__(wppa_opt( 'voted_button_text' ), 'wp-photo-album-plus').'";
793
+ wppaDownLoad = "'.__('Download', 'wp-photo-album-plus').'";
794
+ wppaSlideShow = "'.__('Slideshow', 'wp-photo-album-plus').'";
795
+ wppaPhoto = "'.__('Photo', 'wp-photo-album-plus' ).'";
796
+ wppaOf = "'.__('of', 'wp-photo-album-plus' ).'";
797
+ wppaNextPhoto = "'.__('Next photo', 'wp-photo-album-plus').'";
798
+ wppaPreviousPhoto = "'.__('Previous photo', 'wp-photo-album-plus').'";
799
+ wppaNextP = "'.__('Next', 'wp-photo-album-plus' ).'";
800
+ wppaPrevP = "'.__('Prev.', 'wp-photo-album-plus').'";
801
+ wppaAvgRating = "'.__('Average&nbsp;rating', 'wp-photo-album-plus').'";
802
+ wppaMyRating = "'.__('My&nbsp;rating', 'wp-photo-album-plus').'";
803
+ wppaAvgRat = "'.__('Avg.', 'wp-photo-album-plus').'";
804
+ wppaMyRat = "'.__('Mine', 'wp-photo-album-plus').'";
805
+ wppaDislikeMsg = "'.__('You marked this image as inappropriate.', 'wp-photo-album-plus').'";
806
+ wppaStart = "'.__('Start', 'wp-photo-album-plus').'";
807
+ wppaStop = "'.__('Stop', 'wp-photo-album-plus').'";
808
+ wppaPleaseName = "'.__('Please enter your name', 'wp-photo-album-plus').'";
809
+ wppaPleaseEmail = "'.__('Please enter a valid email address', 'wp-photo-album-plus').'";
810
+ wppaPleaseComment = "'.__('Please enter a comment', 'wp-photo-album-plus').'";
811
+ wppaProcessing = "'.__('Processing...', 'wp-photo-album-plus').'";
812
+ wppaDone = "'.__('Done!', 'wp-photo-album-plus').'";
813
+ wppaUploadFailed = "'.__('Upload failed', 'wp-photo-album-plus').'";
814
+ wppaServerError = "'.__('Server error.', 'wp-photo-album-plus').'";
815
';
816
817
// Relative urls?
819
820
if ( wppa_js_in_footer() ) {
821
$wppa_js_page_data .=
822
+ "\n/* WPPA+ START Page/language dependant data */" .
823
$result .
824
+ "\n/* WPPA+ END Page/language dependant data */\n";
825
}
826
else {
827
echo '
828
+ <!-- WPPA+ START Page/language dependant data -->
829
<script type="text/javascript" >' . $result . '</script>
830
+ <!-- WPPA+ END Page/language dependant data -->';
831
}
832
}
833
966
';
967
if ( ( WPPA_DEBUG || wppa_get_get( 'debug' ) || WP_DEBUG ) && ! wppa_switch( 'defer_javascript' ) ) {
968
$content .= '
969
+ /* Check if wppa.js and jQuery are present */
970
+ if (typeof(_wppaSlides) == \'undefined\') alert(\'There is a problem with your theme. The file wppa.js is not loaded when it is expected (Errloc = wppa_kickoff).\');
971
+ if (typeof(jQuery) == \'undefined\') alert(\'There is a problem with your theme. The jQuery library is not loaded when it is expected (Errloc = wppa_kickoff).\');
972
'; }
973
/* This goes into wppa.js */
974
$content .= '
975
+ wppaVersion = "'.$wppa_api_version.'";
976
+ wppaDebug = '.( wppa_switch( 'allow_debug' ) ? 'true' : 'false' ).';
977
+ wppaBackgroundColorImage = "'.wppa_opt( 'bgcolor_img' ).'";
978
+ wppaPopupLinkType = "'.wppa_opt( 'thumb_linktype' ).'";
979
+ wppaAnimationType = "'.wppa_opt( 'animation_type' ).'";
980
+ wppaAnimationSpeed = '.wppa_opt( 'animation_speed' ).';
981
+ wppaThumbnailAreaDelta = '.wppa_get_thumbnail_area_delta().';
982
+ wppaTextFrameDelta = '.wppa_get_textframe_delta().';
983
+ wppaBoxDelta = '.wppa_get_box_delta().';
984
+ wppaSlideShowTimeOut = '.wppa_opt( 'slideshow_timeout' ).';
985
+ wppaFilmShowGlue = '.( wppa_switch( 'film_show_glue') ? 'true' : 'false' ).';
986
+ wppaMiniTreshold = '.( wppa_opt( 'mini_treshold' ) ? wppa_opt( 'mini_treshold' ) : '0' ).';
987
+ wppaRatingOnce = '.( wppa_switch( 'rating_change') || wppa_switch( 'rating_multi') ? 'false' : 'true' ).';
988
+ wppaHideWhenEmpty = '.( wppa_switch( 'hide_when_empty') ? 'true' : 'false' ).';
989
+ wppaBGcolorNumbar = "'.wppa_opt( 'bgcolor_numbar' ).'";
990
+ wppaBcolorNumbar = "'.wppa_opt( 'bcolor_numbar' ).'";
991
+ wppaBGcolorNumbarActive = "'.wppa_opt( 'bgcolor_numbar_active' ).'";
992
+ wppaBcolorNumbarActive = "'.wppa_opt( 'bcolor_numbar_active' ).'";
993
+ wppaFontFamilyNumbar = "'.wppa_opt( 'fontfamily_numbar' ).'";
994
+ wppaFontSizeNumbar = "'.wppa_opt( 'fontsize_numbar' ).'px";
995
+ wppaFontColorNumbar = "'.wppa_opt( 'fontcolor_numbar' ).'";
996
+ wppaFontWeightNumbar = "'.wppa_opt( 'fontweight_numbar' ).'";
997
+ wppaFontFamilyNumbarActive = "'.wppa_opt( 'fontfamily_numbar_active' ).'";
998
+ wppaFontSizeNumbarActive = "'.wppa_opt( 'fontsize_numbar_active' ).'px";
999
+ wppaFontColorNumbarActive = "'.wppa_opt( 'fontcolor_numbar_active' ).'";
1000
+ wppaFontWeightNumbarActive = "'.wppa_opt( 'fontweight_numbar_active' ).'";
1001
+ wppaNumbarMax = "'.wppa_opt( 'numbar_max' ).'";
1002
+ wppaNextOnCallback = '.( wppa_switch( 'next_on_callback') ? 'true' : 'false' ).';
1003
+ wppaStarOpacity = '.str_replace(',', '.',( wppa_opt( 'star_opacity' )/'100' )).';
1004
+ wppaEmailRequired = "'.wppa_opt( 'comment_email_required').'";
1005
+ wppaSlideBorderWidth = '.$fbw.';
1006
+ wppaAllowAjax = '.( wppa_switch( 'allow_ajax') ? 'true' : 'false' ).';
1007
+ wppaUsePhotoNamesInUrls = '.( wppa_switch( 'use_photo_names_in_urls') ? 'true' : 'false' ).';
1008
+ wppaThumbTargetBlank = '.( wppa_switch( 'thumb_blank') ? 'true' : 'false' ).';
1009
+ wppaRatingMax = '.wppa_opt( 'rating_max' ).';
1010
+ wppaRatingDisplayType = "'.wppa_opt( 'rating_display_type' ).'";
1011
+ wppaRatingPrec = '.wppa_opt( 'rating_prec' ).';
1012
+ wppaStretch = '.( wppa_switch( 'enlarge') ? 'true' : 'false' ).';
1013
+ wppaMinThumbSpace = '.wppa_opt( 'tn_margin' ).';
1014
+ wppaThumbSpaceAuto = '.( wppa_switch( 'thumb_auto') ? 'true' : 'false' ).';
1015
+ wppaMagnifierCursor = "'.wppa_opt( 'magnifier' ).'";
1016
+ wppaArtMonkyLink = "'.wppa_opt( 'art_monkey_link' ).'";
1017
+ wppaAutoOpenComments = '.( wppa_switch( 'auto_open_comments') ? 'true' : 'false' ).';
1018
+ wppaUpdateAddressLine = '.( wppa_switch( 'update_addressline') ? 'true' : 'false' ).';
1019
+ wppaSlideSwipe = '.( wppa_switch( 'slide_swipe') ? 'true' : 'false' ).';
1020
+ wppaMaxCoverWidth = '.wppa_opt( 'max_cover_width' ).';
1021
+ wppaSlideToFullpopup = '.( wppa_opt( 'slideshow_linktype' ) == 'fullpopup' ? 'true' : 'false' ).';
1022
+ wppaComAltSize = '.wppa_opt( 'comten_alt_thumbsize' ).';
1023
+ wppaBumpViewCount = '.( wppa_switch( 'track_viewcounts') ? 'true' : 'false' ).';
1024
+ wppaBumpClickCount = '.( wppa_switch( 'track_clickcounts') ? 'true' : 'false' ).';
1025
+ wppaShareHideWhenRunning = '.( wppa_switch( 'share_hide_when_running') ? 'true' : 'false' ).';
1026
+ wppaFotomoto = '.( wppa_switch( 'fotomoto_on') ? 'true' : 'false' ).';
1027
+ wppaArtMonkeyButton = '.( wppa_opt( 'art_monkey_display' ) == 'button' ? 'true' : 'false' ).';
1028
+ wppaFotomotoHideWhenRunning = '.( wppa_switch( 'fotomoto_hide_when_running') ? 'true' : 'false' ).';
1029
+ wppaCommentRequiredAfterVote = '.( wppa_switch( 'vote_needs_comment') ? 'true' : 'false' ).';
1030
+ wppaFotomotoMinWidth = '.wppa_opt( 'fotomoto_min_width' ).';
1031
+ wppaShortQargs = '.( wppa_switch( 'use_short_qargs') ? 'true' : 'false' ).';
1032
+ wppaOvlHires = '.( wppa_switch( 'lb_hres' ) ? 'true' : 'false' ).';
1033
+ wppaSlideVideoStart = '.( wppa_switch( 'start_slide_video' ) ? 'true' : 'false' ).';
1034
+ wppaSlideAudioStart = '.( wppa_switch( 'start_slide_audio' ) ? 'true' : 'false' ).';
1035
+ wppaRel = "'.( wppa_opt( 'lightbox_name' ) == 'wppa' ? 'data-rel' : 'rel' ).'";
1036
+ wppaOvlRadius = '.wppa_opt( 'ovl_border_radius' ).';
1037
+ wppaOvlBorderWidth = '.wppa_opt( 'ovl_border_width' ).';
1038
+ wppaEditPhotoWidth = "'.(wppa_opt( 'upload_edit' ) == 'new' ? 500 : 960).'";
1039
+ wppaThemeStyles = "'.(wppa_switch( 'upload_edit_theme_css') ? get_stylesheet_uri() : '' ).'";
1040
+ wppaStickyHeaderHeight = '.wppa_opt( 'sticky_header_size' ).';
1041
+ wppaRenderModal = ' . ( wppa_switch( 'ajax_render_modal' ) ? 'true' : 'false' ) . ';
1042
+ wppaModalQuitImg = "url(' . wppa_get_imgdir( 'smallcross-' . wppa_opt( 'ovl_theme') . '.gif' ) . ')";
1043
+ wppaBoxRadius = "' . wppa_opt( 'bradius' ) . '";
1044
+ wppaModalBgColor = "' . wppa_opt( 'bgcolor_modal' ) . '";
1045
+ wppaUploadEdit = "' . wppa_opt( 'upload_edit' ) . '";
1046
+ wppaSvgFillcolor = "' . wppa_opt( 'svg_color' ) . '";
1047
+ wppaSvgBgcolor = "' . wppa_opt( 'svg_bg_color' ) . '";
1048
+ wppaOvlSvgFillcolor = "' . wppa_opt( 'ovl_svg_color' ) . '";
1049
+ wppaOvlSvgBgcolor = "' . wppa_opt( 'ovl_svg_bg_color' ) . '";
1050
+ wppaSvgCornerStyle = "' . wppa_opt( 'icon_corner_style' ) . '";
1051
+ wppaHideRightClick = ' . ( wppa_switch( 'no_rightclick' ) ? 'true' : 'false' ) . ';
1052
+ wppaGeoZoom = ' . wppa_opt( 'geo_zoom' ) . ';
1053
+ wppaLazyLoad = ' . ( wppa_switch( 'lazy' ) ? 'true' : 'false' ) . ';
1054
+ wppaAreaMaxFrac = ' . ( wppa_opt( 'area_size' ) < 1 ? wppa_opt( 'area_size' ) : 1.0 ) . ';
1055
+ wppaNiceScroll = ' . ( wppa_switch( 'nicescroll' ) ? 'true' : 'false' ) . ';
1056
+ wppaIconSizeNormal = "' . wppa_opt( 'nav_icon_size' ) . '";
1057
+ wppaIconSizeSlide = "' . wppa_opt( 'nav_icon_size_slide' ) . '";
1058
+ wppaResponseSpeed = ' . wppa_opt( 'response_speed' ) . ';
1059
+ wppaExtendedResizeCount = ' . wppa_opt( 'extended_resize_count' ) . ';
1060
+ wppaExtendedResizeDelay = ' . wppa_opt( 'extended_resize_delay' ) . ';
1061
';
1062
1063
// Open file
wppa-photo-admin-autosave.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* edit and delete photos
6
- * Version 7.1.11
7
*
8
*/
9
@@ -541,6 +541,7 @@ function wppaToggleExif( id, count ) {
541
$scheduledel = $photo['scheduledel'];
542
$ext = $photo['ext'];
543
$sname = $photo['sname'];
544
545
// See if item is a multimedia item
546
$is_multi = wppa_is_multi( $id );
@@ -860,6 +861,14 @@ function wppaToggleExif( id, count ) {
860
'. ';
861
}
862
863
// Status
864
echo '<br />' .
865
__( 'Status:' , 'wp-photo-album-plus') . ' ';
@@ -2039,7 +2048,7 @@ function wppaToggleExif( id, count ) {
2039
'<td>' .
2040
'<small>' .
2041
sprintf( __( 'See %s The documentation %s for more shortcode options.', 'wp-photo-album-plus' ),
2042
- '<a href="http://wppa.nl/shortcode-reference/" target="_blank" >',
2043
'</a>'
2044
) .
2045
'</small>' .
3
* Package: wp-photo-album-plus
4
*
5
* edit and delete photos
6
+ * Version 7.2.00
7
*
8
*/
9
541
$scheduledel = $photo['scheduledel'];
542
$ext = $photo['ext'];
543
$sname = $photo['sname'];
544
+ $dlcount = $photo['dlcount'];
545
546
// See if item is a multimedia item
547
$is_multi = wppa_is_multi( $id );
861
'. ';
862
}
863
864
+ // Downloads
865
+ if ( true ) {
866
+ echo
867
+ __( 'Downloads', 'wp-photo-album-plus' ) . ': ' .
868
+ htmlentities( $dlcount ) .
869
+ '. ';
870
+ }
871
+
872
// Status
873
echo '<br />' .
874
__( 'Status:' , 'wp-photo-album-plus') . ' ';
2048
'<td>' .
2049
'<small>' .
2050
sprintf( __( 'See %s The documentation %s for more shortcode options.', 'wp-photo-album-plus' ),
2051
+ '<a href="https://wppa.nl/shortcode-reference/" target="_blank" >',
2052
'</a>'
2053
) .
2054
'</small>' .
wppa-picture.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* Make the picture html
6
- * Version 7.1.00
7
*
8
*/
9
@@ -159,6 +159,13 @@ function wppa_get_picture_html( $args ) {
159
$audiobody = esc_attr( wppa_get_audio_body( $id ) );
160
$videox = wppa_get_videox( $id );
161
$videoy = wppa_get_videoy( $id );
162
$result .=
163
'<a' .
164
' href="' . $link['url'] . '"' .
@@ -168,7 +175,7 @@ function wppa_get_picture_html( $args ) {
168
( $is_pdf ? ' data-pdfhtml="' . esc_attr( wppa_get_pdf_html( $id ) ) .'"' : '' ) .
169
( $videox ? ' data-videonatwidth="' . $videox . '"' : '' ) .
170
( $videoy ? ' data-videonatheight="' . $videoy . '"' : '' ) .
171
- ' ' . wppa( 'rel' ) . '="'.wppa_opt( 'lightbox_name' ).'"' .
172
wppa_get_lb_panorama_full_html( $id ) .
173
( $link['target'] ? ' target="' . $link['target'] . '"' : '' ) .
174
' class="thumb-img"' .
3
* Package: wp-photo-album-plus
4
*
5
* Make the picture html
6
+ * Version 7.2.00
7
*
8
*/
9
159
$audiobody = esc_attr( wppa_get_audio_body( $id ) );
160
$videox = wppa_get_videox( $id );
161
$videoy = wppa_get_videoy( $id );
162
+ if ( $type == 'photo' || $type == 'mphoto' || $type == 'xphoto' ) {
163
+ $setname = '['.$type.']';
164
+ }
165
+ else {
166
+ $setname = '';
167
+ }
168
+
169
$result .=
170
'<a' .
171
' href="' . $link['url'] . '"' .
175
( $is_pdf ? ' data-pdfhtml="' . esc_attr( wppa_get_pdf_html( $id ) ) .'"' : '' ) .
176
( $videox ? ' data-videonatwidth="' . $videox . '"' : '' ) .
177
( $videoy ? ' data-videonatheight="' . $videoy . '"' : '' ) .
178
+ ' ' . wppa( 'rel' ) . '="'.wppa_opt( 'lightbox_name' ).$setname.'"' .
179
wppa_get_lb_panorama_full_html( $id ) .
180
( $link['target'] ? ' target="' . $link['target'] . '"' : '' ) .
181
' class="thumb-img"' .
wppa-settings-autosave.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* manage all options
6
- * Version 7.1.11
7
*
8
*/
9
@@ -5066,8 +5066,11 @@ global $wppa_supported_camara_brands;
5066
$desc = __('The top sort item used for topten results from shortcodes.', 'wp-photo-album-plus');
5067
$help = '';
5068
$slug = 'wppa_topten_sortby';
5069
- $opts = array( __('Mean raiting', 'wp-photo-album-plus'), __('Rating count', 'wp-photo-album-plus'), __('Viewcount', 'wp-photo-album-plus') );
5070
- $vals = array( 'mean_rating', 'rating_count', 'views' );
5071
$html = wppa_select($slug, $opts, $vals);
5072
$clas = '';
5073
$tags = 'rating,layout';
@@ -9393,7 +9396,7 @@ global $wppa_supported_camara_brands;
9393
9394
$name = __('Sanitize files', 'wp-photo-album-plus');
9395
$desc = __('Sanitize filenames during import/upload', 'wp-photo-album-plus');
9396
- $help = __('It is STRONGLY recommended to keep this box checked!', 'wp-photo-album-plus');
9397
$slug = 'wppa_sanitize_import';
9398
$html = wppa_checkbox($slug);
9399
$clas = '';
@@ -9402,7 +9405,7 @@ global $wppa_supported_camara_brands;
9402
9403
$name = __('Remove accents', 'wp-photo-album-plus');
9404
$desc = __('Remove accents from filenames during import/upload', 'wp-photo-album-plus');
9405
- $help = sprintf( __('See %s for details', 'wp-photo-album-plus'), make_clickable('https://developer.wordpress.org/reference/functions/remove_accents/') );
9406
$slug = 'wppa_remove_accents';
9407
$html = wppa_checkbox($slug);
9408
$clas = '';
3
* Package: wp-photo-album-plus
4
*
5
* manage all options
6
+ * Version 7.2.00
7
*
8
*/
9
5066
$desc = __('The top sort item used for topten results from shortcodes.', 'wp-photo-album-plus');
5067
$help = '';
5068
$slug = 'wppa_topten_sortby';
5069
+ $opts = array( __('Mean raiting', 'wp-photo-album-plus'),
5070
+ __('Rating count', 'wp-photo-album-plus'),
5071
+ __('Viewcount', 'wp-photo-album-plus'),
5072
+ __('Downloads', 'wp-photo-album-plus'));
5073
+ $vals = array( 'mean_rating', 'rating_count', 'views', 'dlcount' );
5074
$html = wppa_select($slug, $opts, $vals);
5075
$clas = '';
5076
$tags = 'rating,layout';
9396
9397
$name = __('Sanitize files', 'wp-photo-album-plus');
9398
$desc = __('Sanitize filenames during import/upload', 'wp-photo-album-plus');
9399
+ $help = '';
9400
$slug = 'wppa_sanitize_import';
9401
$html = wppa_checkbox($slug);
9402
$clas = '';
9405
9406
$name = __('Remove accents', 'wp-photo-album-plus');
9407
$desc = __('Remove accents from filenames during import/upload', 'wp-photo-album-plus');
9408
+ $help = '';
9409
$slug = 'wppa_remove_accents';
9410
$html = wppa_checkbox($slug);
9411
$clas = '';
wppa-setup.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* Contains all the setup stuff
6
- * Version 7.1.11
7
*
8
*/
9
@@ -112,6 +112,7 @@ global $wppa_error;
112
indexdtm tinytext NOT NULL,
113
panorama smallint(5) NOT NULL default '0',
114
sname text NOT NULL,
115
PRIMARY KEY (id),
116
KEY albumkey (album),
117
KEY statuskey (status(6))
@@ -1787,8 +1788,8 @@ cursorborder:'2px solid transparent',";
1787
'wppa_frontend_album_public' => 'no',
1788
'wppa_optimize_new' => 'no',
1789
'wppa_default_album_linktype' => 'content',
1790
- 'wppa_sanitize_import' => 'yes',
1791
- 'wppa_remove_accents' => 'no',
1792
1793
// E Search
1794
'wppa_search_linkpage' => '0', // 1
3
* Package: wp-photo-album-plus
4
*
5
* Contains all the setup stuff
6
+ * Version 7.2.00
7
*
8
*/
9
112
indexdtm tinytext NOT NULL,
113
panorama smallint(5) NOT NULL default '0',
114
sname text NOT NULL,
115
+ dlcount bigint(20) NOT NULL default '0',
116
PRIMARY KEY (id),
117
KEY albumkey (album),
118
KEY statuskey (status(6))
1788
'wppa_frontend_album_public' => 'no',
1789
'wppa_optimize_new' => 'no',
1790
'wppa_default_album_linktype' => 'content',
1791
+ 'wppa_sanitize_import' => 'no',
1792
+ 'wppa_remove_accents' => 'yes',
1793
1794
// E Search
1795
'wppa_search_linkpage' => '0', // 1
wppa-topten-widget.php CHANGED
@@ -3,7 +3,7 @@
3
* Package: wp-photo-album-plus
4
*
5
* display the top rated photos
6
- * Version 7.1.10
7
*/
8
9
class TopTenWidget extends WP_Widget {
@@ -17,6 +17,7 @@ class TopTenWidget extends WP_Widget {
17
'meanrat' => 'yes',
18
'ratcount' => 'yes',
19
'viewcount' => 'yes',
20
'includesubs' => 'yes',
21
'medalsonly' => 'no',
22
'showowner' => 'no',
@@ -71,6 +72,7 @@ class TopTenWidget extends WP_Widget {
71
$meanrat = wppa_checked( $instance['meanrat'] ) ? 'yes' : false;
72
$ratcount = wppa_checked( $instance['ratcount'] ) ? 'yes' : false;
73
$viewcount = wppa_checked( $instance['viewcount'] ) ? 'yes' : false;
74
$includesubs = wppa_checked( $instance['includesubs'] ) ? 'yes' : false;
75
$albenum = '';
76
$medalsonly = wppa_checked( $instance['medalsonly'] ) ? 'yes' : false;
@@ -89,9 +91,12 @@ class TopTenWidget extends WP_Widget {
89
// Non-zero
90
$non_zero = "";
91
if ( wppa_switch( 'topten_non_zero' ) ) {
92
- if ( wppa_opt( 'topten_sortby' ) == 'views' ) {
93
$non_zero = "AND views > 0 ";
94
}
95
else {
96
$non_zero = "AND rating_count > 0 ";
97
}
@@ -182,8 +187,7 @@ class TopTenWidget extends WP_Widget {
182
LIMIT %d";
183
break;
184
185
- // case 'mean_rating':
186
- default:
187
$query = "SELECT * FROM $wpdb->wppa_photos
188
WHERE album IN ( aaaa )
189
$non_zero
@@ -191,6 +195,14 @@ class TopTenWidget extends WP_Widget {
191
LIMIT %d";
192
break;
193
194
}
195
$thumbs = $wpdb->get_results( $wpdb->prepare( str_replace( 'aaaa', $album, $query ), $max ), ARRAY_A );
196
}
@@ -219,8 +231,7 @@ class TopTenWidget extends WP_Widget {
219
LIMIT %d";
220
break;
221
222
- // case 'mean_rating':
223
- default:
224
$query = "SELECT * FROM $wpdb->wppa_photos
225
WHERE album > 0
226
AND status IN ( 'gold', 'silver', 'bronze' )
@@ -229,6 +240,15 @@ class TopTenWidget extends WP_Widget {
229
LIMIT %d";
230
break;
231
232
}
233
$thumbs = $wpdb->get_results( $wpdb->prepare( $query, $max ), ARRAY_A );
234
}
@@ -252,8 +272,7 @@ class TopTenWidget extends WP_Widget {
252
LIMIT %d";
253
break;
254
255
- // case 'mean_rating':
256
- default:
257
$query = "SELECT * FROM $wpdb->wppa_photos
258
WHERE album > 0
259
$non_zero
@@ -261,6 +280,15 @@ class TopTenWidget extends WP_Widget {
261
LIMIT %d";
262
break;
263
264
}
265
266
$thumbs = $wpdb->get_results( $wpdb->prepare( $query, $max ), ARRAY_A );
@@ -358,6 +386,15 @@ class TopTenWidget extends WP_Widget {
358
sprintf( _n( '%d view', '%d views', $n, 'wp-photo-album-plus' ), $n ) .
359
'</div>';
360
}
361
break;
362
363
case 'rating_count':
@@ -381,9 +418,57 @@ class TopTenWidget extends WP_Widget {
381
sprintf( _n( '%d view', '%d views', $n, 'wp-photo-album-plus' ), $n ) .
382
'</div>';
383
}
384
break;
385
386
case 'views':
387
if ( $viewcount == 'yes' ) {
388
$n = $image['views'];
389
$widget_content .=
@@ -468,10 +553,12 @@ class TopTenWidget extends WP_Widget {
468
$options = array( __( 'Mean value', 'wp-photo-album-plus' ),
469
__( 'Number of votes', 'wp-photo-album-plus' ),
470
__( 'Number of views', 'wp-photo-album-plus' ),
471
);
472
$values = array( 'mean_rating',
473
'rating_count',
474
'views',
475
);
476
echo
477
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values );
@@ -502,7 +589,10 @@ class TopTenWidget extends WP_Widget {
502
wppa_widget_checkbox( $this, 'ratcount', $instance['ratcount'], __( 'Rating count', 'wp-photo-album-plus' ) ) .
503
504
// View count
505
- wppa_widget_checkbox( $this, 'viewcount', $instance['viewcount'], __( 'View count', 'wp-photo-album-plus' ) );
506
507
echo
508
'</div>';
3
* Package: wp-photo-album-plus
4
*
5
* display the top rated photos
6
+ * Version 7.2.00
7
*/
8
9
class TopTenWidget extends WP_Widget {
17
'meanrat' => 'yes',
18
'ratcount' => 'yes',
19
'viewcount' => 'yes',
20
+ 'dlcount' => 'yes',
21
'includesubs' => 'yes',
22
'medalsonly' => 'no',
23
'showowner' => 'no',
72
$meanrat = wppa_checked( $instance['meanrat'] ) ? 'yes' : false;
73
$ratcount = wppa_checked( $instance['ratcount'] ) ? 'yes' : false;
74
$viewcount = wppa_checked( $instance['viewcount'] ) ? 'yes' : false;
75
+ $dlcount = wppa_checked( $instance['dlcount'] ) ? 'yes' : false;
76
$includesubs = wppa_checked( $instance['includesubs'] ) ? 'yes' : false;
77
$albenum = '';
78
$medalsonly = wppa_checked( $instance['medalsonly'] ) ? 'yes' : false;
91
// Non-zero
92
$non_zero = "";
93
if ( wppa_switch( 'topten_non_zero' ) ) {
94
+ if ( $instance['sortby'] == 'views' ) {
95
$non_zero = "AND views > 0 ";
96
}
97
+ elseif ( $instance['sortby'] == 'dlcount' ) {
98
+ $non_zero = "AND dlcount > 0";
99
+ }
100
else {
101
$non_zero = "AND rating_count > 0 ";
102
}
187
LIMIT %d";
188
break;
189
190
+ case 'mean_rating':
191
$query = "SELECT * FROM $wpdb->wppa_photos
192
WHERE album IN ( aaaa )
193
$non_zero
195
LIMIT %d";
196
break;
197
198
+ // case 'dlcount':
199
+ default:
200
+ $query = "SELECT * FROM $wpdb->wppa_photos
201
+ WHERE album IN ( aaa )
202
+ $non_zero
203
+ ORDER BY dlcount DESC, mean_rating DESC, rating_count DESC, views DESC
204
+ LIMIT %d";
205
+ break;
206
}
207
$thumbs = $wpdb->get_results( $wpdb->prepare( str_replace( 'aaaa', $album, $query ), $max ), ARRAY_A );
208
}
231
LIMIT %d";
232
break;
233
234
+ case 'mean_rating':
235
$query = "SELECT * FROM $wpdb->wppa_photos
236
WHERE album > 0
237
AND status IN ( 'gold', 'silver', 'bronze' )
240
LIMIT %d";
241
break;
242
243
+ // case 'dlcount':
244
+ default:
245
+ $query = "SELECT * FROM $wpdb->wppa_photos
246
+ WHERE album > 0
247
+ AND status IN ( 'gold', 'silver', 'bronze' )
248
+ $non_zero
249
+ ORDER BY dlcount DESC, mean_rating DESC, rating_count DESC, views DESC
250
+ LIMIT %d";
251
+ break;
252
}
253
$thumbs = $wpdb->get_results( $wpdb->prepare( $query, $max ), ARRAY_A );
254
}
272
LIMIT %d";
273
break;
274
275
+ case 'mean_rating':
276
$query = "SELECT * FROM $wpdb->wppa_photos
277
WHERE album > 0
278
$non_zero
280
LIMIT %d";
281
break;
282
283
+ // case 'dlcount':
284
+ default:
285
+ $query = "SELECT * FROM $wpdb->wppa_photos
286
+ WHERE album > 0
287
+ $non_zero
288
+ ORDER BY dlcount DESC, mean_rating DESC, rating_count DESC, views DESC
289
+ LIMIT %d";
290
+ break;
291
+
292
}
293
294
$thumbs = $wpdb->get_results( $wpdb->prepare( $query, $max ), ARRAY_A );
386
sprintf( _n( '%d view', '%d views', $n, 'wp-photo-album-plus' ), $n ) .
387
'</div>';
388
}
389
+ if ( $dlcount == 'yes' ) {
390
+ $n = $image['dlcount'];
391
+ if ( $n ) {
392
+ $widget_content .=
393
+ '<div>' .
394
+ sprintf( _n( '%d download', '%d downloads', $n, 'wp-photo-album-plus' ), $n ) .
395
+ '</div>';
396
+ }
397
+ }
398
break;
399
400
case 'rating_count':
418
sprintf( _n( '%d view', '%d views', $n, 'wp-photo-album-plus' ), $n ) .
419
'</div>';
420
}
421
+ if ( $dlcount == 'yes' ) {
422
+ $n = $image['dlcount'];
423
+ if ( $n ) {
424
+ $widget_content .=
425
+ '<div>' .
426
+ sprintf( _n( '%d download', '%d downloads', $n, 'wp-photo-album-plus' ), $n ) .
427
+ '</div>';
428
+ }
429
+ }
430
break;
431
432
case 'views':
433
+ if ( $viewcount == 'yes' ) {
434
+ $n = $image['views'];
435
+ $widget_content .=
436
+ '<div>' .
437
+ sprintf( _n( '%d view', '%d views', $n, 'wp-photo-album-plus' ), $n ) .
438
+ '</div>';
439
+ }
440
+ if ( $meanrat == 'yes' ) {
441
+ $widget_content .=
442
+ '<div>' .
443
+ wppa_get_rating_by_id( $image['id'] ) .
444
+ '</div>';
445
+ }
446
+ if ( $ratcount == 'yes' ) {
447
+ $n = wppa_get_rating_count_by_id( $image['id'] );
448
+ $widget_content .=
449
+ '<div>' .
450
+ ( $likes ? $lt['display'] : sprintf( _n( '%d vote', '%d votes', $n, 'wp-photo-album-plus' ), $n ) ) .
451
+ '</div>';
452
+ }
453
+ if ( $dlcount == 'yes' ) {
454
+ $n = $image['dlcount'];
455
+ if ( $n ) {