This is method 1:
[wppa type="landing"][/wppa]
Click <a onclick="document.location=document.location+'?wppa-occur=1&wppa-album=5&wppa-cover=0'" >here</a> for the album
wppa-occur=1 means: it is the first wppa thing on the page (occurrance)
wppa-album=5 means: it is album with id=5
wppa-cover=0 means: i want to see the thumbnails
other options are:
wppa-cover=1 means: i want to see the album cover
wppa-slide=1 means: i wantt to see the slideshow. (requires wppa-cover=0)
It will not work straitaway with ajax, and you will still see: Click here for the album
after the page reloads.
This is method 2:
<div id="my-wppadiv" style="display:none" >
[wppa type="thumbs" album="5"][/wppa]
</div>
<span id="my-span" >Click <a onclick="jQuery('#my-wppadiv').show();jQuery('#my-span').hide();" >here</a> for the album</span>
Enter this with the wp page/post editor in Text mode, Not in Visual !!!!!
Pro’s:
works immediately
the text in the <span> element disappears after clicking
Con’s:
The code is generated on page load, so do not do this if performance is the issue why you want to do this, but only when layout is the issue.
more coding
My preferance? method 2.
Thanks for both methods. They open the album in the post, which is cool to start with. I was actually looking for an link to open the album page as a new page. I can do it like:
Het <a href="https://www.pemoco.nl/zzssooi/foto-albums-11/?&wppa-album=65&wppa-cover=0&wppa-occur=1">foto album</a> van
But when I later re-arrange the landing page structure (which is moved to zzssooi for now) the links will change. Also the zzsooi stuff does not look nice in the url.
So if you may have an alternative for this, that would be great.
Best regards, Peter
-
This reply was modified 4 years, 1 month ago by
deepcore2.
You can only link to a page that shows the album, not to an album itsself. So you still have to manage the page – currently ‘zzssooi/foto-albums-11/’ – outside the scope of wppa. Wppa does not associate albums with pages.
If you enable Petty links in Table IV-A6, you can change the linkurl into:
https://www.pemoco.nl/zzssooi/foto-albums-11/oc1/cv0/ab3
Ok, thanx. Will figure out how to work with it.
Best regards, Peter