Commit graph

34 commits

Author SHA1 Message Date
Tim Starling
4f189276ae fixing broken search links e.g. from prev/next links on results page 2004-06-26 12:56:44 +00:00
Antoine Musso
16a74059bd recommiting specialpages loading fix as the BoardVote extension as now been fixed 2004-06-12 01:31:00 +00:00
Brion Vibber
e96217fc1c Undo change that stopped Wikipedia from running at all 2004-06-11 23:29:56 +00:00
Antoine Musso
cd43f3b122 removing print_r *hides 2004-06-11 21:14:51 +00:00
Antoine Musso
82b207df94 do not instant Special* objects if user is not requesting a special page (save memory / cpu time) 2004-06-11 21:13:51 +00:00
Tim Starling
c1f1a87ab6 update cur_touched on action=purge 2004-06-06 14:05:51 +00:00
Brion Vibber
87d342d844 Fix bad title detection again; was dying with error on whitelist check 2004-05-30 06:44:47 +00:00
Brion Vibber
bce224d0db Fix preg_quote usage in interwiki loop detection 2004-05-29 01:24:33 +00:00
Tim Starling
e3676a470c Introducing special page modular extensions, making the board vote special page the first of these.
* Moving common special page handling to SpecialPage.php
* Special page lists in the language classes are obsolete, replaced by the list in SpecialPage.php
* Special:Specialpages uses the standard page titles wfMsg(pagename) instead of the description list previously contained in the $wgSpecialPagesEn arrays
* Ability to add custom messages to the MessageCache. Overridable by the MediaWiki namespace.
* Moving board vote functionality from includes/SpecialBoardvote.php to extensions/BoardVote.php
2004-05-15 03:36:39 +00:00
Erik Moeller
472272dc61 New feature:
Automatic or manual collapsing and expanding of long pages.
Pages can be collapsed automatically according to a size threshold
set in the user preferences. Pages can be collapsed manually by clicking
the "Collapse" link in the TOC.

When a page is collapsed, only the intro & TOC are displayed. The
individual TOC lines link to section views, which can be individually edited
(classic section editing).

Section editing/viewing behavior has also been improved. When a section
with subsections is viewed or edited, all subsections are also loaded.

Known issues:
- After saving a section, we return to the full article view
rather than the section view, even if we previously were in section view
mode.
- Should work with Standard and Monobook, not tested with Cologne Blue yet.
- In Monobook, no backlink to the mother article is shown during section
viewing (Gabriel, can you fix that?)
2004-05-12 13:26:36 +00:00
Brion Vibber
34ceac3add Whitelist and diff fixes:
* Enforce whitelist on oldid and diff specifiers (bug 950911)
* Show the titles given for oldid and diff if they differ (UI change related to bug 622636)
* Use canonical text form in $wgWhitelistRead
2004-05-11 09:47:41 +00:00
Brion Vibber
762b8e9b47 Allow installing and running the wiki on a server where ini_set has been
disabled via disable_functions in php.ini (bug #928168)

The PHPTal skin doesn't function unless the PEAR bits are in include_path,
so it's disabled if ini_set can't be used. If the files are manually placed
or a real PEAR installation is available with the right stuff, one can
use $wgUsePHPTal = true;

There are likely other things that need to be taken into account for
restricted environments. Maintenance scripts haven't been tweaked for
such an environment yet either.
2004-05-09 10:37:00 +00:00
Tim Starling
8f22cb45b1 include_once -> require_once 2004-05-07 13:43:10 +00:00
Tim Starling
52def2f997 Interwiki redirects using prefixes in the URL 2004-05-04 12:37:29 +00:00
Gabriel Wicke
df106e2f49 New, simple method to retrieve the plain source of an article
Syntax:
* action=raw
* ctype=text/plain (defaults to text/plain, used in the header)
* charset=utf-8 (defaults to wgInputEncoding, used in header)
* oldid=int (retrieves old version if set)
2004-04-28 17:38:48 +00:00
Brion Vibber
37cf644140 Fix for old-style search URLs to force the page to behave as search 2004-04-24 06:39:59 +00:00
Brion Vibber
93b09379fb Add experimental MathML output option for math (only works with some
browsers and requires use of an XML content type; try setting
$wgMimeType = "application/xhtml+xml" and use Mozilla).
Rearranged a couple things in prefs.
Did some refactoring in Math.php to remove some duplicated code and
figure out what is going on.
2004-04-22 08:51:04 +00:00
Brion Vibber
e77f54f65b Un-break large number of actions. Timwi, please read http://www.php.net/switch 2004-04-09 10:46:28 +00:00
Arne Heizmann
444b3b8b84 Make code infinitely more readable and understandable by seizing use of a pointless,
confusing and error-prone feature of PHP.
2004-04-09 10:29:54 +00:00
Brion Vibber
33821336ba Whitespace & coding standards adjustments to Evan's last commits.
Metadata.php seems to be missing, so the new code doesn't work yet.
2004-04-04 22:33:11 +00:00
Evan Prodromou
22f8c4ce37 Added code to implement Dublin Core and Creative Commons RDF metadata.
If these features are turned on (with global flags), a metadata link tag is
provided to the appropriate action ('dublincore' or 'creativecommons'). When
the wiki script receives these actions, it creates RDF files on the fly.

Also includes two valuable general functions: one to show an HTTP error
(used when the flags are turned off), and one to do content negotiation
(used to determine the MIME type for RDF files).

A helper function is also added to page output to display metadata links.
2004-04-04 21:58:05 +00:00
Brion Vibber
84027db7f2 Installation, compatibility, security fixlets:
* Detect use of PHP as CGI and disable index.php/Title URLs
* Try to auto-create math tmp & output directories if not present
* Disable Asksql in default install ($wgAllowSysopQueries)

Added skin names to LanguageEo
2004-03-26 16:47:12 +00:00
Gabriel Wicke
d3831b1dd3 added manual purge action 2004-03-13 16:09:00 +00:00
Gabriel Wicke
35a86615bf calls to setSquidMaxage for cacheable pages 2004-03-13 13:43:22 +00:00
Brion Vibber
014093acc4 More globals and uninitialized variables fixes. Added WebRequest ($wgRequest)
object to encapsulate the handling of get/post variables:

The following grab something out of $_REQUEST. The first parameter is the
variable name and is required. The second is an optional default value:

  $wgRequest->getVal() - any type, returns NULL if no default given
  $wgRequest->getInt() - forced integer, 0 default
  $wgRequest->getText() - runs through $wgLang->recodeInput()
  $wgRequest->getBool() - return true/false
  $wgRequest->getCheck() - returns true if the var is set, even if to ""

$wgRequest strips slashes at initialization if necessary.

Also in this fine object:
  $wgRequest->wasPosted() - returns false if this wasn't a real form post,
    so we can protect against faked submissions in get urls.

There's still plenty of work to do, not everything uses the new functions
yet. To test the strict mode, do define('DEBUG_GLOBALS', 1);
2004-03-08 09:09:35 +00:00
Brion Vibber
51f738ea9a More unitialized variable cleanup && 'pure' register_globals cleanup...
Added wfDebugDieBacktrace() function to help in pinpointing problems by
showing a function call backtrace along with a friendly die message.
2004-03-08 02:50:04 +00:00
Brion Vibber
9e53bfc81c Imported the register_globals hack from REL1_2. Also starting work on
elimination of the use of import_request_variables (which gives us all
the insecurity of register_globals). Uncomment the define of DEBUG_GLOBALS
in index.php to turn on extra error reporting and trace down use of
uninitialized variables and nassssty globals.

Also rearranged the magic_quotes fixing, may not yet cover everything...
2004-03-08 01:51:32 +00:00
Brion Vibber
8d3f9999c3 Use PATH_INFO for prettier default URLs: index.php/Foo instead of index.php?title=Foo 2004-03-06 21:35:07 +00:00
Tim Starling
840dee3ad4 * Fixed magic quotes in $_REQUEST, in Setup.php
* Converted many instances of globals from the query to $_REQUEST
* Renamed near-useless Title::getURL() to Title::getPartialURL()
* Created new Title::getURL(), to replace wfLocalUrl, wfLocalUrlE, wfFullUrl and wfFullUrlE. Replaced most instances throughout the code
* In Parser.php, generalised stripping of <nowiki>, <pre> and <math> to allow more general use such as nesting
* Moved body of Article::preSaveTransform to Parser.php
* Put lots of comments in Title.php
2004-03-06 01:49:16 +00:00
Nicholas Pisarro, Jr
74a1c21d60 Implemented '$wgWhitelistRead'.
$wgWhitelistRead is now defined to be an optional array
of namespace:pages a user may see unless they login.

For example:
$wgWhitelistRead = array ( ":Main_Page", "Special:Userlogin", "Wikipedia:Help" );

will restrict an anonymous user to only those pages. They are
alerted that they must login, if the try to go to another page.

If 'false', the default, the anonymous user may see all pages,
except Sysop pages, of course.
2004-03-05 13:19:19 +00:00
Gabriel Wicke
4364a77058 allow caching for permanent redirects 2004-03-01 22:16:39 +00:00
Brion Vibber
d11bdf29ca Experimental in-place installer.
Doesn't yet do any database setup, but does produce a LocalSettings.php
that can successfully operate the wiki in the distribution directory
structure. Note that the maintenance scripts may not all be fully armored
against web access, and aren't set up to be run from the web by an actual
administrator either.
2004-03-01 12:59:45 +00:00
Brion Vibber
7f0854126d Double-check at runtime that sitename is set. Paranoia is good... if we don't do this, manual installs that are sloppy may introduce subtle bugs. 2004-02-29 08:06:49 +00:00
Erik Moeller
1dea93f758 using index.php and redirect.php instead of wiki.phtml and redirect.phtml
keeping phtml stubs around for compatibility and CVS history
2004-02-28 03:04:02 +00:00