Extension:Factscript

This extension works much like the SMW Factbox extension, except the output is all javascript.

When triggered, the javascript object "smw_properties" is created. The properties of the object match the SMW property names, and the values match the values. When a property contains more than one value, the object is an array:

 var smw_properties = { "Book" : "Shades of Hope", "Chapter" : "unknown", "Hero" : [ "Abigail", "Thorak", "Inteus" ],   "Location" : "Farlourn", "Title" : "A Helping Hand" };

todo
Better type awareness
 * Numbers without quotes
 * dates as "new Date(...)"

Better installation instructions

Translations from "factbox" to "factscript"

installation
1. Create a new file "$IP/extensions/SemanticMediaWiki/includes/Factscript.php" by copy-and-paste from the "source", listed below

2. wire reference to the new code
 * Do a file-content search in $IP/extensions/SemanticMeidaWiki for "factbox"
 * duplicate each line with "factbox" in it, and change "factbox" to "factscript" (honor case conventions: eg use __NOFACTSCRIPT__ instead of __NOFACTscript__)

3. Test it to see if you found all the factbox references