Commit graph

378 commits

Author SHA1 Message Date
Brion Vibber
07650eba1d * (bug 1228) Fix double-escaping on & sequences in [enclosed] URLs 2005-01-30 04:11:22 +00:00
Jens Frank
ea9b9f176d BUG#1217 Image within an image caption broke rendering 2005-01-22 23:11:17 +00:00
Jens Frank
0957c04743 BUG#1131 Fix headings containing interwiki links 2005-01-22 09:34:56 +00:00
Jens Frank
24d8299089 BUG#925 Fix canonized_headline for e.g. <math> 2005-01-22 09:13:02 +00:00
Brion Vibber
7710788d3a * Remove unnecessary initialization and double-caching of parser variables
This saves a couple milliseconds; since the variables are internally cached there's no benefit to running every variable when we're often just going to use one or two (Sitename in messages for instance)
2005-01-18 11:52:06 +00:00
Tom Gilder
2d71cb3080 Generate expanded URLs for printing on the client, not server (using CSS, or JS for IE/win) (bug 642) 2005-01-15 23:56:26 +00:00
Tom Gilder
221156150e Complete TOC recode: proper HTML list; CSS for layout; JS recode; hidden TOC stays hidden across different pages; never show TOC if no headings; more opportunity to style TOC 2005-01-15 23:21:52 +00:00
Jens Frank
50ebb1e045 BUG#1317 - External links in image caption not working
Changed regexp to allow single ] inside of an image's alternative text
2005-01-13 09:13:22 +00:00
Antoine Musso
f2baa43923 Implement #1206
Patch by M7 "computerville (at) gmail (tod) com"
FORPORT from 1_4
2005-01-11 01:30:13 +00:00
Brion Vibber
c0d99e5c3e * (bug 1186) news: in the middle of a word 2005-01-08 03:03:10 +00:00
Jens Frank
922609f104 BUG#1269 - Fix section editing for articles with verbatim <h[1-6]> sections
There's a space added before the closing bracket during processing of HTML tags.
Changed the regexp to also match </h1 >
2005-01-06 00:13:49 +00:00
Jens Frank
eb39f13f04 BUG#32 External links had a whitespace after the link when tidy was used 2005-01-02 22:09:54 +00:00
Brion Vibber
8e4250ae57 * Add the dreaded <span> to the HTML whitelist 2004-12-23 14:04:11 +00:00
Brion Vibber
4f323f50e1 Fancy sig option for the very nice folks who just aren't content with a user page link and will produce ugly invalid code and then complain about it. merge from REL1_4 2004-12-23 08:40:51 +00:00
Brion Vibber
bbfaa459f9 monkeys! monkeys bouncing around my BRAIN 2004-12-23 07:47:17 +00:00
Brion Vibber
64ac6b8e77 Merge SCHEMA_WORK into HEAD. Lots of changes, some things are probably broken:
* Page moves/overwrites are a little iffy
* Compression might not be working right
* Profit!
2004-12-19 08:00:50 +00:00
Brion Vibber
d319dbe869 Split link generation, table of contents, and image functions from the
Skin class to a separate class, in preparation for thinning and refactoring.
Most users of these functions don't need the _Skin_, which generates the
user interface, and they clutter up the code with unrelated stuff.
2004-12-18 06:29:23 +00:00
Brion Vibber
3150abb758 * Gracefully ignore non-legal titles in a <gallery> 2004-12-15 09:07:21 +00:00
Brion Vibber
9a2a36ce5e * Defer message cache initialization, shaving a few ms off file cache hits 2004-12-09 05:51:20 +00:00
Brion Vibber
e6bb9de12b Merge image gallery fixlets from 1.4 2004-12-09 02:13:00 +00:00
Shane King
94ba835da9 Added support for .. style backlinks within subpages. See bug #981
for full details.
2004-12-07 01:23:32 +00:00
Brion Vibber
c6d4472efb Allowed HTML list has been frozen for some time, and we're trying not to add new tags. 2004-11-30 08:00:17 +00:00
Antoine Musso
229ac8759b Fix bug http://bugzilla.wikimedia.org/show_bug.cgi?id=671
* allow <abbr> and <acronym>
2004-11-30 05:22:39 +00:00
Evan Prodromou
4b42f18b66 Removed CVS keywords from files, to make merging between branches
easier. Interpolated keywords cause lots of conflicts and headaches at
merge time for older (<1.12.x) CVS versions.
2004-11-29 18:25:30 +00:00
Brion Vibber
b7557bf809 Profiling points 2004-11-28 04:05:05 +00:00
Brion Vibber
d66f60ed43 Loop invariant optimization: skip further checks for subpages on namespaces where subpages aren't allowed. Saves ~20ms on [[List of Royal Navy ship names]] on my test rig. 2004-11-28 03:29:50 +00:00
Brion Vibber
ffe8c4594e Avoid undefined string index notice on {{}} 2004-11-28 02:46:52 +00:00
Brion Vibber
f75240210c Tell regexp parser to use extra analysis on external link regexp;
this saves about 10ms on [[Zuiderzee Works]] on my test rig.
2004-11-26 12:10:24 +00:00
Brion Vibber
7a4c860acc Tell regexp engine to do extra analysis on doBlockLevels() paragraph-level
HTML checking. This speeds up this part of the operation from about 30ms
to about 7ms in Zuiderzee_Works on my test rig.
2004-11-26 10:49:46 +00:00
Brion Vibber
e39dd4532c (bug 934) List each category on a page only once.
Dan Keshet's patch (http://bugzilla.wikipedia.org/attachment.cgi?id=134&action=view) plus an added version check on parser cache objects, to automatically discard cached objects using the incompatible older format.
2004-11-25 22:02:30 +00:00
Brion Vibber
5a8cf9de43 Profiling points etc 2004-11-23 07:41:07 +00:00
Brion Vibber
f8c3d4bfb4 Inner loop optimization: reverse order of conditions for language variant link check, so the condition short-circuits correctly and we can skip the expensive per-link lookup. 2004-11-22 10:05:11 +00:00
Brion Vibber
2376b2c6f1 Avoid asking for the day, month etc name messages and the total number of articles over and over. InitialiseVariables() gets called during message transformations, so this saves several milliseconds of startup time which can be a significant portion of execution time on ParserCache'd page views. 2004-11-21 14:07:24 +00:00
Jens Frank
5b8630e1bf Added magic PubMed-Link, links to PubMed DB can be set like RFC
or ISBN links, using PMID 15545900 magic link.

Some code beautifying.
2004-11-20 11:28:37 +00:00
Tim Starling
ac77eb5b2c Fixed bug causing interwiki links to disappear unless accompanied by an internal link 2004-11-13 14:24:42 +00:00
Jens Frank
a8369d40dd Moved <gallery> code to Parser, registering images in a gallery as link 2004-11-13 12:04:31 +00:00
Jens Frank
e34d357e9d New tag "<gallery>" to generate a table of image thumbnails 2004-11-13 10:53:46 +00:00
Erik Moeller
1c54b48e4a [[Wikinews:Bla]] should not be matched as a news:// URL type.
Change regex to require that URL_PROTOCOLS is at the beginning of a link
(e.g. [[news:bla]]) for it to match.

Note: This will break if someone decides to reverse the order of
replaceExternal and replaceInternal again.
2004-11-07 10:14:36 +00:00
Brion Vibber
35cd7657f5 Remove old commented-out section which has some literals that break my editor's syntax highlighting 2004-10-28 01:22:49 +00:00
Erik Moeller
d2f27cf300 restore old order of replaceInternal/replaceExternal, mask absolute URLs
left behind by [[Media:]] links to prevent them from being parsed twice.
2004-10-25 05:24:23 +00:00
Jens Frank
bbfc760c1f Rename fields of user_rights and user_groups table to tablename_columnname schema 2004-10-24 09:21:53 +00:00
Tim Starling
412eda0517 Correcting bugs due to double-prefixing table names. Removing obsolete Database member functions. Adding comments to Database.php 2004-10-24 07:10:33 +00:00
Zheng Zhu
2f305c082a forgot to move the comment 2004-10-23 13:00:33 +00:00
Brion Vibber
2e7cecdeb6 Remove $wgCurParser kludge 2004-10-23 07:10:37 +00:00
Erik Moeller
0d02b52702 Preliminary support for shared upload directory. This is primarily intended
for the Wikimedia Commons. If $wgUseSharedUploads is set, MediaWiki will try
to locate an image file in the shared upload directory if it is not found
locally. Thumbnails for shared images will also be generated in the
shared directory.

Note: I changed
                $text = $this->replaceInternalLinks ( $text );
                $text = $this->replaceExternalLinks( $text );
to
                $text = $this->replaceExternalLinks( $text );
                $text = $this->replaceInternalLinks ( $text );

in Parser.php. Otherwise [[Media:Bla.jpg]] to an absolute URL would be
incorrectly parsed as external links. The header of
replaceExternalLinks says:

        Note: we have to do external links before the internal ones

So the old order was not consistent with the documentation. I did some
tests and nothing seems to be broken, but I have some problems executing
parserTests.php so I couldn't test it systematically.
2004-10-21 05:04:14 +00:00
Zheng Zhu
ccf6536d52 Moving code that checks for valid link in another variant from Parser.php to Language.php 2004-10-21 02:47:51 +00:00
Zheng Zhu
b6093aad4e Added option wgDisableLangConversion to disable langauge variant conversion, mainly for debugging and testing purpose. 2004-10-19 18:02:44 +00:00
Zheng Zhu
7bb0a0b64b removed double conversion of linked text. 2004-10-19 17:44:00 +00:00
Brion Vibber
da056c312e (bug 737) only use the post-parse link placeholders within replaceInternalLinks().
The recent move of the replacement step from OutputPage into Parser completely
broke a crapload of special pages; this makes the links show again.
2004-10-19 07:30:56 +00:00
Wil Mahan
4bc5a37c98 Move replaceLinkHolders() from OutputPage to Parser, because
it needs to happen before unstripNoWiki() and before tidy.
This also makes the parser more self-contained, so there is
no need to create an OutputPage object for the parser
tester.

Call unstripNoWiki() before creating a Title object
for an internal link; this fixes <nowiki> inside of
a link target. Need to make sure this does not degrade
performance.
2004-10-15 17:39:10 +00:00