Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#493 2008-06-09 00:14:48
Re: smd_slimbox
I had a previous version of your great plugin installed. I uninstalled it and the library, then added back the latest version of the library. So far, so good. Then I tried to install 0.3 of the plugin and was greeted by a blank screen after clicking upload. Going back to the plugin screen there is no smd_slimbox.
Any ideas? I really need this to work again!
robin
Offline
#494 2008-06-09 00:56:52
Re: smd_slimbox
Well, I thought the issue might be that I was running textpattern version 4.0.5. Upgraded to 4.0.6 and the same thing happens. But now I have other errors related to the upgrade. :-(
(edit: other errors were related to out-of-date plugins — fixed.)
Last edited by robin746 (2008-06-09 01:31:36)
robin
Offline
#495 2008-06-09 07:51:56
Re: smd_slimbox
robin746 wrote:
I tried to install 0.3 of the plugin and was greeted by a blank screen after clicking upload.
Curious, I have v0.3 of slimbox and v0.33 of the library installed here and I just uploaded them both again to test it under 4.0.6. *ponder*
It is a big plugin; have you tried the compressed version in case your hoster has just decided to limit the size of your $_POST requests or something like that?
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
#496 2008-06-09 11:17:46
Re: smd_slimbox
Well, that is odd. I had tried the compressed code but the version linked to in the post above is somehow different than what I had! So now it installs properly.
Of course slimbox still failed ;-)
But I discovered the page header did not have the correct javascript links. Then I saw in the change log where the include file is no longer used. A quick copy’n‘paste of the javascript includes and I’m off and running.
Next I get to use the parameters to build the look I’m after. I want to extract a list of image IDs from the current article and display the first one on the page (thumbnail). When this is opened in slimbox all the images should be accessed through prev/next navigation. This is what I have:
<txp:asy_wondertag>
<txp:smd_slimbox thumbsize="270, 200" sort="fixed" limit="1" imageid="<txp:jk_get_article_image/>"/>
</txp:asy_wondertag>
This results in something interesting — I can use “prev” and “next” to step through the thumbnails themselves. Wasn’t expecting that but it’s cool!
However I cannot step through the opened slimbox images. How do I do that?
(Please note I cannot use Image Categories for any of my manipulation as the site users have no way to manage these.)
robin
Offline
#497 2008-06-09 11:49:13
Re: smd_slimbox
robin746 wrote:
I cannot step through the opened slimbox images. How do I do that?
My guess is that since there’s only one image per page (i.e. per article, courtesy of the limit attribute) you can only “step through” one image. Slimbox relies on there being more than one image with a rel=
attribute on the page.
Sounds like you need a way of only showing one thumb to “launch” the lightbox effect, essentially hiding the other pictures. With slimbox you can only do this by cheating. Put two calls to identical slimbox tags on the page but surround the 2nd one with a div (or use wraptag/class) that you set via CSS to display: none;
The way I hoped to make slimbox work in v3 never materialised because smd_gallery came along and blew it out of the water. With smd_gallery, the process is trivial since it has a thumblimit
attribute to only show one thumb and the {object} replacement that understands this. In fact, there’s even an example in the smd-gallery help to do exactly that.
btw, does the jk_get_article_image (where is this plugin available? Can’t find mention of it anywhere) just retrieve the contenst of the current article image? If so, you could use the built-in feature of slimbox: imageid="?article_image"
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
#498 2008-06-09 13:17:40
Re: smd_slimbox
Bloke wrote:
btw, does the jk_get_article_image (where is this plugin available? Can’t find mention of it anywhere) just retrieve the contenst of the current article image? If so, you could use the built-in feature of slimbox: imageid="?article_image"
Actually, I think I wrote this function, maybe from some code I got off this forum. Since I couldn’t get my own plugin to work, I just stuck the code in someone else’s. Sorry for the confusion! Even I had forgotten about this… what happens when you return to code after 6 mo. away.
I will check out this gallery plugin of which you speak.
BTW, thanks for your timely help and your great coding work.
robin
Offline
#499 2008-06-09 13:40:08
Re: smd_slimbox
Following your advice I reduced my code to:
<txp:upm_if_article_image>
<txp:smd_slimbox thumbsize=“270, 200” sort=“fixed” limit=“1” imageid=”?article_image”/>
</txp:upm_if_article_image>
Although I specify fixed sorting, it doesn’t seem to work. In the article the attached images are specified as 70, 61, 62. But the thumbnails show up in numeric order: 61, 62, 70. Am I missing something?
robin
Offline
#500 2008-06-09 13:47:32
Re: smd_slimbox
Bloke wrote:
The way I hoped to make slimbox work in v3 never materialised because smd_gallery came along and blew it out of the water.
OK, now that plugin I cannot install because it gives me a blank page afterwards. Just like what was happening with smd_slimbox at first! Arg!
Guess I need to go to the other thread and debug this.
robin
Offline
#501 2008-06-09 13:58:32
Re: smd_slimbox
Ignore that last message. Grabbing the compressed code from the smd_gallery thread worked. I do not know why this issue keeps cropping up.
robin
Offline
#502 2008-06-09 14:27:00
Re: smd_slimbox
robin746 wrote:
<txp:smd_slimbox thumbsize=“270, 200” sort=“fixed” limit=“1” imageid=”?article_image”/>
Although I specify fixed sorting, it doesn’t seem to work. In the article the attached images are specified as 70, 61, 62. But the thumbnails show up in numeric order: 61, 62, 70. Am I missing something?
Umm, yes. limit="1"
:-) Slimbox is still only generating one image per page. Is the ‘order’ coming from the order of your articles? i.e. next/prev walk you through the articles? Incidentally, smd_gallery also has powerful built-in pagination support so you don’t need to resort to trickery to do it.
Grabbing the compressed code… worked. I do not know why this issue keeps cropping up.
I think it’s to do with the size of the plugin vs the size of a POST request set by the server. If the plugin is large it exceeds the size, the upload is cancelled and returns a blank page? Just a stab in the dark based on what ruud has said in the past.
Last edited by Bloke (2008-06-09 14:27:58)
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
#503 2008-06-09 14:38:21
Re: smd_slimbox
The page is in fact showing one image at a time, as limit=1 specifies. My point is that these are not displayed in the correct order. They are showing up sorted numerically whereas I have asked for them to be in fixed order.
But never mind, I have installed smd_gallery. Can’t get it to work though, but that is in another thread. :-)
robin
Offline
#504 2008-06-09 17:34:18
Re: smd_slimbox
Well, I am back to this plugin until I can get smd_gallery to show anything at all on my pages. :-(
I followed your previous suggestion and got my code like so:
<txp:upm_if_article_image>
<txp:smd_slimbox thumbsize="270, 200" sort="fixed" limit="1" imageid="?article_image"/>
<div style="display:none;"><txp:smd_slimbox imageid="?article_image" /></div>
</txp:upm_if_article_image>
This is almost perfect except the thumbnail displayed when the page first loads is not the correct one but rather the lowest numerically.
robin
Offline