Extension talk:SlimboxThumbs

Small Problem
Hi, I really like your extension and the fact that thumbnails size adapt to the size of the window. But I think it could cause lots of problem. Each time you open your browser with a different size of window you obtain thumbnails of different size. By looking in the images/thumbs folder. I can see that if 100 people use 100 different window sizes, you will get at the end 100 different thumb files ! It could be a good idea to have the option to limit the number of possible thumb sizes. What do you think of that ?

Thank you


 * VitaliyFilippov (talk) 22:29, 28 September 2012 (UTC) Hm :-) I think you're right, yet instead of 100 there would probably be a relatively small amount of "typical" widths, as related to users' display resolutions... The fix for this is easy, I've just committed it - auto-fitted thumnail widths will be limited to multiples of 80 (I think it's a reasonable number...)

Hey ! Thanks for the update ! I have changed the 80 to 160 to have less thumbs Thank you !

Non existing images crashes page
Hi, this extension is really cool and i like it. But i have a little trouble. Im using MW 1.18.4. When i put a link to non existing image, Slimbox crashes this page and the page is not accesible. I must shut off this extension, then i can go to this page. MW works with non existing files. Where's the trouble? Thank you much. --31.186.189.226 13:32, 27 July 2012 (UTC)
 * I suggest changing line 58 to read:

--89.160.21.47 08:52, 16 August 2012 (UTC)

It works perfect, thank you! --31.186.189.226 07:30, 5 September 2012 (UTC)


 * -- Fixed in new version (2012-09-17). VitaliyFilippov (talk) 10:19, 27 September 2012 (UTC)

[OLD] Howto use Gallery?
I have just installed it with Mediawiki version 1.18.1 - it works fine. It is possible to use the gallery feature? Gallery works fine (using the gallery tag) - but when i click a picture i get no "left" or "right" arrows and no counter how many pictures there are.

I can see in the SlimboxThumbs.php a efRewriteGalleryImage Function - but it did not work or i am using the wrong tags. Thx for help --BLinz 23:49, 26 January 2012 (UTC) Edit: --> Found the Reason: in the SlimboxThumbs.php at the last lines:

The $allDone will not use - the efRewriteGalleryImage function did not work right. So no gallerys are possible. I changed the code at line 118 from: to so the gallery feature will always used. Now all pictures at one Site will used in only one Gallery, even if i don't use the gallery tag - but i like it so. --BLinz 20:51, 29 January 2012 (UTC)

[OLD] Announcement
Sorry for not replying to any of your complaints. I'll pick back up the development of this extension soon and will look after the issues. --Clausekwis 02:53, 25 September 2010 (UTC)

[OLD] Full Size Image with 1.18.1
Hi, I just upgraded to mediawiki 1.18.1. I download SVN version 109611 of SlimboxThumbs. When I clicked a picture in a Gallery, The picture popup by taking all the space in the window and it is impossible to resize it. The next fonction seems to work, but the image is not scale to the size of the window.

Thank you

I have the same problem --ZelChief 17:50, 21 January 2012 (UTC)

[OLD]
Hi, thanks for the extension!

The gallery code worked without any problems, except I changed your hardlink from /w/thumb.php to '.$wgScriptPath.'/thumb.php

The single image code did not work, it seems to be some sort of problem with the way the regex interprets greediness on different servers. I played with it a bit and ended up using the following pattern and rewriting the callback a little:

and

I had one further problem, that the Edit page was not shown, but I can't reproduce it now; it had something to do with the callback - no content was returned. As a security measure I built the following couple of lines in: and

--Cm 11:24, 29 October 2009 (UTC)

[OLD] No slimbox effekt
After clicking on image, it just openin in new page in full-size by link lokking like that: http://www.turystyka-powiat-nowosolski.info.pl/thumb.php?f=Siedlisko_%28zamek%29-02.jpg&width=299

Site

How can i fix it?--Skarabeusz 11:17, 31 January 2010 (UTC)


 * It seems the javascript isn't loaded. There might be a problem with the jQuery library having a conflict with some other library your mediawiki installation is using. Can you please post the link to the page where your gallery is? --Clausekwis 13:13, 3 March 2010 (UTC)
 * See here []--Skarabeusz 15:01, 9 March 2010 (UTC)

