Hi, The `#subobject` parser function itself understands the JSON notation (without deep nesting) as demonstrated in [0].
> and I'm trying to add support for reading JSON content (actually from > MediaWiki JSON content model pages). > > I try to trigger subobject storage using \SMW\ParserFunctionFactory, Best to create a ticket for that sort of question since email is not the best place to post code snippets. [0] https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/tests/phpunit/Integration/JSONScript/TestCases/p-0211.json Cheers On 1/27/18, Toni Hermoso Pulido <toni...@cau.cat> wrote: > Hello, > > after a long while I'm trying to update a extension I started: > https://github.com/toniher/SemanticDataImport > > and I'm trying to add support for reading JSON content (actually from > MediaWiki JSON content model pages). > > I try to trigger subobject storage using \SMW\ParserFunctionFactory, > https://github.com/toniher/SemanticDataImport/blob/master/includes/SDImportData.php#L237 > > but it does not work since I imagine that Parser object is not the > proper way to handle it since all this is being called from > PageContentSaveComplete hook... > > I imagine I should generate subobjects in a programmatic way and > associate them to the current page. > > Any tip or existing extension that would follow a similar approach to > add Semantic Data content as reference would be appreciated. > > Thanks! > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > Semediawiki-devel mailing list > Semediawiki-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/semediawiki-devel > ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel