Difference between revisions of "Mobile"

(Created page with "== WPtouch == cd /usr/home/wiki/skins wget --no-check-certificate https://extdist.wmflabs.org/dist/skins/WPtouch-REL1_27-2091e4b.tar.gz * https://www.mediawiki.org/wiki/Sk...")
 
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
 +
== MobileFrontend ==
 +
 +
https://www.mediawiki.org/wiki/Extension:MobileFrontend
 +
 +
In /usr/home/extensions
 +
 +
wget --no-check-certificate https://extdist.wmflabs.org/dist/extensions/MobileFrontend-REL1_27-039b40b.tar.gz
 +
tar -xzf MobileFrontend-REL1_27-039b40b.tar.gz
 +
 +
In LocalSettings.php
 +
 +
require_once "$IP/extensions/MobileFrontend/MobileFrontend.php";
 +
$wgMFAutodetectMobileView = true;
 +
 +
 
== WPtouch ==
 
== WPtouch ==
 +
 +
* https://www.mediawiki.org/wiki/Skin:WPtouch
  
 
  cd /usr/home/wiki/skins
 
  cd /usr/home/wiki/skins
 
  wget --no-check-certificate https://extdist.wmflabs.org/dist/skins/WPtouch-REL1_27-2091e4b.tar.gz
 
  wget --no-check-certificate https://extdist.wmflabs.org/dist/skins/WPtouch-REL1_27-2091e4b.tar.gz
  
* https://www.mediawiki.org/wiki/Skin:WPtouch
+
In LocalSettings.php
 +
wfLoadSkin( 'wptouch' );
 +
 
 +
Change from:
 +
$wgDefaultSkin = "vector";
 +
to:
 +
$wgDefaultSkin = "wptouch";
 +
 
 +
Or set default based on user agent, e.g.:
 +
 
 +
<pre>if (preg_match("/mobile|webos|opera mini/i",
 +
$_SERVER['HTTP_USER_AGENT'])){
  
In LocalSettings.php
+
$wgDefaultSkin = "wptouch";
wfLoadSkin( 'WPtouch' );
+
}
 +
else {
 +
$wgDefaultSkin = "vector";  
 +
}
 +
</pre>

Latest revision as of 19:42, 18 August 2016

MobileFrontend

https://www.mediawiki.org/wiki/Extension:MobileFrontend

In /usr/home/extensions

wget --no-check-certificate https://extdist.wmflabs.org/dist/extensions/MobileFrontend-REL1_27-039b40b.tar.gz
tar -xzf MobileFrontend-REL1_27-039b40b.tar.gz

In LocalSettings.php

require_once "$IP/extensions/MobileFrontend/MobileFrontend.php";
$wgMFAutodetectMobileView = true;


WPtouch

cd /usr/home/wiki/skins
wget --no-check-certificate https://extdist.wmflabs.org/dist/skins/WPtouch-REL1_27-2091e4b.tar.gz

In LocalSettings.php

wfLoadSkin( 'wptouch' );

Change from:

$wgDefaultSkin = "vector";

to:

$wgDefaultSkin = "wptouch";

Or set default based on user agent, e.g.:

if (preg_match("/mobile|webos|opera mini/i",
$_SERVER['HTTP_USER_AGENT'])){

$wgDefaultSkin = "wptouch";
}
else {
$wgDefaultSkin = "vector"; 
}