Extension talk:SMWAskAPI

PHP Warning
I get following deprecating warnings: Deprecated: Call-time pass-by-reference has been deprecated in C:\xampp\htdocs\wiki\extensions\SMWAskAPI\api\SMWAsk_API.php on line 79 Deprecated: Call-time pass-by-reference has been deprecated in C:\xampp\htdocs\wiki\extensions\SMWAskAPI\api\SMWAsk_API.php on line 85 Deprecated: Call-time pass-by-reference has been deprecated in C:\xampp\htdocs\wiki\extensions\SMWAskAPI\api\SMWAsk_API.php on line 99 Deprecated: Call-time pass-by-reference has been deprecated in C:\xampp\htdocs\wiki\extensions\SMWAskAPI\api\SMWAsk_API.php on line 145 Deprecated: Call-time pass-by-reference has been deprecated in C:\xampp\htdocs\wiki\extensions\SMWAskAPI\api\SMWAsk_API.php on line 152 Deprecated: Call-time pass-by-reference has been deprecated in C:\xampp\htdocs\wiki\extensions\SMWAskAPI\api\SMWAsk_API.php on line 169

Details of my configuration:
 * MediaWiki	1.16.2
 * PHP	5.3.5 (apache2handler)
 * MySQL	5.5.8
 * Semantic Bundle (Version 2011-03-29.20110329)

Any hints? Cheers, --Rolze 09:22, 6 April 2011 (UTC)

Yes, some call-time pass-by-reference was actually done in several parts of the extension, and your apache is configured to display such warnings. This has been fixed in the latest version, available on the SVN. The corresponding zip archive will follow briefly --PierreMz 10:05, 12 september 2011 (UTC+2)

Updated for SMW 1.6
These changes made it work for me on SMW 1.6 Index: api/SMWAsk_API.php

=
====================================================== 125c125 <                $item['title'] = $rowsubject->getShortText(null, null); --- >                $item['title'] = $rowsubject->getTitle; 149,150c149,151 <            $item['uri'] = $wgServer. $wgScriptPath. '/index.php?title='. $rowsubject->getPrefixedText; <            $page_cats = smwfGetStore->getPropertyValues($rowsubject, SMWPropertyValue::makeProperty('_INST')); // TODO: set limit to 1 here --- >            $item['uri'] = $wgServer. $wgScriptPath. '/index.php?title='. $rowsubject->getTitle; >            $ptype = new SMWDIProperty( '_INST' ); >            $page_cats = smwfGetStore->getPropertyValues($rowsubject, $ptype); // TODO: set limit to 1 here 152c153 <                $this->addPropToItem(&$item, 'type', array(reset($page_cats)->getShortHTMLText)); --- >                $this->addPropToItem(&$item, 'type', array(reset($page_cats)->getTitle)); Cariaso 16:31, 28 August 2011 (UTC)

Now two versions of the extension, to support both SMW 1.5 and 1.6
The patch above has been applied to the trunk of SMWAskAPI. The version for SMW 1.5 has been kept in branches/smw-1.5/.

Both versions are available to direct download :
 * http://sourceforge.net/projects/smwaskapi/files/SMWAskAPI-0.9a-r2.zip/download for SMW 1.6
 * http://sourceforge.net/projects/smwaskapi/files/SMWAskAPI-0.9a-r1.zip/download for SMW 1.5