From f80583b4f3284750ac269c072d89b70159d338c0 Mon Sep 17 00:00:00 2001 From: Tom Gilder Date: Thu, 6 Oct 2005 13:05:33 +0000 Subject: [PATCH] Many improvements: better HTML (validates), more accessible, looks nicer, easier to use, better error messages... what more could you ask for? --- config/index.php | 299 ++++++++++++++++++++++++++--------------------- 1 file changed, 165 insertions(+), 134 deletions(-) diff --git a/config/index.php b/config/index.php index d9da0f7136..ff790ebf1b 100644 --- a/config/index.php +++ b/config/index.php @@ -30,43 +30,79 @@ header( "Content-type: text/html; charset=utf-8" ); MediaWiki installation @@ -376,7 +412,7 @@ print "
  • Script URI path: " . htmlspecialchars( $conf->ScriptPath ) . "DBprefix = importPost( "DBprefix" ); $conf->RootPW = importPost( "RootPW" ); $conf->LanguageCode = importPost( "LanguageCode", "en" ); - $conf->SysopName = importPost( "SysopName", "WikiSysop" ); + $conf->SysopName = importPost( "SysopName", "WikiAdmin" ); $conf->SysopPass = importPost( "SysopPass" ); $conf->SysopPass2 = importPost( "SysopPass2" ); @@ -716,7 +752,7 @@ if( count( $errs ) ) { /* Display options form */ if( $conf->posted ) { - echo "

    Something's not quite right yet; make sure everything below is filled out correctly.

    \n"; + echo "

    Something's not quite right yet; make sure everything below is filled out correctly.

    \n"; } ?> @@ -725,34 +761,34 @@ if( count( $errs ) ) {

    Site config

    -
    -
    +
    +
    -
    -
    + +

    Your site name should be a relatively short word. It'll appear as the namespace name for 'meta' pages as well as throughout the user interface. Good site names are things like "Wikipedia" and "OpenFacts"; avoid punctuation, which may cause problems. -

    +

    -
    +
    -
    -
    + +

    This will be used as the return address for password reminders and may be displayed in some error conditions so visitors can get in touch with you. It is also be used as the default sender address of e-mail notifications (enotifs). -

    +

    -
    - +
    + -
    -
    + +

    You may select the language for the user interface of the wiki... Some localizations are less complete than others. Unicode (UTF-8 encoding) is used for all localizations. -

    +

    -
    - -
    Select one:
    +
    +
    • @@ -783,8 +818,8 @@ if( count( $errs ) ) { $exit = urlencode( "$wgServer{$conf->ScriptPath}/config/index.php?License=cc&RightsUrl=[license_url]&RightsText=[license_name]&RightsCode=[license_code]&RightsIcon=[license_button]" ); $icon = urlencode( "$wgServer$wgUploadPath/wiki.png" ); $ccApp = htmlspecialchars( "http://creativecommons.org/license/?partner=$partner&exit_url=$exit&partner_icon_url=$icon" ); - print "choose"; - ?> (link will wipe out any other data in this form!) + print "choose"; + ?> License == "cc" ) { ?>
      • RightsIcon ) . "\" alt='icon' />", "hidden" ); ?>
      • @@ -795,34 +830,33 @@ if( count( $errs ) ) {
      -
    -
    + +

    MediaWiki can include a basic license notice, icon, and machine-readable copyright metadata if your wiki's content is to be licensed under the GNU FDL or a Creative Commons license. If you're not sure, leave it at "none". -

    +

    -
    - -
    -
    +
    + +
    +
    -
    -
    + +
    -
    -
    - A sysop user account can lock or delete pages, block problematic IP + +

    + An admin user account can lock or delete pages, block problematic IP addresses from editing, and other maintenance tasks. If creating a new - wiki database, a sysop account will be created with the given name + wiki database, an admin account will be created with the given name and password. -

    +

    -
    - -
    Select one:
    +
    +
    • @@ -841,55 +875,50 @@ if( count( $errs ) ) { } ?>
    • -
    -
    -
    +
    + +

    Using a shared memory system such as Turck MMCache, eAccelerator, or Memcached will speed up MediaWiki significantly. Memcached is the best solution but needs to be installed. Specify the server addresses and ports in a comma-separted list. Only use Turck shared memory if the wiki will be running on a single Apache server. -

    +

    +

    E-mail, e-mail notification and authentication setup

    -
    -
    - -
    Select one:
    - +
    +
    +
    -
    -
    + +

    Use this to disable all e-mail functions (send a password reminder, user-to-user e-mail and e-mail notification), if sending e-mails on your server doesn't work. -

    -
    - -
    Select one:
    - +

    +
    +
    -
    -
    + +

    Use this to disable only the user-to-user e-mail function (EmailUser). -

    -
    - -
    Select one:
    - +

    +
    +
    -
    -
    + +

    E-mail notification sends a notification e-mail to a user, when the user_talk page is changed and/or when watch-listed pages are changed, depending on the above settings. @@ -900,18 +929,16 @@ if( count( $errs ) ) { The user options are not shown on the preference page, if e-mail notification is disabled.

    There are additional options for fine tuning in /includes/DefaultSettings.php .

    -
    - -
    - -
    Select one:
    + +
    +
    -
    -
    + +

    E-mail address authentication uses a scheme to authenticate e-mail addresses of the users. The user who initially enters or changes his/her stored e-mail address gets a link with a token mailed to that address. The stored e-mail address is authenticated at the moment the user comes back to the wiki via the link.

    @@ -920,83 +947,80 @@ if( count( $errs ) ) {

    If the option is enabled, only authenticated e-mail addresses can receive EmailUser mails and/or e-mail notification mails.

    -
    + -
    +

    Database config

    -
    -
    - -
    Select the database server software:
    +
    +
    +
      - +
    • +
    -
    + -
    -
    +
    +

    If your database server isn't on your web server, enter the name or IP address here. MySQL only. -

    +

    -
    -
    +
    +
    If using Oracle, set this to your connection identifier. -
    -
    -
    -
    -
    + +
    +
    +
    +

    If you only have a single user account and database available, enter those here. If you have database root access (see below) you can specify new accounts/databases to be created. -

    +

    -
    -
    +
    +

    If you need to share one database between multiple wikis, or MediaWiki and another web application, you may choose to add a prefix to all the table names to avoid conflicts.

    Avoid exotic characters; something like mw_ is good.

    -
    + -
    +
    -
    -
    + +

    You will only need this if the database and/or user account above don't already exist. Do not type in your machine's root password! MySQL has its own "root" user with a separate password. (It might even be blank, depending on your configuration.) -

    +

    -
    +
    - -
    -
    + + + @@ -1250,7 +1274,10 @@ function importRequest( $name, $default = "" ) { return importVar( $_REQUEST, $name, $default ); } -function aField( &$conf, $field, $text, $type = "", $value = "" ) { +$radioCount = 0; + +function aField( &$conf, $field, $text, $type = "text", $value = "" ) { + global $radioCount; if( $type != "" ) { $xtype = "type=\"$type\""; } else { @@ -1259,6 +1286,10 @@ function aField( &$conf, $field, $text, $type = "", $value = "" ) { if(!(isset($id)) or ($id == "") ) $id = $field; $nolabel = ($type == "radio") || ($type == "hidden"); + + if ($type == 'radio') + $id .= $radioCount++; + if( $nolabel ) { echo "\t\t