Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

  1. Index
  2. » Plugin support
  3. » smd_slimbox

#217 2007-08-04 09:33:00

the_ghost
Plugin Author
From: Minsk, The Republic of Belarus
Registered: 2007-07-26
Posts: 907
Website

Re: smd_slimbox

Can you post the tags you’re using and/or a link to a page that exhibits this behaviour (http://www.okoshki.by/ is giving a 500 internal server error right now)

the tag is very simple – <txp:smd_slimbox category="sertificates" />

The page is here http://www.okoshki.by/about/proverka-galerei

There are three images in my galery and i think that it’s the key, why all of them go to the adress bar, including caption for on og them. But, regrettably, I can’t find the rule this bug appears. On my girlfriend computer it bugs only in Opera 9.21, but in IE7 – works perfectly. At home it works in Opera and IE6, at my friend comp it bugs in Opera 9.x too. Something strange, yes?

http://www.okoshki.by/ is giving a 500 internal server error right now

Sorry for 500 – I’m trying to switch on gzip compression. Not successfully yet :(

And thanks for link to mootools components!

Last edited by the_ghost (2007-08-04 09:50:28)


Providing help in hacking ATM! Come to courses and don’t forget to bring us notebook and hammer! What for notebook? What a kind of hacker you are without notebok?

Offline

#218 2007-08-04 09:51:00

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,263
Website GitHub

Re: smd_slimbox

the_ghost wrote:

On my girlfriend computer it bugs only in Opera 9.21, but in IE7 – works perfectly. At home it works in Opera and IE6, at my friend comp it bugs in Opera 9.x too.

Very strange. I’ve just tried your page in Opera 9.21 (Build 8776 on WinXP) and 9.22 (Build 8801) and the slimbox gallery shows fine. So it must be something specific with those computers or Opera versions. Can’t think of any reason at the moment. Hmmmm….


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

#219 2007-08-04 10:06:32

iblastoff
Plugin Author
From: Toronto
Registered: 2006-06-11
Posts: 1,197
Website

Re: smd_slimbox

just wanted to chime in and say that http://www.okoshki.by/about/proverka-galerei works fine for me using opera 9.22

Offline

#220 2007-08-04 16:08:32

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,263
Website GitHub

Re: smd_slimbox

Another update. The latest version fixes the Next/Prev links to allow proper navigation of multiple slimboxes per page.

Couldn’t have done it without the help of wheaticus who put me on the right track so kudos to you fella! I had to modify your hack a little because I realised your version only worked if the orderby remained as ‘category’. This one will work no matter what order your thumbs are.

If you don’t care about the technical details, just grab v0.26 and play, reporting any weirdness here. Note also that I squashed another small bugette in smd_lib, taking it to v0.21d.

New attribute: galleryid

With luck, you’ll never need the new option, galleryid. Just install the plugin and it’ll work out of the box, allowing you to put as many smd_slimbox tags per page you like and each Next/Prev link under the thumbnails will only advance that group, leaving all the other pics in their same locations.

It works like this: the program transparently generates a 32-character hash string for each slimbox tag (based on the other options you give it, which should guarantee uniqueness). It then picks a random 4-char code from this string (it takes every 6th character by default) and assigns that to the gallery. In the very unlikely event that this generates two galleries with the same ID you can tweak the galleryid attribute for one or more slimbox tags to avoid the clash.

Either supply galleryid with a unique fixed string (e.g. galleryid="TheGallery2") or give it a question mark and 2 numbers, separated by a colon (e.g. galleryid="?5:4"). The first number is the length of the final string to generate, the second number is how many characters to skip over in the full 32-char string each time it picks one. So in that case, it generates a 5-character string from the characters it finds at positions 1,5,9,13, and 17.

If you miss out the 2nd number (e.g. galleryid="?6") it will just assume it’s an increment of 1, so in this case it’ll use the 1st 6 characters. The help file explains it better, with examples.

As I say, you should never need this option, but it’s there if you need it or simply love tinkering with stuff.

Hope it helps you out, and thanks again wheaticus.

Last edited by Bloke (2007-08-04 16:10:09)


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

#221 2007-08-22 03:17:41

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: smd_slimbox

Bloke:

Hope all is well.

I have a question, hopefully it is simple, I want to limit the max size of images displayed using slimbox. For example, if I can set an image size (maybe 800 × 600 width) if any images are greater than that, when displayed using slimbox they would be resized down …

If that is not possible, is there a way to have slimbox display the image thumbnails, instead of the actual image.

I know these may seem like odd questions, but there is a method (at least I think) behind the madness …

Any assistance would be gretaly appreciated.

progre55

Offline

#222 2007-08-22 08:08:08

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,263
Website GitHub

Re: smd_slimbox

progre55 wrote:

I want to limit the max size of images displayed using slimbox.

Alas, not possible/desirable according to Christophe

is there a way to have slimbox display the image thumbnails, instead of the actual image.

For you my friend, anything :-) v0.27 now with thumb="1" support. Hope that does what you want, if not let me know.

Last edited by Bloke (2007-08-22 08:08:22)


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

#223 2007-08-22 11:57:03

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: smd_slimbox

Bloke:

Thanks.

That should do my trick …. I think :)

