Extension talk:SmoothGallery

About this board


external pictures doesn't work

1 (talkcontribs)

hello, I've installed SmoothGallery on MW 1.15.4 and then I enabled $wgSmoothGalleryAllowExternal, I put it to true and put the following code :


Result, SmoothGallery gives me the following error : SmoothGallery error:No images were found in this gallery. Make sure all images requested exist. The following images were not found:

where's the problem? how do I do fix that? thank you.

This post was posted by, but signed as ren.

Reply to "external pictures doesn't work"
Juandev (talkcontribs)

Hi, I have tested 1.1h with SmoothGallery 2.0 on mw 1.15.1. (images via Foreignrepos) but a lot of html code comes to the column. What might be the problem?

This post was posted by Juandev, but signed as Juan de Vojníkov.

Ryan lane (talkcontribs)

I've never tried it with a ForeignRepo before...

Juandev (talkcontribs)

So you recommend to test it with just locally uploaded files?

This post was posted by Juandev, but signed as Juan de Vojníkov.

Reply to "HTML code comes with"

Extension installed and I can see blank page

Juandev (talkcontribs)

Just want to report it. I have installed the extension to smoothgallery dir, there I placed also dirs css, images, scripts and other files of JonDesigns v 2.0 as it is not clear from installation manual how to settle it. Than I fixed the bug coming with 2.0 and then relized my wiki is blanked, so additionally I Fix the jd.gallery.css, but the problem persists.

mw 1.16.0 in MoWeS Portable package, Apache 2.2.11 on Windows Vista Home Premium, MySQL 5.1.35, PHP 5.3.0

--Juan de Vojníkov 18:29, 9 November 2010 (UTC)

This post was posted by Juandev, but signed as Juan de Vojníkov.

Ryan lane (talkcontribs)

If you are getting a blank page, its because of a problem with the extension. Check the php log to see if there are any errors.

Juandev (talkcontribs)

Well, I dont understand PHP. So I may only send you a log and you can have a look if you like.

This post was posted by Juandev, but signed as Juan de Vojníkov.

Reply to "Extension installed and I can see blank page"

Invalid marker in MW 1.24

Leucosticte (talkcontribs)

I am using MW 1.24. I am using this wikitext:



[86f71766] /wiki/Project:Sandbox Exception from line 77 of /home/stauffenbergssh/theshatteredpan.org/w/includes/parser/StripState.php: Invalid marker: UNIQ3e909c67eef36a9c-sgallery-00000000-QINU


#0 /home/stauffenbergssh/theshatteredpan.org/w/includes/parser/StripState.php(66): StripState->addItem(string, string, string)
#1 /home/stauffenbergssh/theshatteredpan.org/w/includes/parser/Parser.php(4068): StripState->addGeneral(string, string)
#2 /home/stauffenbergssh/theshatteredpan.org/w/includes/parser/Preprocessor_DOM.php(1181): Parser->extensionSubstitution(array, PPFrame_DOM)
#3 /home/stauffenbergssh/theshatteredpan.org/w/includes/parser/Parser.php(3159): PPFrame_DOM->expand(PPNode_DOM, integer)
#4 /home/stauffenbergssh/theshatteredpan.org/w/includes/parser/Parser.php(1222): Parser->replaceVariables(string)
#5 /home/stauffenbergssh/theshatteredpan.org/w/includes/parser/Parser.php(395): Parser->internalParse(string)
#6 /home/stauffenbergssh/theshatteredpan.org/w/includes/content/WikitextContent.php(335): Parser->parse(string, Title, ParserOptions, boolean, boolean, integer)
#7 /home/stauffenbergssh/theshatteredpan.org/w/includes/WikiPage.php(3613): WikitextContent->getParserOutput(Title, integer, ParserOptions)
#8 /home/stauffenbergssh/theshatteredpan.org/w/includes/poolcounter/PoolCounterWork.php(116): PoolWorkArticleView->doWork()
#9 /home/stauffenbergssh/theshatteredpan.org/w/includes/Article.php(698): PoolCounterWork->execute()
#10 /home/stauffenbergssh/theshatteredpan.org/w/includes/actions/ViewAction.php(44): Article->view()
#11 /home/stauffenbergssh/theshatteredpan.org/w/includes/Wiki.php(428): ViewAction->show()
#12 /home/stauffenbergssh/theshatteredpan.org/w/includes/Wiki.php(292): MediaWiki->performAction(Article, Title)
#13 /home/stauffenbergssh/theshatteredpan.org/w/includes/Wiki.php(596): MediaWiki->performRequest()
#14 /home/stauffenbergssh/theshatteredpan.org/w/includes/Wiki.php(448): MediaWiki->main()
#15 /home/stauffenbergssh/theshatteredpan.org/w/index.php(46): MediaWiki->run()
#16 {main}

