|
This page you are viewing is part of the SEVA Wiki Archive, Please visit the new Official Website! |
|
User:WikiAdmin
Contents
Seattle EVA
- User Management:
- Namespace messages
- MediaWiki:Whitelistedittext
- MediaWiki:Loginprompt
- MediaWiki:Sidebar
- MediaWiki:Topbar
- MediaWiki:Sitetitle = SeattleEVA
- MediaWiki:Pagetitle = $1 - SeattleEVA
- MediaWiki:Wikititlesuffix = ⧼Wikititlesuffix⧽
- Special:Interwiki - Management
- /etc/php4/apache/php.ini
- post_max_size = 80M
- upload_max_filesize = 80M
- Nested menus patches
- Nested menus are working in MonoBook and CologneBlue based skins...
- Changes made to includes/Skin.php, skins/MonoBook.php, skins/CologneBlue.php, skins/common/cologneblue.css, skins/monobook/main.css, and custom skin.
Search Enhancements
per [1] In includes/SpecialSearch.php there is a function showResults( $term ) which formats and outputs all the search results from a query, near the top add:
$wgOut->addHTML( wfMsg( 'Googlesearch', $term ) ); # add $wgOut->addWikiText( wfMsg( 'searchresulttext' ) );# above this
- MediaWiki:Googlesearch fix $3 and cleanup?
- MediaWiki:Nogomatch remove prompt to create page?
- MediaWiki:Searchresulttext cleanup/clear
In LocalSettings.php
# $wgDisableTextSearch = true; # $wgSearchForwardUrl = 'http://www.google.com/search?q=$1'; # $wgSearchForwardUrl = 'http://www.google.com/search?q=site%3Adigipen.edu+%22$1'; $wgNamespacesToBeSearchedDefault = array( -1 => 0, # Default setting 0 => 1, # Main 1 => 0, # Main talk 2 => 0, # User 3 => 0, # User talk 4 => 1, # SiteName 5 => 0, # SiteName talk 6 => 1, # Image 7 => 0, # Image talk 8 => 0, # MediaWiki 9 => 0, # MediaWiki talk 10 => 1, # Template 11 => 0, # Template talk 12 => 0, # Help 13 => 0, # Help talk 14 => 1, # Category 15 => 0); # Category talk
Licenses
- Wikipedia:Image_copyright_tags#Creative_Commons_Licenses
- http://www.gnu.org/licenses/license-list.html#OtherLicenses - GNU General Public License
- http://www.gnu.org/copyleft/fdl.html - GNU Free Documentation License
- http://creativecommons.org/licenses/by-sa/2.0/legalcode - Creative Commons Attribution-Sharealike 2.0 license
- http://artlibre.org/licence/lalgb.html - Free Art License
- In accordance with Title 17 U. S. C. Section 107, any copyrighted work in this message is distributed under fair use without profit or payment to those who have expressed a prior interest in receiving the included information for nonprofit research and educational purposes only. Ref. http://www.law.cornell.edu/uscode/17/107.shtml
DigiPen
A restricted wiki setup...
Setup Notes
New Files
extensions/Flash.php skins/DPSkin11.php skins/DPSkin21.php skins/DPSkin31.php skins/dpskin11 skins/dpskin31 skins/common/images/dpwiki.png
Modified Files
includes/SpecialWatchlist.php ( Select All ) includes/ImagePage.php ( file history for Users Only ) includes/SkinTemplate.php ( call new TopBar function ) includes/Skin.php ( TopBar, NewsTicker, Nesting ) languages/Language.php ( sitesubtitle ) skins/common/cologneblue.css ( sidebars ) skins/monobook/main.css ( sidebars ) skins/MonoBook.php ( Nesting Top-Sidebar ) skins/CologneBlue.php ( Nesting ) skins/Standard.php ( Nesting )
- Might need to start sql on the Mac like this...
mysqladmin shutdown -uroot -p /bin/sh /usr/bin/mysqld_safe --user=mysql --skip-networking --old-passwords &
- Trash a retired user account.
mysql -uroot -p mysql mysql> SELECT * FROM user; mysql> DELETE FROM user where User="bad_user";
- Trash an old/test database.
mysqladmin -u root -p drop wikidbtest
- New Initialize and Import a new database and user!
- make sure new_db.spl is in the local directory.
mysql -uroot -p
mysql> create database new_db;
mysql> use new_db;
mysql> source new_db.sql;
mysql> use mysql;
mysql> SELECT * FROM user;
mysql> GRANT SELECT, INSERT, DELETE, UPDATE
-> ON new_db.* TO db_user@localhost
-> IDENTIFIED BY 'some_pass' WITH GRANT OPTION;
Search Enhancements
per [2] In includes/SpecialSearch.php there is a function showResults( $term ) which formats and outputs all the search results from a query, near the top add:
$wgOut->addHTML( wfMsg( 'Googlesearch', $term ) ); # add $wgOut->addWikiText( wfMsg( 'searchresulttext' ) );# above this
- MediaWiki:Googlesearch fix $3 and cleanup?
- MediaWiki:Nogomatch remove prompt to create page?
- MediaWiki:Searchresulttext cleanup/clear
In LocalSettings.php
# $wgDisableTextSearch = true; # $wgSearchForwardUrl = 'http://www.google.com/search?q=$1'; # $wgSearchForwardUrl = 'http://www.google.com/search?q=site%3Adigipen.edu+%22$1'; $wgNamespacesToBeSearchedDefault = array( -1 => 0, # Default setting 0 => 1, # Main 1 => 0, # Main talk 2 => 0, # User 3 => 0, # User talk 4 => 1, # SiteName 5 => 0, # SiteName talk 6 => 1, # Image 7 => 0, # Image talk 8 => 0, # MediaWiki 9 => 0, # MediaWiki talk 10 => 1, # Template 11 => 0, # Template talk 12 => 0, # Help 13 => 0, # Help talk 14 => 1, # Category 15 => 0); # Category talk
No longer used: Added to skins/DPSkin31.php at about line 407
// Begin New Portions to search more namespaces $s .= "<input type=\"hidden\" value=\"1\" name=\"ns0\">"; // Main //$s .= "<input type=\"hidden\" value=\"1\" name=\"ns1\">"; // Talk $s .= "<input type='hidden' name=\"searchx\" value=\"" . htmlspecialchars( wfMs( "Go" ) ) . "\" />";
Also change this
. "  <input type='submit' name=\"fulltext\" value=\"" . htmlspecialchars( wfMsg( "Go" ) ) . "\" /></form>";
To this
. "  <input type='submit' name=\"searchx\" value=\"" . htmlspecialchars( wfMsg( "Go" ) ) . "\" /></form>";
LocalSettings.php
<?php
# This file was automatically generated by the MediaWiki installer.
# If you make manual changes, please keep track in case you need to
# recreate them later.
$IP = "/SomePath";
ini_set( "include_path", ".:$IP:$IP/includes:$IP/languages" );
require_once( "includes/DefaultSettings.php" );
# If PHP's memory limit is very low, some operations may fail.
ini_set( 'memory_limit', '80M' );
if ( $wgCommandLineMode ) {
if ( isset( $_SERVER ) && array_key_exists( 'REQUEST_METHOD', $_SERVER ) ) {
die( "This script must be run from the command line\n" );
}
} elseif ( empty( $wgNoOutputBuffer ) ) {
## Compress output if the browser supports it
if( !ini_get( 'zlib.output_compression' ) ) @ob_start( 'ob_gzhandler' );
}
$wgSitename = "www2.digipen.edu";
$wgScriptPath = "";
$wgScript = "$wgScriptPath/index.php";
$wgRedirectScript = "$wgScriptPath/redirect.php";
## If using PHP as a CGI module, use the ugly URLs
#$wgArticlePath = "$wgScript/$1";
# $wgArticlePath = "$wgScript?title=$1";
$wgArticlePath = "/main/$1";
$wgStylePath = "$wgScriptPath/skins";
$wgStyleDirectory = "$IP/skins";
$wgLogo = "$wgStylePath/common/images/dpwiki.png";
$wgUploadPath = "$wgScriptPath/images";
$wgUploadDirectory = "$IP/images";
$wgEnableEmail = true;
$wgEnableUserEmail = true;
$wgEmergencyContact = "it-at-digipen123.edu";
$wgPasswordSender = "it-at-digipen123.edu";
## For a detailed description of the following switches see
## http://meta.wikimedia.org/Enotif and http://meta.wikimedia.org/Eauthent
## There are many more options for fine tuning available see
## /includes/DefaultSettings.php
## UPO means: this is also a user preference option
include('extensions/Flash.php');
$wgEnotifUserTalk = true; # UPO
$wgEnotifWatchlist = true; # UPO
$wgEmailAuthentication = true;
$wgDBserver = "localhost";
$wgDBname = "som_dbname";
$wgDBuser = "some_user";
$wgDBpassword = "some_pass";
$wgDBprefix = "prefix_";
# If you're on MySQL 3.x, this next line must be FALSE:
$wgDBmysql4 = true;
# Experimental charset support for MySQL 4.1/5.0.
$wgDBmysql5 = false;
## Shared memory settings
$wgMainCacheType = CACHE_NONE;
$wgMemCachedServers = array();
## To enable image uploads, make sure the 'images' directory
## is writable, then uncomment this:
$wgEnableUploads = true;
$wgUseImageResize = true;
$wgUseImageMagick = true;
$wgImageMagickConvertCommand = "/usr/bin/convert";
$wgMimeDetectorCommand= "file -bi"; # use external mime detector (linux)
$wgFileExtensions = array( 'png', 'jpg', 'jpeg', 'ogg', 'doc', 'xls', 'ppt', 'pdf', 'wmv', 'avi', 'mov', 'swf' );
$wgVerifyMimeType = false;
#$wgUseCopyrightUpload = true;
#$wgCheckFileExtensions = false;
#$wgStrictFileExtensions = false;
# Upload error
# Warning: Wrong parameter count for print_r() in /var/www/html/wiki/includes/Exif.php on line 528
## If you want to use image uploads under safe mode,
## create the directories images/archive, images/thumb and
## images/temp, and make them all writable. Then uncomment
## this, if it's not already uncommented:
# $wgHashedUploadDirectory = false;
## If you have the appropriate support software installed
## you can enable inline LaTeX equations:
# $wgUseTeX = true;
$wgMathPath = "{$wgUploadPath}/math";
$wgMathDirectory = "{$wgUploadDirectory}/math";
$wgTmpDirectory = "{$wgUploadDirectory}/tmp";
$wgLocalInterwiki = $wgSitename;
$wgLanguageCode = "en";
$wgProxyKey = "some_key_string";
## Default skin: you can change the default skin. Use the internal symbolic
## names, ie 'standard', 'nostalgia', 'cologneblue', 'monobook':
# $wgDefaultSkin = 'monobook';
$wgDefaultSkin = 'dpskin31';
## For attaching licensing metadata to pages, and displaying an
## appropriate copyright notice / icon. GNU Free Documentation
## License and Creative Commons licenses are supported so far.
# $wgEnableCreativeCommonsRdf = true;
$wgRightsPage = ""; # Set to the title of a wiki page that describes your license/copyright
$wgRightsUrl = "";
$wgRightsText = "";
$wgRightsIcon = "";
# $wgRightsCode = ""; # Not yet used
$wgDiff3 = "/usr/bin/diff3";
# Custom Settings http://meta.wikimedia.org/wiki/Preventing_Access
# This disables user registration, admins can still register users.
$wgWhitelistAccount = array ( "user" => 0, "sysop" => 1, "developer" => 1 );
#
# This disables anonymous edits
#
# Permission keys given to users in each group.
# All users are implicitly in the '*' group including anonymous visitors;
# logged-in users are all implicitly in the 'user' group. These will be
# combined with the permissions of all groups that a given user is listed
# in in the user_groups table.
# This replaces wgWhitelistAccount and wgWhitelistEdit
# The following line should be commented, otherwise these settings will
# throw away the settings on DefaultSettings.php (you probably don't want this).
# With this line commented you will only overwrite the settings you explicitly
# define here (that's what you probably want).
#$wgGroupPermissions = array(); # SEE THIS IN includes/DefaultSettings.php
$wgGroupPermissions['*' ]['createaccount'] = false;
$wgGroupPermissions['*' ]['read'] = true;
$wgGroupPermissions['*' ]['edit'] = false;
#
# Make the site non-readable
# Pages anonymous (not-logged-in) users may see
# $wgWhitelistRead = array ("Main Page", "Special:Userlogin", "Wikipedia:Help");
# $wgGroupPermissions['*' ]['read'] = false;
# $wgBlacklistRead = array ("User:someuser", "User:otheruser"); # This does nothing.
#
# To prevent a special page from being listed at Special:Specialpages,
# edit SpecialPage.php and change the relevant entry to be an instance of
# UnlistedSpecialPage instead of SpecialPage.
$wgShowIPinHeader = false;
# Don't show Categories for anonymous users
# $wgUseCategoryMagic = false;
# This will cache static pages for non-logged-in users to reduce
# $wgUseFileCache = true;
# Use article validation feature; turned off by default
#$wgUseValidation = true;
#$wgValidationForAnons = true ;
# $wgAuth = null;
# $wgSearchForwardUrl = 'http://www.google.com/search?q=$1';
# Array of disabled article actions, e.g. view, edit, dublincore, delete, etc.
# $wgDisabledActions = array();
?>
non Readable
LocalSettings.php
# Custom Settings http://meta.wikimedia.org/wiki/Preventing_Access # This disables user registration, admins can still register users. # LDAP enabled sites don't need user creation at all? $wgWhitelistAccount = array ( "user" => 0, "sysop" => 1, "developer" => 1 ); $wgGroupPermissions['*' ]['createaccount'] = false; $wgGroupPermissions['sysop' ]['createaccount'] = true; $wgGroupPermissions['bureaucrat']['createaccount'] = true; # Make the entire site non-readable $wgGroupPermissions['*' ]['read'] = false; # Pages anonymous (not-logged-in) users may read $wgWhitelistRead = array ("Main Page", "Special:Userlogin", "Help:Contents"); # $wgBlacklistRead = array ("User:WikiAdmin", "Foo"); # No "Black" lists. # Permission keys given to users in each group. # All users are implicitly in the '*' group including anonymous visitors; # logged-in users are all implicitly in the 'user' group. These will be # combined with the permissions of all groups that a given user is listed # in in the user_groups table. # This replaces wgWhitelistAccount and wgWhitelistEdit # The following line should be commented, otherwise these settings will # throw away the settings on DefaultSettings.php (you probably don't want this). # With this line commented you will only overwrite the settings you explicitly # define here (that's what you probably want). #$wgGroupPermissions = array(); # SEE THIS IN includes/DefaultSettings.php #$wgGroupPermissions['*' ]['read'] = false; #$wgGroupPermissions['user' ]['read'] = true; #$wgGroupPermissions['clients']['read'] = true; #$wgGroupPermissions['authors']['read'] = true; #$wgGroupPermissions['sysop' ]['read'] = true; $wgGroupPermissions['*' ]['edit'] = false; $wgGroupPermissions['user' ]['edit'] = false; $wgGroupPermissions['clients']['edit'] = false; $wgGroupPermissions['authors']['edit'] = true; $wgGroupPermissions['sysop' ]['edit'] = true; $wgGroupPermissions['user' ]['upload'] = false; $wgGroupPermissions['clients']['upload'] = true; $wgGroupPermissions['authors']['upload'] = true; $wgGroupPermissions['sysop' ]['upload'] = true; $wgGroupPermissions['user' ]['move'] = false; $wgGroupPermissions['sysop']['move'] = true;
LDAP auth
- http://meta.wikimedia.org/wiki/LDAP_Authentication
- http://meta.wikimedia.org/wiki/LDAP_Authentication_Configuration_Examples
- http://meta.wikimedia.org/wiki/Auto_Login_via_REMOTE_USER
In LocalSettings.php
# LDAP - NonADD Settings require_once( 'extensions/LdapAuthentication.php' ); $wgAuth = new LdapAuthenticationPlugin(); $wgLDAPDomainNames = array( "DigiPen" ); #$wgLDAPServerNames = array( "DigiPen"=>"1.2.3.4 1.2.3.5 1.2.3.6" ); $wgLDAPServerNames = array( "DigiPen"=>"1.2.3.4" ); # Choose who can login, Everyone, single branch, multiple domain/branches # Anyone with a valid account can login #$wgLDAPBaseDNs = array( "DigiPen"=>"dc=digipen,dc=edu" ); #$wgLDAPSearchAttributes = array( "DigiPen"=>"uid" ); # Only Students can login #$wgLDAPSearchStrings = array( "DigiPen"=>"uid=USER-NAME,ou=users,ou=students,dc=digipen,dc=edu"); # Only Staff can login #$wgLDAPSearchStrings = array( "DigiPen"=>"uid=USER-NAME,ou=users,ou=staff,dc=digipen,dc=edu"); # if multiple "Domains" are defined... #$wgLDAPSearchStrings = array( #"DigiPen_Students"=>"uid=USER-NAME,ou=users,ou=students,dc=digipen,dc=edu", #"DigiPen_Staff"=>"uid=USER-NAME,ou=users,ou=staff,dc=digipen,dc=edu"); # Need to change search in LdapPlugin from "members" to "memberUid", still doesn't work yet #$wgLDAPGroupDN = "cn=staff,ou=groups,dc=digipen,dc=edu"; #$wgLDAPGroupDN = "cn=pro,ou=webservices,ou=groups,dc=digipen,dc=edu"; #$wgLDAPGroupDN = "cn=web,ou=webservices,ou=groups,dc=digipen,dc=edu"; # requires changes in LdapPlugin #$wgLDAPRequireUser = array( "DigiPen"=>"userabc,userxyz" ); $wgLDAPUseSSL = true; $wgLDAPUseLocal = false; $wgLDAPAddLDAPUsers = false; $wgLDAPUpdateLDAP = false; $wgLDAPMailPassword = false; $wgLDAPRetrievePrefs = false; $wgMinimalPasswordLength = 1; # Case Sensetive user names fix, prevents multiple UserName creation due to case. # This will causes the local "WikiAdmin" account to no longer function #In "includes/SpecialUserlogin.php", in function "LoginForm", change: #$this->mName = $request->getText( 'wpName' ); # To: #$this->mName = strtolower( $request->getText( 'wpName' ) );