I HAVE THE SAME PROBLEM. I tried LightboxThumbs, SlimboxThumbs, but nothing happens. Installed: ajax.js,ajaxwatch.js, mwsuggest.js,google analytics js, AND jquery.js,slimbox.js My site is in Russian, maybe its important? But i think its because of JS Conflict. PLEASE HELP. http://abcplanet.co.cc/
 * Hey, on my wiki I have the same problem, no slimbox effects, I can't figure out how it works - sometimes I get forwarded to the file's description page, sometimes it just shows the image... - the example page though works fine. --Fxk2

No slimbox effect
I have a page that has the same problem. It has 9 images on the page of which 5 work with slimboxthumbs. Slimboxthumbs will scroll through the 5 images that work fine, the others don't call the JS, they function just as links to the inbuilt mediawiki image with metadata page. Update: Paths on non-working images seem slightly different: /images/thumb/8/8f/600px-filename.jpg works, /images/8/8f/filename.jpg doesn't?

Update 2: Found a workaround. By commenting out line 42 and 48 of slimboxthumbs.js (removing the if statement) it now adds the zoom function to all 9 images on my page. Ralph


 * VitaliyFilippov (talk) 20:23, 23 October 2012 (UTC) It was thought to be a feature :))) SlimboxThumbs only shows lightboxes for image thumbnails, not for all images on the page. I.e. just Image.jpg]] won't show up in the lightbox, and [[File:Image.jpg will. Also, commenting out the if statement isn't correct as it will probably break on external images.

Ah ok, I didn't realise it was designed to only trigger on thumbnails. Thanks for your replies and a very useful plugin :-) Ralph

[OLD] See source code of the plugin instead of my own wiki
When I include this plugin (or lightbox for that matter) my wiki suddenly turns into a Extension:SlimboxThumbs/SlimboxThumbs.php page, in which I see the sourcecode of the extension, which is clearly not the idea. It is really the only thing I can see, also my own menu items aren't there anymore: it is all basic mediawiki. This is probably me doing something wrong with this plugin (though all other plugins I installed work fine), but has anyone any idea why this is?

Thanks a lot in advance, --FrankLeone 21:26, 16 March 2010 (UTC)

[OLD] Problem with 1.16.1, Gallery and SlimboxThumbs
After an upgrade from 1.15.4 to 1.16.1 mediawki I have problems with galleries. If on my page I have 18 or less pictures, SlimboxThumb does not work. If I have more than 18 pictures, I can not see the pictures table on the page. Everything else is visible. I also try to use HighslideThumbs but exactly same effect. So I think there is an incompatibility with 1.16 and 1.16.1 and one component of HighslideThumbs and SlimboxThumb.

Thank you, 13:47, 06 January 2011


 * You are correct in your assessment. I'll try to get the extension working with 1.16 but I'd be happy for any kind of help of course. --Clausekwis 18:45, 12 February 2011 (UTC)

Problem with 1.16 and SlimboxThumbs
I was getting an error in my console .parseJSON is not a function, it appears the version of jquery.min.js that gets pulled in by the script with a low mediawiki version is 1.3.2, this is too old to include that function so I fixed it by including the latest jquery.min.js (1.8.2 at time of writing). Seems to work now. Ralph


 * VitaliyFilippov (talk) 20:10, 18 October 2012 (UTC) Thanks for the report, I've just fixed that incompatibility in the repository. Now it uses $.ajax instead of the deprecated sajax_do_call and doesn't use $.parseJSON at all.

Issue with firefox
First i wanted to say, fantastic extension. small light and does what it's supposed to.

