Last modified: 2014-02-12 23:38:25 UTC
The gallery format of Semantic Result Formats (http://semantic-mediawiki.org/wiki/Help:Gallery_format) could be made to support foreign file repos, such as http://www.mediawiki.org/wiki/InstantCommons, where local file pages are probably missing most of the time. This is currently prevented by line 257 in SRF_Gallery.php: if ( $imgTitle->exists() ) { We still need to check that the file exists, of course. Not sure what the best method is. Maybe something like this: $imgFile = wfFindFile( $imgTitle ); if ( $imgFile && $imgFile->isVisible() ) {
Another user just posted a demonstration of the problem here: http://scratchpad.referata.com/w/index.php?title=Testask
I am the user who posted demonstration above. You are writing > This is currently prevented by line 257 in SRF_Gallery.php: > if ( $imgTitle->exists() ) { > We still need to check that the file exists, of course. Not sure what the best > method is. Maybe something like this: > $imgFile = wfFindFile( $imgTitle ); > if ( $imgFile && $imgFile->isVisible() ) { This code belongs to function addImageProperties, but using debug printing i have figured out that it does not even called. So i belive the guilty code is if ( $this->params['imageproperty'] !== '' && in_array( $this->params['imageproperty'], $printReqLabels ) || $this->params['redirects'] !== '' && in_array( $this->params['redirects'], $printReqLabels ) ) { at line 148 of SRF_Gallery.php Actually, I dont even understand what this condition checks. All after the $this->params['imageproperty'] !== '' code.
However, if I understood the mailing list conversation correctly, the problem Uimanov Aleksey is experiencing, does not have with this bug (a suggestion to make foreign repos work) to do.