Extension talk:SmoothGallery
Contents
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 }}
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.
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?
Just to add. First try was in Firefox browser. Tried in IE-7, the problem remains even in preview mode.
1.17 is a different beast. It is using Resource Loader, which this extension isn't written to support yet.
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
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! ;)
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; }
replace
function initSmoothGalleryTag( $input, $argv, $parser ) { $output = initSmoothGallery( $input, $argv, $parser ); return $output; }
As I stated in the title, does SG makes Cite does not work? Whenever I inserted Template:Reflist 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?
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.
Notice that this extension is not currently compatible with SmoothGallery 2.1
- What's involved to make this extension compatible? Thanks.
is this extension abandoned or is it still under devlopment?
We just migrated a copy of our existing MW 1.16 database to Linux and the Sgallery code broke. I am unsure whether there is a parameter that we are missing which Windows is more forgiving about, or if this is perhaps incompatible with Linux. Please advise.
Warning: Invalid argument supplied for foreach() in /home/tarasius/public_html/extensions/SmoothGallery/SmoothGalleryClass.php on line 23 Warning: Invalid argument supplied for foreach() in /home/tarasius/public_html/extensions/SmoothGallery/SmoothGalleryClass.php on line 78
MediaWiki 1.16.0 PHP 5.2.14 (cgi) MySQL 5.0.91 SmoothGallery 1.1g
I'm receiving this exact same issue. I can't figure out anything to do to get the SmoothGallery to function properly. I see that this issue was reported back in November, has anyone else had this same issue and resolved it since then?
Could you paste the wikitext you're using?
<sgallery> Noir01.jpg Noir02.jpg Noir03.jpg Noir04.jpg </sgallery>
What happens if you run 1.1h instead?
I have the same exact problem. I'm running MediaWiki 16.3, php 5.2.x. And here's what I am using in my page:
<sgallery> Affenpinscher.jpg Afghan_Hound.jpg American_Pit_Bull.jpg </sgallery>
Here's a link to the test site that I set up to play around:
http://www.thepetwiki.com/EStahl/mw/index.php?title=Foxes
If anyone could give me a hand with it, I'd really appreciate it.
Thanks!
i got a couple of errors when i tried installing on my wiki, first using <sgallery> i got that there was an invalid argmuent supplied for foreach() on line 23 of smoothgalleryclass, when using #sgallery i got Fatal error: Call to undefined method Title::expand() in /home/aiowiki/aiowiki/w/includes/parser/Parser.php on line 926
hi, does anyone knows how to change the font size of the caption, I find it too small. thanks.
By using the development version of the SmoothGallery extension, I was able to get a gallery to show up. However, for some reason the title of the page gets changed to File:ImageXX.jpg, where ImageXX.jpg is the last image in the list of files for the sgallery, and all section titles have strange text added to them. For example:
==History==
Displays:
UNIQ58e2197a757753b4-h-1--QINUHistory
I saw that someone previously had the issue with the garbage text in the section headers, but their fix was to not show the infopane. If I set my sgallery tag to
<sgallery showinfopane="false">
It does not solve the problem. Can anyone offer any help?
Okay, so a little more digging and it looks like I can get it working, though I can't use the <sgallery> tag. The following works for me:
{{#sgallery:
|showinfopane=false
|imagelist=Image01.jpg
Image02.jpg
Image03.jpg
Image04.jpg
Image05.jpg
}}
Why would the parser function tag work and not the <sgallery> tag? Also, is there a way to set the infopane to false as a default so I don't have to use that tag every time?
I was able to find the file that contains the defaults. They're in SmoothGalleryParser.php. I used "showinfopane" => false, and now I can use <sgallery> to my heart's content. Now I just need to find out how to get the infopane working without garbling up my pages, and I'll be all set. Can someone PLEASE help with this?
I was thinking of dropping support for old style tags altogether. Is there a reason why you need to use this rather than the parser function style?
The <sgallery> tag just seems cleaner and easier to remember how to use than using the parser function style. That being said, people could always learn how to use the parser function version if need be.
The main issue though is that if showinfopane isn't set to false, there's all kinds of garbage text that shows up in the section headers and the page title gets changed.
Here's an example of a page that has the garbage text issue: http://www.threeawiki.com/Medic_Square²
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?
hi, I've noticed that files used in smoothgallery shows up in the unused files special page, how do I prevent that? thanks
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 :
<sgallery> http://website.com/picture.png%7Cdescription </sgallery>
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.
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)
hi, ive had sgallery installed for a while now. All of a sudden i cant click through to the next picture anymore. Check http://klusopedia.nl/klussen/Tips_hoe_te_zagen for an example. Who knows what might have cause this?
Hi,
I have Mediawiki 1.15 installed with SmoothGallery 2.0 and the latest version of the extension. All my files - JonDesign's stuff and this extension's PHP files are here:
/extensions/SmoothGallery/
The paths and everything are set correctly. However, I, till recently, was unable to get even the <sgallery> tag to work. I was getting the following error:
Fatal error: Unsupported operand types in /home/XXX/includes/parser/LinkHolderArray.php on line 33
I followed the steps outlined here and got it working. I am now getting the images in a panel properly and it seems great. However, there are three problems:
1) I cannot get the Image Titles to show up even if I use the '|' syntax. Same problem as mentioned by User:Mindbender here. Is this functionality working for people? It'd be really helpful if someone could let me know how
2) The #sgallery tag is not working at all. I dont even see the hook in my Special:Version page. What could be wrong? It doesnt seem to be a skin problem as I tried it with Monobook and Ontoskin2, but does not work. It would be of enormous help if someone could help me with this.
3) I am using images from Wikimedia Commons using $wgForeignFileRepos. Is there a way to get these images to show up in SmoothGallery? I dont seem to be having any success in that.
Thanks a lot in advance for any suggestions!
OK. Here are the updates:
1) Updating to the latest version - 1.1h presumably (whichever corresponded with Mediawiki 1.16.x) - solved the Image captions issue and the #sgallery issue. There is no need now to comment out the $local_parser lines in SmoothGalleryParser.php. Everything's working fine now.
2) However #sgallery does not accept images which are duplicates of wikimedia commons images. Something clashing with $wgForeignFileRepos.
3) <sgallery> tag is clashing with Semantic Mediawiki queries. It works if there is only the first part of the query eg:
{{#ask: [[Category:Cities]]
|limit=10
|format=list
}}
But does not work if you specify more eg:
{{#ask: [[Category:Cities]]
| ?country
|limit=10
|format=list
}}
The error produced is a popup message saying "Handler could not be removed"
Any suggestions?? Veryhuman 03:25, 3 September 2010 (UTC)
Hello,
I have tried adding this extension to a wiki that I am working on. The extension can be enabled without problems, but as soon as a user tries adding a gallery to their page, an Internal Server Error is returned. Looking through the logs, I found this:
PHP Fatal error: Unsupported operand types in /srv/www/htdocs/wiki/includes/parser/LinkHolderArray.php
As far as I can tell, this happens because the array $this->interwikis is undefined. This error happens even if I disable all other extensions. I found a hack to the file that got rid of the error, but the gallery does not display properly. I can't find apparent cause or solution. Do you have any ideas?
Thanks!
external link icon appears in gallery + internal and external URL's in caption box do not function
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!
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).
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.
Yeah, this was likely going to be the fix I used.
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.
The following error occurs with SmoothGallery extension and PHP 5.3:
Detected bug in an extension! Hook smoothGalleryParserOutput failed to return a value
This is solved by changing the line in SmoothGallery.php:
function smoothGalleryParserOutput( &$outputPage, &$parserOutput ) {
to:
function smoothGalleryParserOutput( &$outputPage, $parserOutput ) {
Mediawiki specifies that the second parameter is not a reference, and when it was one, it broke the hook completely.