FANDOM


Schema is a script to make it easier to edit Schema instances in MediaWiki. The idea is to port the schema.org features into a form usable in MediaWiki pages.

Background Information

What is Schema?

Schema is a vocabulary of ways to label the contents of a webpage. For example, if you had a page with information about a person, one would label the text with their birthday as birthDate.

Why should we bother with this?

Schema makes it easier for search engines to understand the contents of your pages. This means that traffic is more likely to come to your pages.

Installation Instructions

Note: Because of the way it's implemented, this script can not be installed individually. It can only be used Wiki-wide.

Step 0: go to your wiki's MediaWiki:Common.js file
Step 1: amend it with this:
importScriptPage('MediaWiki:Schema/SchemaLoader.js', 'dev');
Step 2: use action=purge and purge killing refreshes to purge until the script loads properly.

Editing Schemas

To edit a schema or create a new schema, go here: "http://wikiName.wikia.com/wiki/Schema:InsertSchemaNameHereWithUnderscoresInsteadOfSpaces?action=edit" , edit the page to have the appropriate content, and publish. It's that simple. Every schema on a wiki must have a unique name. Try to stick to alphanumerical characters for the names. It's just a good idea.

The namespace is the same name in every language.

Adding Schemas to Pages

To add a schema to a page, the schema has to be written and properly named. See "Editing Schemas" for how to do that. The schema in question must be written on the same wiki that it will be used on. Schemas can only be added to non-raw namespaces, such as main and template.

Assuming the schema actually has been written in a usable form and published on the same wiki, do the following to add a schema to the page:

0. Go to the page you want to add the schema to.
1. Edit that page.
2. At the top of the page, add this:
<span class="schema" data-widget-id="TheSchemaNameWithUnderscoresInsteadOfSpaces"></span>
3. Publish the page.
4. Wait and hope for the webcrawlers to index the page correctly. This can take a while.

Known Bugs

  • Due to the death of verbatim, this feature injects the schemas into a page using client-side Javascript. As a result, crawlers which do not support client-side Javascript do not support this implementation of schema. For reference, this means that Google is supported, Yahoo and Bing are probably not supported, and Yandex remains to be determined. As a side note, Google's schema testing tool doesn't support client side Javascript either, so while the crawler understands schema, it's very difficult to verify and test it. Sorry.
  • Due to the death of verbatim, this script had to be completely re-written. Several features were lost, including a dedicated schema editor.

See More

Future Features

  • A dedicated schema editor.
  • Auto-complete in the editor.
  • Bing/Yahoo support
  • Yandex support "it's currently theoretical"
  • Moving the injection process back to the server. somehow.

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.