Hey,

> I 've had an extension that lists article authors in an article, and
thought it would be convenient to migrate that to an SMW extension
instead...

Cool :)

> I have registered my special property from the smwInitProperties hook

That's good.

> and I'm adding the author properties from MediaWikis ArticleSaveComplete
hook.

This is not, and neither is doing this for every property:
$store->updateData($SD);

The updateData method writes the provided SemanticData object to the data
store, rather then updating some copy the store class holds. It'd be better
to use the SMWStore::updateDataBefore hook, which is called at the start of
the updateData method, and gets passed a SemanticData object you can add
to. In the handler of this hook, you should add all your properties. You'll
be able to get to the title of the modified page using
$data->getSubject()->getTitle().

Btw, if you are writing a whole extension, I recommend you try to get
commit access [0] to the WMF SVN repo and update your code there. This way
people can more easily give you feedback.

[0]
https://www.mediawiki.org/wiki/Commit_access_requests#Requesting_commit_access

Cheers

--
Jeroen De Dauw
http://www.bn2vs.com
Don't panic. Don't be evil.
--
------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure 
contains a definitive record of customers, application performance, 
security threats, fraudulent activity, and more. Splunk takes this 
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Semediawiki-devel mailing list
Semediawiki-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/semediawiki-devel

Reply via email to