Table of Contents
To Do Items
- how do I make the home page a table of contents, category list?
- how do I get the search box to work?
- how do I embed teachertube videos in my wiki?
- how do I enter a Math formula, seems the easiest is Microsoft Word - export math equation. Design Science - makers of MathType doesn't work with IE10 or 11
- how do you get a list of all users on a wiki?
Installation
- Moving a wiki from /wiki to /w recommends that MediaWiki be installed in /w instead of /mediawiki (as I did)
- Godaddy install on http://gisengineering.com/w/ with MediaWiki version 1.24.1, automatic update any new version, create backup
Amazon AWS
- Micro instances is free for first 12 months or 750 hrs each month.
-
- Step 0: login to console.aws.amazon.com jefferyjjensen.com normal (closed account on 5/24/2015)
- Step 1: Choose an Amazon Machine Image (AMI), Mark Hershberger recommends Debian based like Ubuntu Server 13.10 (PV) - ami-7eaecc4e (64-bit) available from Canonical (http://ubuntu.com/cloud/services) but I was unable to get this to work, so using Amazon Linux instead.
- Step 2: create a key pair name like username, then download key pair (jefferyjjensen.com/secure/aws/amazon.com/jjensen.pem)
- Step 3: visit https://console.aws.amazon.com/console/home > Elastic Computing (EC2) > Running Instance > Connect
- Step 4: create a SSH connection to Amazon AWS
- UltraEdit SSH/Telnet Account Manager
- General Tab
- Server: 54.186.193.221
- Port: 22
- Username: ec2-user
- Password: leave blank
- Authentication Tab
- Public Key Only
- Private key path: (e.g, jefferyjjensen.com/secure/aws/amazon.com/jjensen.pem, if skipped, will get error <b>Status: Failed to load key or certificate</b>
- UltraEdit SSH/FTP Account Manager
- Step 5: Installing a LAMP Web Server
- Step 6: download MediaWiki to /var/www/html/mediawiki (Install MediaWiki on CentOS)
- Step 8: test connection http://54.186.193.221/
- Step 9: transfer files
- scp -r -i /C/downloads/aws.amazon.com/jjensen.pem /C/downloads/aws.amazon.com/jjensen.pem ec2-user@54.186.193.221:/home/ec2-user/
- Step 9: MySQL Workbench
wiki.ccsdcurriculum.com
- Step 1. create a subdomain, http://wiki.ccsdcurriculum.com which points to www.ccsdcurriculum.com/mediawiki/mediawiki-1.22.3
- Step 1. Manual:Installing MediaWiki
- Step 2. download MediaWiki
- Step 3. login to SmarterASP.NET control panel and upload. Unzip using SmarterASP.NET file manager to ccsdcurriculum.com/mediawiki
- Step 4. SmarterASP.NET MySQL Manager. Database Name: db_991088_ccsd, password: normal
-
- Step 4a. MySQL Settings.
- Database Host: MYSQL5006.smarterasp.net
- Database Name: db_991088_ccsd
- Database Table Prefix: leave blank
- Database username: 991088_ccsd
- Database password: normal
- Step 4b. name of wiki: CCSD Curriculum
- your name: jjensen
- password: normal
- email address: jefferyjjensen@gmail.com
- Step 4c. user rights profile: private wiki
- extensions: cite, gadgets, imagemap, inputbox, parserfuntions, wikieditor
- enable file uploads
- directory for deleted files H:roothomejefferyjjensen-001wwwccsdcurriculum.commediawikimediawiki-1.22.3imagesdeleted
- save LocalSettings.php and upload to ccsdcurriculum.commediawikimediawiki-1.22.3LocalSettings.php
-
- Error: uncommitted DB writes (transaction from DatabaseBase::query (MessageBlobStore::clear)). in H:roothomejefferyjjensen-001wwwccsdcurriculum.commediawikimediawiki-1.22.3includesdbDatabase.php on line 3944
Logo and Favicon
- edit jefferyjjensen.com/mediawiki/LocalSettings.php using UltraEdit, line 44
- <b>$wgLogo = “http://jefferyjjensen.com/wikidata/img/JeffJensen135x135.jpg”</b>
- default logo is /mediawiki/skins/common/images/wiki.png
-
- image size is 32×32 pixels
- edit jefferyjjensen.com/mediawiki/LocalSettings.php using UltraEdit and add the following
- <b>$wgFavicon = “http://jefferyjjensen.com/wikidata/img/favicon.ico”;</b>
Extensions
Semantic Bundle
- Procedure to install
- Download Semantic Bundle
- Go Daddy File Manager, upload zip file (SemanticBundle-20140514.zip) to /home/jefferyjensen/public_html/gisengineering.com/w/extensions
- the extract using Go Daddy File Manager (/public_html/gisengineering.com/w/extensions)
- Maps
- Validator
- Widgets
- Arrays
-
- copy require_once lines of code
- require_once( “$IP/extensions/SemanticBundle/SemanticBundleSettings.php” );
- require_once( “$IP/extensions/SemanticBundle/SemanticBundle.php” );
- open www.gisengineering.com/w and login with fullname NormalOne as admin login
- http://www.gisengineering.com/w/Special:SMWAdmin then click on <b>Initialize or upgrade tables</b> button
- edit SemanticBundleSettings.php and uncomment Widgets lines (require_once and wgGroupPermissions)
-
- visit www.gisengineering.com/w/Special:AllPages select Widgets from the drop down
-
- copy and paste View source for Widget: YouTube
Collection Extension - PediaPress
- PediaPress Sales Christoph Kepper, sales@pediapress.com, T +49 (0) 6131 327 180 9
- EPUB conversion - Amazon Kindle doesn't support EPUB
- Idea is to take a MediaWiki page > export using DumpHTML > convert HTML to XML with Adobe InDesign > InDesign Import XML
- Install
- download Collection Extension
- upload to wwwjefferyjjensen.commediawikiextensions
- use smarterasp.net to unzip and extract
- rename folder wikimedia-mediawiki-extensions-Collection-bf7c4b9 to Collection
<syntaxhighlight lang=“php”>
- export wiki to PDF, ODF and DocBook XML
require_once( “$IP/extensions/Collection/Collection.php” ); </syntaxhighlight>
Quiz
- Hot Potatoes is used to create interactive multiple-choice exercises for the web.
Cite
- create folder mediawiki/extensions/Cite
- Download Cite extension and unzip in the mediawiki/extensions/Cite folder
- unzip wikimedia-mediawiki-extensions-Cite-e688aad.tar.gz
- rename folder to Cite
- edit jefferyjjensen.com/mediawiki/LocalSettings.php and add the following
<syntaxhighlight lang=“php”>
require_once( “$IP/extensions/Cite/Cite.php” ); </syntaxhighlight>
Lockdown
LiquidThreads
Scribunto
Category Tree
- “CategoryTree also lets you put, on any page, a similar collapsible, hierarchical list of categories, but this one also listing the pages that each category holds.” <ref name=“Working with MediaWiki”>Working with MediaWiki, Yaron Koren, p. 99</ref>
SyntaxHighlight_GeSHi
-
- see Help:Formatting
- Step 1. download from ExtensionDistributor select SyntaxHighlight_GeSHi. Select 1.22 (current stable MediaWiki). https://codeload.github.com/wikimedia/mediawiki-extensions-SyntaxHighlight_GeSHi/legacy.tar.gz/REL1_22
- Step 2. upload to web hosting account (e.g login to smarterasp.net control panel, place in jefferyjjensen.com/mediawiki/extensions)
- Step 3. unzip using smarterasp.net file manager
- Step 4. rename directory wikimedia-mediawiki-extensions-SyntaxHighlight_GeSHi-7fa4488 to SyntaxHighlight_GeSHi
<syntaxhighlight lang=“php”> wikimedia-mediawiki-extensions-SyntaxHighlight_GeSHi-7fa4488 to SyntaxHighlight_GeSHi </syntaxhighlight>
- Step 5. edit LocalSettings.php, add the following at the end of the file
<syntaxhighlight lang=“html4strict” highlight=“4” enclose=“div”>
- unzip in extensions folder, creates subfolder geshi, need to rename
require_once “$IP/extensions/SyntaxHighlight_GeSHi/SyntaxHighlight_GeSHi.php”; </syntaxhighlight>
- Step 6. Edit a wiki page. Enclose code in <syntaxhighlight> tags
<code> <syntaxhighlight lang=“html4strict” line start=“100” highlight=“5” enclose=“div”> HTML module goes here… </syntaxhighlight> <\/code>
Widgets
- Step 2 - to see all Widgets defined in your system, you can simply go to the page http://wiki.jefferyjjensen.com/wiki/Special:AllPages. select “Widget” in the namespace dropdown and click 'Go' button. Should see Widget:YouTube
- Issues with youtube being blocked, use https://www.youtube.com instead of http
- Firefox extension Disconnect is reported to help also
-
Widget:Html5media
- Step 1. install MediaWiki Widgets extension
- Step 2. visit http://www.mediawikiwidgets.org/Html5media
- Step 4. copy entire contents of source page
- Step 5. visit http://wiki.jefferyjjensen.com/wiki/Widget:Html5media and since this is the first time visiting the page (doesn't exist), click the Edit this page link
- Step 6. paste in contents of source page and save
- Step 7. edit a MediaWiki page and add the following
<syntaxhighlight lang=“php”> url=http://jefferyjjensen.com/secure/videos/jefferyjjensen.com/Ch12SheetMetalDefaults-FanCoverMP4.mp4 |width=640 |height=360 </syntaxhighlight>
GeoGebra
- Installation
- login to smarterasp.net control panel and create a directory <b>GeoGebra</b> in the <b>extensions</b> folder
- upload Wikimedia-mediawiki-extensions-GeoGebra-4371f58.tar.gz to above directory
- unzip in the same folder, will create a sub-directory Wikimedia-mediawiki-extensions-GeoGebra-4371f58
- edit LocalSettings.php and add the following code
<syntaxhighlight lang=“php”>
require_once( “$IP/extensions/GeoGebra/GeoGebra.php” ); </syntaxhighlight>
Math
- Math Magic works with Adobe InDesign, Captivate
NOMATHJAX
- MathJax works with MediaWiki Extension:Math
- Using MathJax in a Theme File MediaWiki /jefferyjjensen.com/mediawiki/skins/Vector.php
- Loading and Configuring MathJax
- Integrating MathJax in a webpage by caseywstark caseywstark@gmail.com
- Step 0 - see if MathJax extension is already installed by visiting Special:Version
- Step 1 - install Extension:MathJax
- a) download MathJax.php and mwMathJaxConfig.js from MathJax Extension. Documentation can be found at MediaWiki Extension:MathJax
- b) make directory jefferyjjensen.com/mediawiki/extensions/MathJax
- c) upload MathJax.php and mwMathJaxConfig.js to above directory
- Step 2 - edit LocalSettings.php
- a) add the following
<syntaxhighlight lang=“php”> <script type=“text/javascript”
require_once( “$IP/extensions/MathJax/MathJax.php” ); </script> </syntaxhighlight>
- Step 3 - type some math markup in a wiki page
- Step 1 - reference the MathJax CDN and Using MathJax in popular web platforms
- add this in the head tag, which I think is stored in the theme for wordpress and in jefferyjjensen.com/mediawiki/skins/Vector.php for MediaWiki (see Using MathJax in popular web platforms)
<syntaxhighlight lang=“php”> <script type=“text/javascript”
src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
</script> </syntaxhighlight>
- Step 2 - add math markup language to webpage. Hopefully can just type the equation in Microsoft Word Equation Editor and then copy the MathML and paste in the webpage
<syntaxhighlight lang=“php”> <math xmlns=“http://www.w3.org/1998/Math/MathML”>
<mi>a</mi><msup><mi>x</mi><mn>2</mn></msup> <mo>+</mo> <mi>b</mi><mi>x</mi> <mo>+</mo> <mi>c</mi> <mo>=</mo> <mn>0</mn>
</math> </syntaxhighlight>
- Default skin is vector see LocalSettings.php $wgDefaultSkin = “vector”;
- Vector is a modern version of MonoBook
- I was hoping there was a Math MediaWiki widgets that allowed me to just copy and paste MathML from MathType into the widget tag in the editor.
Navbox
- Step 0: see if ParserFunctions Extension is installed Special:Version
- Step 1: install ParserFunctions Extensions but the extension is already bundled with MediaWiki 1.18 and above.
- edit jefferyjjensen.com/mediawiki/LocalSettings.php
- require_once “$IP/extensions/ParserFunctions/ParserFunctions.php”;
- Step 2: install HTML Tidy
Flickr
- Extension:Flickr - upload your photos to Flickr and then share them in your wiki!
- Edward Simpson, ewwsimpson@gmail.com
- Step 1. login to flickr.com, for example flickr screen name: jefferyjjensen, google: jefferyjjensen@gmail.com password: NormalOne
- Questions
- How do you make a flickr directory (collection) to store all the images for http://wiki.jefferyjjensen.com/wiki/Autodesk_Inventor.
- go to Organizr > Sets & Collections tab > click create a new collection > Autodesk_Inventor (Autodesk_Inventor Collection)
Google Analytics
Setup
Short URL
- Reference
- Step 1. edit jefferyjjensen.commediawikiLocalSettings.php file, note I installed mediawiki in /mediawiki, not /w as the help file says.
- $wgScriptPath = “/mediawiki”;
- $wgArticlePath = "/wiki/$1“;
- $wgUsePathInfo = true;
- Step 2. edit jefferyjjensen.comweb.config and within the system.webServer tag, add the following
- SmarterASP.net supports Microsoft URL Rewrite 2.0 on IIS8
-
- Changing the URL structure. By default, MediaWiki URLs appear in a format like:
- mywiki.com/mediawiki/index.php?title=Main_page
- However, the preferred format is something more like:
- mywiki.com/wiki/Main_Page
- This is the format that Wikipedia and other Wikimedia sites use. The 'wiki' directory can have any name, though 'wiki' makes sense for obvious reasons. There are various approaches to changing the URL format, based primarily on whether you have root access on the server on which the wiki resides. You can see all the steps required for the various approaches here: https://www.mediawiki.org/wiki/Manual:Short_URL
- We will just note that there are some cases when users want to have a URL structure that looks simply like:
- mywiki.com/Main_Page
- It's certainly a clean-looking URL, but this is not recommended, because, among other reasons, it means that your server can't have helper files like robots.txt and favicon.ico. You can see a longer discussion of this approach here: https://www.mediawiki.org/wiki/Manual:Wiki_in_site_root_directory" <ref name="Working with MediaWiki">[[http://workingwithmediawiki.com|Working with MediaWiki, Yaron Koren, p. 11-12</ref>
Categories
- Level 1 - Grandparent Category
- Main
- Main Page
- Level 2 - Parent Category
- Autodesk Inventor
- Level 3 - Child Category
- Machine Vise, Cams, Gears, Geneva Wheel
- “Categories are MediaWiki's basic method of organizing information. On wikis that don't use Semantic MediaWiki, categories are really the only way to tag information about pages. Categories, for that reason, have been used in a large variety of ways - you only have to look at the explosion of categories on Wikipedia to see that. On the English-language Wikipedia, there are at least 6 ways in which categories get used:
- to establish the basic type of page's subject, e.g. 'Space Shuttles'
- to define further characteristics of a page's subject, e.g. 'Italian generals'
- to note a larger topic to which this page's subject relates, e.g. 'Theosophy'
- to tag temporary information about the page itself, e.g. 'Proposed deletion as of September 20, 2012'
- to serve as a container super-category for other categories, e.g. 'Symphonies by composer'
- to tag pages other than regular pages or categories, e.g. 'Animal templates'
- There are better ways of tagging much of this information, which take less work and lead to less redundancy. In fact, Semantic MediaWiki, which we'll get to in later chapters, was first thought up in part in order to remove the need for the profusion of categories on Wikipedia. Still, even with Semantic MediaWiki, categories play an important role.” (Working with MediaWiki by Yaron Koren, p. 43-4)
- Step 1. Adding a page to a category Edit LocalSettings.php to include the following:
<syntaxhighlight lang=“php”>
- Category Browser breadcrumb-style
$wgUseCategoryBrowser = true; </syntaxhighlight>
- Step 2. Check if the proposed name category already exists, visit http://wiki.jefferyjjensen.com/wiki/Special:AllPages/Categories:
- Step 3a. create the parent category (e.g. Autodesk Inventor)
- Part A. Edit the wiki page you want to be included in the proposed category (e.g. Edit the Main Page)
- Part B. Add the following to the bottom of the wiki page, then click the <b>Save page</b> button
<syntaxhighlight lang=“php”> Inventor </syntaxhighlight>
- Part C. Click the newly created category link at the bottom of the saved wiki page
- Part D option 1. Will get a new page 'Creating Category:Machine Vise' then type
<syntaxhighlight lang=“php”> Vise </syntaxhighlight> In the edit portion of the page, will see the formatting buttons like Bold, Italic, Underline, etc. in the upper right corner of the editing portion of the page.
- Part D option 2. If the page already exists, will see Category:Autodesk Inventor heading. Below that will see another heading, <b>Pages in category “Autodesk Inventor”</b>
- Step 3b. create the child category (e.g. Geneva Wheel)
- Part A. Edit the parent wiki page you want to be included in the proposed category (e.g. Edit Inventor
- Part B. Add the following to the bottom of the wiki page, then click the <b>Save page</b> button
<syntaxhighlight lang=“php”> Wheel </syntaxhighlight>
- Part C. Click the newly created category link at the bottom of the saved wiki page Wheel
- Part D option 1. Will get a new page 'Creating Category:Geneva Wheel' then type
<syntaxhighlight lang=“php”> Wheel </syntaxhighlight>
- Step 4. assign a category to a page
- Part A. visit the child page, say Vise and edit the page. At the bottom add the following:
<syntaxhighlight lang=“php”> Inventor </syntaxhighlight>
- Part B. save the page. Then click the Autodesk Inventor category link at the bottom of the page. Should see that Vise is now listed as a child category of the Inventor parent page.
- “To assign a category to a page, simply add the link Category:Category name enclosed in square brackets to the page's wikitext. The usual place to add it is at the bottom of the page.”
<syntaxhighlight lang=“php”>
Sort of Warcraft:Class Guides of Magic:Class Guides </syntaxhighlight>
- Question: How do you make a category reference to the Main Page?
- Recommend using Categories instead of subpages
- MediaWiki Manual shows subcategories
Transclusion
- “You can embed pages within other pages - if, for instance, you have a lot of content whose editing you want to break up into multiple pages but still display together. If you have a page like 'History of chairs' that you want to embed in a page called 'Chairs', you can do that with the following wikitext:
<syntaxhighlight lang=“php”> history_of_chairs </syntaxhighlight> For pages in namespaces other than the main one, you simply put the entire page name in curly brackets, like: <syntaxhighlight lang=“php”> how_to_get_started </syntaxhighlight> Such embedding is also called 'transclusion'. The most important use of such transclusion is to include templates, which, unlike other page types, can take in variables when they're called. Templates are covered later in this chapter. Within transcluded pages, one can add the markup tags <noinclude>, <includeonly> and <onlyinclude>, all of which affect what shows up when the page is both viewed on its own, and transcluded elsewhere. These three tags are all covered in the section on templates.” (Working with MediaWiki by Yaron Koren, p. 29-30)
References
Subpages
- “Subpages are a handy way to break up a single page into multiple pages, if it gets too big or unwieldy. A subpage is simply a page whose name takes the form “main page name/additional text”, where “main page name” already exists. So if you have a page about the company Ace Motors, and it contains a long section about company's history, you could spin off that section into its own page, named “Ace Motors/History”, and link to it from the “Ace Motors” page.” (Working with Mediawiki by Yaron Koren, p. 52)
- “Of course, you could also call the page 'History of Ace Motors', which is how it would be done on Wikipedia (Wikipedia doesn't use subpages in its main namespace, though it does use them in other namespaces, like 'Wikipedia:' and 'Template:'). So are subpages just another naming convention? To some extent, yes, although MediaWiki does offer one important feature that makes subpages feel more like they 'belong' to their main page: if you turn on the subpages, any page with a slash in its name will include a small 'breadcrumb' link at the top, pointing back to the 'main' page, i.e., the section before the slash, provided that the main page exists. This small feature goes a long way toward making subpages feel legitimate.” (Working with Mediawiki by Yaron Koren, p. 52-3)
- “Sub-subpages, and pages further down the hierarchy, are also possible, provided that each page further up in the hierarchy already exists. The 'breadcrumb' link at the top will link to each sub-section of the page name in turn. So you could have a page like “Ace Motors/History/Europe/1900-1950”, and, if subpages are enabled for the main namespace, the top of the page will look like: (Working with Mediawiki by Yaron Koren, p. 52-3)
Enabling subpages
- “Subpages are enabled through the global variable $wgNamespacesWithSubpages, which by default is empty. If you want to have subpages, say, the main namespace and the template namespace, you could add the following to LocalSettings.php:
<syntaxhighlight lang=“php”> $wgNamespacesWithSubpages = array( NS_MAIN, NS_TEMPLATE ); </syntaxhighlight>
Conversely, if you wanted every namespace to have subpages, you would be best off calling array_fill(), like the following:
<syntaxhighlight lang=“php”> $wgnamespacesWithSubpages = array_fill( 0, 200, true ); </syntaxhighlight>
(In this case, 200 is an arbitrarily high number, with the assumption that there are no namespaces on this wiki with an ID greater than 200).” (Working with Mediawiki by Yaron Koren, p. 53)
Videos
- “A wiki doesn't usually consist of text alone, and often it's helpful to embed outside media into the pages. MediaWiki itself doesn't allow for embedding HTML and JavaScript within pages, though, which means that audio and video players, and other content like RSS viewers, can't be added by default into MediaWiki. To get around this problem, a staggering array of extensions have been created, tasked with embedding specific players and widgets. Of the around 1,000 extensions listed on mediawiki.org, 44 are in the 'Video player extensions' category; and around 12 exist for YoutTube alone. Each one embeds into the wiki page some variation of the required HTML and JavaScript. The need for all of these ended, however, in 2008, when the Widgets extension was released.” (Working with MediaWiki by Yaron Koren, p. 263)
- EmbedVideo supports TeacherTube
Image
Animated GIFs
Formatting
- Basic wiki formatting text
<syntaxhighlight lang=“php”> Example Adds wiki page to category 'example' thumb|Text image thumbnail –~~~~ signature with timestamp </syntaxhighlight>
Headings
<ul> <li>Reference</li> <ul>
<li>[[http://www.mediawiki.org/wiki/Help:Formatting|MediaWiki Help:Formatting]]</li>
</ul> </ul>
MediaWiki and Moodle
MediaWiki Support desk
MediaWiki People
- Mark A. Hershberger, from Lancaster Pennsylvania, mah@nichework.com rate is $85/hr hexmode.com and Wikipedia User:MarkAHershberger mah.everybody.org/contact-info
recommend using Amazon Web Service or digitalocean.com to host mediawiki sites
- Dan Bucharest of Romania - dansevastian@yahoo.com does MediaWiki consulting for Elance and oDesk, price is $35 an hour.
- Jan Steinman, jan@bytesmiths.com, Jan_Steinman EcoReality Wiki and MediaWiki User
- Yaron Koren, yaron57@gmail.com
- Joel Natividad chair of the Semantic MediaWiki Conference (SMWCon) Spring 2013
References
<references />
–Jjensen (talk) 21:01, 9 March 2014 (PDT) Software Applications:MediaWiki MediaWiki notes by Jeff Jensen