Re: [SMW-devel] Adding Site Settings support to SMW?
Hi Yury, On Wed, Jul 16, 2014 at 1:32 AM, Yury Katkov katkov.ju...@gmail.com wrote: Hi Yaron! I think that for SiteSettings this patch could make sense although I'm strongly against such interdependencies between extensions (after trying to contribute to PageSchemas) Could you expand on that? Is AdminLinks mentioned in SMW? That's really strange and surprising - I thought it's just a header button and the predefined wikipage for the content (well, maybe it can also check, which extensions are installed). Every extension-related link in Special:AdminLinks is added by that extension. -Yaron -- WikiWorks · MediaWiki Consulting · http://wikiworks.com -- Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds___ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel
Re: [SMW-devel] Adding Site Settings support to SMW?
Hi! On Wed, Jul 16, 2014 at 3:37 PM, Yaron Koren ya...@wikiworks.com wrote: Hi Yury, On Wed, Jul 16, 2014 at 1:32 AM, Yury Katkov katkov.ju...@gmail.com wrote: Hi Yaron! I think that for SiteSettings this patch could make sense although I'm strongly against such interdependencies between extensions (after trying to contribute to PageSchemas) Could you expand on that? It's just a lot harder to contribute the code when there is such a dependency. In order to contribute the code I have to make changes not in one extension but in two or three. This can create inconsistency, like the one we can see now in Page Schemas: there are some features that are presented in PS but the code in SF still doesn't have support for them, because the changes haven't been accepted. I understand that you've had in mind the following scenario: there is Page Schemas and everyone can register their own extension in it. It didn't work well in the Page Schemas case but it can in principle work in case of Site Settings since it's not SMW-specific. Is AdminLinks mentioned in SMW? That's really strange and surprising - I thought it's just a header button and the predefined wikipage for the content (well, maybe it can also check, which extensions are installed). Every extension-related link in Special:AdminLinks is added by that extension. -Yaron -- WikiWorks · MediaWiki Consulting · http://wikiworks.com -- Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds___ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel
Re: [SMW-devel] Adding Site Settings support to SMW?
On 7/15/2014 7:25 PM, Yaron Koren wrote: Semantic MediaWiki already hooks into the first two: Admin Links via a function, and Page Schemas with a class. Hi Yaron - What function/class are those. Also, i happened to review PS extension's DTD - has it changed? ?xml javascript:searchRef('xml') version javascript:searchRef('version')=1.0encoding javascript:searchRef('encoding')=utf javascript:searchRef('utf')-8? !DOCTYPE javascript:searchRef('DOCTYPE') PageSchema javascript:searchRef('PageSchema') [ !ELEMENT javascript:searchRef('ELEMENT') PageSchema javascript:searchRef('PageSchema') (Template javascript:searchRef('Template')*) !ELEMENT javascript:searchRef('ELEMENT') PageSchema javascript:searchRef('PageSchema') (semanticforms_Form javascript:searchRef('semanticforms_Form')*) !ATTLIST javascript:searchRef('ATTLIST') PageSchema javascript:searchRef('PageSchema') name javascript:searchRef('name') CDATA javascript:searchRef('CDATA') #REQUIRED javascript:searchRef('REQUIRED') !ELEMENT javascript:searchRef('ELEMENT') Template javascript:searchRef('Template') (Field javascript:searchRef('Field')*) !ATTLIST javascript:searchRef('ATTLIST') Template javascript:searchRef('Template') name javascript:searchRef('name') CDATA javascript:searchRef('CDATA') #REQUIRED javascript:searchRef('REQUIRED') !ATTLIST javascript:searchRef('ATTLIST') semanticforms_Form javascript:searchRef('semanticforms_Form') name javascript:searchRef('name') CDATA javascript:searchRef('CDATA') #REQUIRED javascript:searchRef('REQUIRED') !ATTLIST javascript:searchRef('ATTLIST') Field javascript:searchRef('Field') name javascript:searchRef('name') CDATA javascript:searchRef('CDATA') #REQUIRED javascript:searchRef('REQUIRED') ] I looked at SiteSettings schema and wondering about a different idea -- how about duplicating mediawiki's interwiki table but with a blob of named-value settings. In this way other setup settings can be added with great ease. And it can be used as the anchor for definition of an smw-wiki farm. It could come in handy during cross-site joins in some future. -- Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds___ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel
Re: [SMW-devel] Adding Site Settings support to SMW?
Hi Yury, You're right that Page Schemas, unlike the other two, is not really a generic framework, and is pretty tightly integrated in with the standard SMW approach to data structures, which has caused some problems. Personally, I think Page Schemas works well now - I use it on a regular basis - but that of course is a matter of opinion. Like with any software, there's always room for improvement. -Yaron On Wed, Jul 16, 2014 at 10:46 AM, Yury Katkov katkov.ju...@gmail.com wrote: Hi! On Wed, Jul 16, 2014 at 3:37 PM, Yaron Koren ya...@wikiworks.com wrote: Hi Yury, On Wed, Jul 16, 2014 at 1:32 AM, Yury Katkov katkov.ju...@gmail.com wrote: Hi Yaron! I think that for SiteSettings this patch could make sense although I'm strongly against such interdependencies between extensions (after trying to contribute to PageSchemas) Could you expand on that? It's just a lot harder to contribute the code when there is such a dependency. In order to contribute the code I have to make changes not in one extension but in two or three. This can create inconsistency, like the one we can see now in Page Schemas: there are some features that are presented in PS but the code in SF still doesn't have support for them, because the changes haven't been accepted. I understand that you've had in mind the following scenario: there is Page Schemas and everyone can register their own extension in it. It didn't work well in the Page Schemas case but it can in principle work in case of Site Settings since it's not SMW-specific. Is AdminLinks mentioned in SMW? That's really strange and surprising - I thought it's just a header button and the predefined wikipage for the content (well, maybe it can also check, which extensions are installed). Every extension-related link in Special:AdminLinks is added by that extension. -Yaron -- WikiWorks · MediaWiki Consulting · http://wikiworks.com -- WikiWorks · MediaWiki Consulting · http://wikiworks.com -- Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds___ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel
Re: [SMW-devel] Adding Site Settings support to SMW?
Hi John, The Page Schemas class is linked in my original email; the Admin Links function is in SemanticMediaWiki.hooks.php. I would rather not get into the technical details of any of those extensions in this thread, except as it relates to SMW. However - it's true that a key-value approach for Site Settings would be more flexible than a hardcoded table, but Site Settings is also meant to be usable for a wiki farm, and I figured that a standard DB table would be easier for admins to deal with than a big key-value table. -Yaron On Wed, Jul 16, 2014 at 12:27 PM, John McClure jmccl...@hypergrove.com wrote: On 7/15/2014 7:25 PM, Yaron Koren wrote: Semantic MediaWiki already hooks into the first two: Admin Links via a function, and Page Schemas with a class. Hi Yaron - What function/class are those. Also, i happened to review PS extension's DTD - has it changed? ?xml version=1.0 encoding=utf-8? !DOCTYPE PageSchema [ !ELEMENT PageSchema (Template*) !ELEMENT PageSchema (semanticforms_Form*) !ATTLIST PageSchema name CDATA #REQUIRED !ELEMENT Template (Field*) !ATTLIST Template name CDATA #REQUIRED !ATTLIST semanticforms_Form name CDATA #REQUIRED !ATTLIST Field name CDATA #REQUIRED ] I looked at SiteSettings schema and wondering about a different idea -- how about duplicating mediawiki's interwiki table but with a blob of named-value settings. In this way other setup settings can be added with great ease. And it can be used as the anchor for definition of an smw-wiki farm. It could come in handy during cross-site joins in some future. -- Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds ___ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel -- WikiWorks · MediaWiki Consulting · http://wikiworks.com -- Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds___ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel
Re: [SMW-devel] Adding Site Settings support to SMW?
Hey, Can you give me some idea of what this code you'd put in SMW would look like? Is there already an example somewhere? Cheers -- Jeroen De Dauw - http://www.bn2vs.com Software craftsmanship advocate Evil software architect at Wikimedia Germany ~=[,,_,,]:3 -- Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds___ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel
Re: [SMW-devel] Adding Site Settings support to SMW?
Hi Jeroen, Unfortunately, there isn't yet a public example of an extension that hooks into Site Settings - if this potential code gets into SMW, SMW could become the first. But the basic idea is that the class would contain various static methods, each of which was called by a different Site Settings hook, that mainly did the following: added HTML for new fields to the Special:SiteSettings form, saved information from those fields to the database, and loaded information from the database into SMW's global variables. The latter two would be done by calling the Site Settings API, for what it's worth - there would be no direct database calls. By the way, the only SMW global variable that I'm currently planning to handle in this code is $smwgShowFactbox - but there's always the potential for adding additional settings. -Yaron On Wed, Jul 16, 2014 at 7:50 PM, Jeroen De Dauw jeroended...@gmail.com wrote: Hey, Can you give me some idea of what this code you'd put in SMW would look like? Is there already an example somewhere? Cheers -- Jeroen De Dauw - http://www.bn2vs.com Software craftsmanship advocate Evil software architect at Wikimedia Germany ~=[,,_,,]:3 -- WikiWorks · MediaWiki Consulting · http://wikiworks.com -- Want fast and easy access to all the code in your enterprise? Index and search up to 200,000 lines of code with a free copy of Black Duck Code Sight - the same software that powers the world's largest code search on Ohloh, the Black Duck Open Hub! Try it now. http://p.sf.net/sfu/bds___ Semediawiki-devel mailing list Semediawiki-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/semediawiki-devel