It reminds me of this bug. Perhaps SmoothGallery stopped working with a certain version of MediaWiki, as MathJax did.

Reply to "Invalid marker in MW 1.24"

MW1.15 Not Working - Images on top of each other

16 (talkcontribs)

Extension version - 1.1h SmoothGallery - 2.0

When I use the following, I just get all images stacked on top of each other; {{#sgallery: |width=200 |height=300 |showarrows=false |showcarousel=false |showinfopane=false |timed=true |delay=4000 |imagelist=Image1.jpg Image2.jpg Image3.jpg }}

Ryan lane (talkcontribs)

I've tested this with 1.15. It works. I'd check to see if your javascript is being loaded properly. Do you have web developer? See if all of the javascript is loading.

Arkasha (talkcontribs)

I have the same result in MW-1.17wmf1. All the pictures are on top of each other. However, when I press button Show preview I got normal gallery layout like in wiki/Special:NewFiles (Gallery of New files). When I save page I have the problem. How to check that all JS are loading?

Arkasha (talkcontribs)

Just to add. First try was in Firefox browser. Tried in IE-7, the problem remains even in preview mode.

Ryan lane (talkcontribs)

1.17 is a different beast. It is using Resource Loader, which this extension isn't written to support yet. (talkcontribs)

I just upgraded a mediawiki to 1.17.0 and noticed that SmoothGallery isn't working any more. When is SmoothGallery expected to be updated to work with Resource Loader?

Thank you, Christoph (talkcontribs)

Still no answer so let's change the question. :-) Will there be an update for SmoothGallery working with Mediawiki 1.17.0 in the near future?

Regards Norbert

Umoenks (talkcontribs)

For me, the following worked (more ore less):

Add a line like

$outputPage->addHeadItem('mootools', '<script src="' . $extensionpath . '/scripts/mootools.uncompressed.js" type="text/javascript"></script>' );

to the function setGalleryHeaders() in SmoothGalleryClass.php. Then, the gallery did appear, at least. Anyways, the parameters were not passed to the gallery... Seems the SmoothGalleryParser class is not loaded/initialized correctly.

I would appreciate an official update of this marvelous extension very much!

Umoenks (talkcontribs)

The support desk answered something similar to what Ryan said so far (cf. OutputPage::addScript(), where I first thought it was a problem of the OutputPage::addScript() function).

Desperately voting for an update, Ryan! ;)

Zck (talkcontribs)

Fix, works on MW 1.18 and SG 1.1h,
in SmoothGalleryClass.php find (line 283):

$outputPage->addScript( '<script src="' . $extensionpath . '/scripts/mootools.uncompressed.js" type="text/javascript"></script>' );
$outputPage->addScript( '<script src="' . $extensionpath . '/scripts/jd.gallery.js" type="text/javascript"></script>' );
$outputPage->addScript( '<script src="' . $extensionpath . '/scripts/HistoryManager.js" type="text/javascript"></script>' );

and replace it with:

$outputPage->addHeadItem( 'smgal1','<script src="' . $extensionpath . '/scripts/mootools.uncompressed.js" type="text/javascript"></script>' );
$outputPage->addHeadItem( 'smgal2','<script src="' . $extensionpath . '/scripts/jd.gallery.js" type="text/javascript"></script>' );
$outputPage->addHeadItem( 'smgal3','<script src="' . $extensionpath . '/scripts/HistoryManager.js" type="text/javascript"></script>' );

pass parameters fix, in SmoothGallery.php (line 112):

function initSmoothGalleryTag( $input, $argv, $parser ) {
	$output = initSmoothGallery( $input, $args, $parser );

	return $output;


function initSmoothGalleryTag( $input, $argv, $parser ) {
	$output = initSmoothGallery( $input, $argv, $parser );

	return $output;
Umoenks (talkcontribs)

Zck, actually your patch did not work completely for me. What worked was the hybrid approach fixing function initSmoothGalleryTag(), as suggested by you, and patching SmoothGalleryClass.php as suggested by me.

My configuration: MW 1.17, SG 1.1h (talkcontribs)

Great job Zck! Your Fix is working fine in Version MW 1.18.1, SG 1.1h. I didn't need to add Umoenks fix.

Regards Norbert (talkcontribs)

Zck your pass parameter fix has two blocks of code with the SAME code in each block.

function initSmoothGalleryTag( $input, $argv, $parser ) {

       $output = initSmoothGallery( $input, $argv, $parser );

       return $output;


for both. Is one supposed to be different?

Umoenks (talkcontribs)

Yes, one is different. ;) Watch out the $argv parameter. In the second case, it is

$output = initSmoothGallery( $input, $argv, $parser );

instead of

$output = initSmoothGallery( $input, $args, $parser );

which apparently won't work at all. (talkcontribs)

I think the problems is that addScript() sets the script at the end of the page, but window.addEvent() (which requires mootools.js) is in the middle. So, changing addScript() in addHeadItem() only for mootools is enough.

$outputPage->addHeadItem('mootools', '<script src="' . $extensionpath . '/scripts/mootools.uncompressed.js" type="text/javascript"></script>' );


P.S. I'm using MW 19+

Reply to "MW1.15 Not Working - Images on top of each other"

Change opacity of slideInfoZone but not of the text inside of it

SmashLink (talkcontribs)

Hi everyone. I'd like to change the opacity of the slideInfoZone but preserve the text as it is. That is, I want the "background" (actually the div) to be more transparent, but let the title and the paragraph (h2 and p) with the same opacity. Is that possible? Thanks!

Reply to "Change opacity of slideInfoZone but not of the text inside of it" (talkcontribs)

I have a smoothgallery folder in my extensions directory, do i extract the contents of the smoothgallery file (the original plugin not made for MW) to the smooth gallery extension directory? Do i need to leave it in it's own file so it's extensions/Smoothgallery/Smoothgallery 2.0

The installation instructions don't explain this. I'm getting stacked images as mentioned in another post and don't think my java is loading correctly.

MW 1.18 Smooth Gallery 2.0 (fixed the file name bugs mentioned with the v1.1 business in the file names)


Reply to "File Locations"

external link icon appears in gallery + internal and external URL's in caption box do not function

6 (talkcontribs)

I'm testing to see if I can implement the smoothgallery tool you developed on my mediawiki (http://csdms.colorado.edu/wiki/Test6a). However, I'm facing some minor problems that I hope you can help out with.

Installation went all fine. I'm using the following software versions: Mediawiki 1.15.4 php 5.2.13 mysql 5.1.45 smoothgallery 1.1g

A few problems: 1) I get an external link symbol in my smooth gallery which I can't get away. The only way I can get the external link away is by setting the showinfopane="false" but than I loose the figure caption at the bottom and I would like to keep that. Any idea how to solve this?

2) I would like to add an internal link in the figure caption that appears at the bottom. So I tried to add something like: T071_james_syvitski.jpg|This is the description for picture1 test but it doesn't show the text or the link between the brackets. Is there a way to get links in the "showinfopane"?

Thank you!

Ryan lane (talkcontribs)

I haven't had much of a chance lately to update this extension. I hope to update this, and look at these issues soon. Both of these are bugs (both of which I previously knew about). (talkcontribs)

Hi Ryan, I looked a bit into the external link symbol that shows up in the gallery. It turns out that I can suppress the icon by using the following layout parameter in front of the <sgallery>: <span class="plainlinks">. See also: m:Help:Link#Arrow icon. It is a bit of a work around but it works which is good enough for me. Now the only thing is being able to add a link in the figure caption at the bottom.

Cheers, Albert.

Ryan lane (talkcontribs)

Yeah, this was likely going to be the fix I used. (talkcontribs)

I just noticed that the disadvantage is that the arrows on the left and right side to scroll the images will disappear as well .....

Best, Albert.

Ryan lane (talkcontribs)

I've fixed issue #2 in 1.1h. I need internet explorer to test #1, I believe. I don't see this in safari or firefox, but I know these issues occur frequently with IE.

Reply to "external link icon appears in gallery + internal and external URL's in caption box do not function"

SmoothGallery makes Cite does not work?

1 (talkcontribs)

As I stated in the title, does SG makes Cite does not work? Whenever I inserted

    or <reference>, it did not work. When I removed the SmoothGallery from that page, it worked.

    Could you please help me how to fix it?

    Reply to "SmoothGallery makes Cite does not work?" (talkcontribs)

    I just noticed that the latest revision + SmoothGallery 2.0 the image isn't shown when there is only one image in the list. (Firefox + Opera). Instead, just a white area is shown where the image should be. Not sure if this is a bug in the extension or in the original gallery framework.

    Reply to "Single Image-list not showing"
    Return to "SmoothGallery" page.