however i do have one issue. it seems that random images will not work in firefox or chrome however IE the images work fine, i can't seem to find any pattern in it. There doesn't seem to be any pattern to it, the image resolution does not seem to affect it, size of the image doesn't, nor does the file name. it seems to have something to do with image mapping according to google searches. however nothing i do seems to resolve it. I am running mediawiki 1.20.0 and the latest version of slimboxthmbs from the git master snapshot. Any help with this would be greatly appreciated.


 * VitaliyFilippov (talk) 04:12, 28 December 2012 (UTC) Maybe you can post the URL of your wiki with an example of failure here, and I'll check it?
 * Unfortunately i forgot to mention that my wiki is hosted on an internal company network so i wouldn't be able send you a link, but screenshots might be an option. In addition i have tried running firebug to see what the issue might be, firebug lists no errors for anything when opening these pages.
 * VitaliyFilippov (talk) 05:20, 29 December 2012 (UTC) Maybe it just doesn't show images that are included in the article full-size, not as the thumbnails? I.e. SlimboxThumbs doesn't make lightboxes for just Image.jpg]] (not [[File:Image.jpg ). If this is your case, I think I'll change that behavior, because it would be the second report of this issue :-) Or this isn't your case?
 * No It doesn't seem to matter if the image is set to a thumb or not, it seems to just not load the image at all either way. Interestingly enough when i set an image that was doing this to "thumb" it then showed up as a gallery in lightbox even though there was only one image on the page. of course the image was not loaded in any of these. it almost feels like it might be more of an issue with imagemajick not rendering correctly.
 * VitaliyFilippov (talk) 10:24, 10 January 2013 (UTC) Actually, there is another condition of displaying a lightbox :-) the thumbnail should be linked to the image page. The idea is to show the image which would be shown anyway on the click, and do not show anything if the user didn't want to show something on the click. If the thumbnail is linked to some random URL, there will be no lightbox. Is this your case?
 * Okay if i'm understanding you correctly the thumbnail should link to an actual image page, which they all do in this case. one thing i've noticed and i don't know if this is a legitimate factor or not is that it seems to be affected by the resolution of the computer accessing it. but i can't seem to figure out what the correlation is between the two. Thank you again for the help.
 * VitaliyFilippov (talk) 19:47, 15 January 2013 (UTC) ...uhhh, so that's something strange. OK, I think you have to try debugging the extension with Firebug or chrome debugger. You need to look at the script 'slimboxthumbs.js' and try to find out A) if the offending images get in 'names' during the first loop and B) if they are returned in response to the efSBTGetImageSizes ajax call.

Not working on 1.15.1 installation
I've installed this, and initially the example page in the slimbox directory didn't work; replacing slimbox2.js with the one from the slimbox site fixed that. However, it's still not working on actual wiki pages. The scripts are entered into the head as they should be, and the debugger in Firefox suggests the image names are being pulled into the $names array, but none of the images seems to get a lightbox. The image links also don't get a rel="lightbox" link -- should they, in this context? I understand the script isn't supposed to make boxes for images at their normal size or which aren't linked to something, but in this case linked thumbnails in and outside of galleries aren't getting it either. Poking through the scripts, nothing seems obviously wrong, and it sounds like it works great for other people, so any suggestions? (Aside from 'upgrade the wiki version' -- that's unfortunately out of my hands.)

C.C. Principalis (talk) 00:32, 21 February 2013 (UTC)


 * VitaliyFilippov (talk) 08:36, 21 February 2013 (UTC) Example page doesn't need to be working for the extension itself to work. Slimbox2 consists of slimbox2 itself and autoload.js. The usually expected behavior with lightboxes popping up for images with rel="lightbox" is achieved by including autoload.js, but SlimboxThumbs doesn't use it. And the example page assumes autoload is included in slimbox2.js.
 * I think your issue is related to $wgArticlePath in some way - what it is equal to on your wiki?


 * C.C. Principalis (talk) 13:14, 21 February 2013 (UTC): Oh, good to know! I didn't realise it didn't use the 'rel="lightbox"' at all -- that explains why I couldn't figure out where the scripts were setting it! It looks like $wgArticlePath = "/index.php/$1"; does that need to be changed somehow/somewhere?  pathRegexp comes out as "/index\.php/[^:]+:(.*)", and it does grab the names; rsargs[0] seems to come out as image1.jpg:image2.gif:image3.jpeg:imageN.jpg, etc, and get passed to efSBTGetImageSizes like it should, but I think perhaps nothing is coming back?  I can't quite tell for certain.  Thanks for the help.