Semantic MediaWiki: Difference between revisions

From CoMakingSpace Wiki

(quick explanation of properties used in "smart" navigation galleries)
(→‎Cheat Sheet: unions of results (OR))
 
Line 19: Line 19:
* [https://www.semantic-mediawiki.org/wiki/Help:Result_formats list of possible '''result formats'''] (e.g. table or gallery)
* [https://www.semantic-mediawiki.org/wiki/Help:Result_formats list of possible '''result formats'''] (e.g. table or gallery)
* [https://www.semantic-mediawiki.org/wiki/Help:Property_page/Filter how to '''filter''' for values on property pages]
* [https://www.semantic-mediawiki.org/wiki/Help:Property_page/Filter how to '''filter''' for values on property pages]
* [https://www.semantic-mediawiki.org/wiki/Help:Unions_of_results unions of results] - how to use "OR" instead of the (assumed) "AND" between two queries
** useful to make our [[MachineInfoBox]] find Tutors for Introductions to the "type" OR the "machine name", for example
** can also be used to embed machines of different types into the same page (if we want to do that)




[[Category:Software]]
[[Category:Software]]
[[Category:Wiki]]
[[Category:Wiki]]

Latest revision as of 01:06, 4 September 2022

We started using Semantic MediaWiki (SMW) for some "smart" functions of this wiki around June 2019. Feel free to join the effort!

How we use it so far:

Cheat Sheet

This is not supposed to replace the SMW documentation, but some things are nice to remember/share once you've finally found them:

  • Special:Ask - "sandbox" page for SMW queries (help)
  • assigning properties
    • in-text annotation: [[Property::value]] (only "value", or its |alt text, is displayed)
    • hidden annotation: use the set function
      • alternatively, you could enter | (the space is important!) to the end of a property (e.g. [[Has demo::test| ]]) which might be necessary in certain template elements
  • list of possible result formats (e.g. table or gallery)
  • how to filter for values on property pages
  • unions of results - how to use "OR" instead of the (assumed) "AND" between two queries
    • useful to make our MachineInfoBox find Tutors for Introductions to the "type" OR the "machine name", for example
    • can also be used to embed machines of different types into the same page (if we want to do that)