progre55

Offline

#224 2007-08-24 15:36:23

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,263
Website GitHub

Re: smd_slimbox

And just when I thought I’d seen it all, along comes Slimbox extended which allows resizing of images a bit like you wanted, progre55.

It seems to use an older version of slimbox as its base code but if your current hack isn’t quite doing what you want, it may be possible for me to compare the two bits of code and merge the latest base with the iframe and resizing extensions (depending on demand for each). Then I’d have to mod the thumbnail generation such that it can take extra options to allow you to specify an absolute value for all images or, perhaps more usefully, an absolute maximum applied only to those images that were oversized.

Of course the downside is that any future changes to the slimbox core mean I have to go through and re-patch the code (unless Christophe is willing to put some of the extensions into the core – if you want to lobby him about it, be my guest!)

What would be more super-cool in my mind would be if you could specify a maximum size which is relative to the user’s current browser resolution. I’m sure that’ll be tricky to achieve, but it’d be useful. Either way, it’s all just pie-in-the-sky thinking right now.

But if you want, I’ll try some experiments in the name of science. I might fail, but I can try if anyone thinks being able to specify a maximum image size is worth it.

Thoughts? Ideas? Bueller? Bueller? Anyone?


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

#225 2007-08-24 15:50:53

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: smd_slimbox

Bloke:

Let me think about it over the weekend and look at it more closely.

My thought is that for now probably not worth the effort. You are the man and I appreciate the thought, but I think that I can get around my issu with the modification you have made.

I will touch base at the beginning of the week.

Speak to you soon.

progre55

Offline

#226 2007-08-26 22:55:48

Adam_V
Member
From: Vancouver, BC, Canada
Registered: 2007-08-22
Posts: 10
Website

Re: smd_slimbox

Hey Bloke, thanks for the fantastic plugin!

I’m sorry if this question has been already asked, but this thread is pretty long!

Is it possible to display an image’s alt text with the full-sized pop-up image instead of with the thumbnails? I couldn’t seem to find anything relating to that in the documentation. Cheers!

Offline

#227 2007-08-27 21:51:49

Adam_V
Member
From: Vancouver, BC, Canada
Registered: 2007-08-22
Posts: 10
Website

Re: smd_slimbox

Bump… I read through the whole thread and I don’t think anyone asked the same question.

Any ideas people? TIA!

Offline

#228 2007-08-29 18:33:00

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 10,263
Website GitHub

Re: smd_slimbox

Adam_V wrote:

Bump…

No bump required. I was in Paris and couldn’t check my mail until today, sorry.

Is it possible to display an image’s alt text with the full-sized pop-up image instead of with the thumbnails?

Not at present. Leave it with me.


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

  1. Index
  2. » Plugin support
  3. » smd_slimbox

Board footer

Powered by FluxBB