Daniel Kinzler
9d00a90a21
follow-up to r57278: cache all variables untill the next clearState()
2009-10-02 09:46:17 +00:00
Daniel Kinzler
f0b39b40d2
clear variable cache in clearState() as suggested by tim. fix odd values for long running imports; more vars could be cached now.
2009-10-02 09:09:18 +00:00
Andrew Garrett
1a42431b0f
Add signature prefetching logic to Parser, supports r56706.
2009-09-30 10:35:34 +00:00
Happy-melon
96e20213d4
Recommit r56688 (tracking categories for __INDEX__ and __NOINDEX__).
2009-09-28 17:55:00 +00:00
Roan Kattouw
62de3d1478
Add a {{STYLEPATH}} magic word; necessary for upcoming EditToolbar fix
2009-09-26 11:51:37 +00:00
Brion Vibber
0d1d984313
Revert broken rewrite of login system; totally broken.
...
* Login doesn't attach to session properly, so can't stay logged in!
* Password field shown in plaintext!
If it just DOESN'T WORK please keep it on a work branch, don't put it in trunk!
Reverted:
r56682
r56683
r56684
r56686
r56688
r56696
r56699
r56702
r56703
r56704
r56782
r56896
2009-09-26 00:49:32 +00:00
Happy-melon
a25885d336
(bug16979) Add tracking categories for __INDEX__ and __NOINDEX__.
2009-09-20 22:14:09 +00:00
Brion Vibber
63b39c9164
Revert r53832, r53897, r54145 "(bug 17988) Spaces before [[Category:]] links are no longer ignored" and followup
...
Causes entire page to go blank under some circumstances.
2009-09-17 00:57:10 +00:00
Andrew Garrett
41437106a9
Relax === check for blank signatures to ==, fixes bug 19261 (alternative solution to r54585)
2009-09-09 17:30:52 +00:00
Aryeh Gregor
d87f3188bc
Don't embed ?> in string literals
...
It messes up some syntax highlighters for some unknown reason.
2009-09-07 00:23:04 +00:00
Nephele
91716a9d7a
(bug 2257) Add a $frame parameter to recursiveTagParse so tag extensions can expand template parameters
2009-08-30 06:37:10 +00:00
Andrew Garrett
33f5a8983b
Revert r52983 for now, could cause unexpected syntax interactions, we want to investigate this before deploying it
2009-08-27 17:16:15 +00:00
Alexandre Emsenhuber
152638e907
* (bug 8143) Localised parser function names are now correctly case insensitive if they contain non-ASCII characters
...
Patch by Matěj Grabovský - http://bug-attachment.wikimedia.org/attachment.cgi?id=6406
2009-08-26 15:47:03 +00:00
Raimond Spekking
e1e2c80783
* (bug 20318) Distinct CSS classes for ISBN/RFC/PMID special links added
2009-08-20 09:13:29 +00:00
Tim Starling
831b6d2bf7
* Per my CR comments on r44560: merged FileCache into RepoGroup and fixed wfFindFile() global function bloat. Did not port unused functions such as the batch loading functions.
...
* Fixed the formal parameter bloat in the file finding functions by making wfFindFile(), RepoGroup::findFile() and FileRepo::findFile() take an associative array of options instead of a rapidly growing collection of formal parameters. Maintained backwards compatibility for the $time parameter, which was the only one used in an extension.
* Took the advice of the todo comment on FileRepo::findFiles() and implemented a calling convention for specifying times (and other options)
* Removed the file object cache from Parser, redundant with the RepoGroup file cache
* Deleted clueless and non-functional LocalRepo::findFiles(). Does not respect redirects, deletion bitfields, or anything else nuanced about FileRepo::findFile(). Does not have the same calling convention as FileRepo::findFiles().
2009-08-15 09:59:59 +00:00
Alexandre Emsenhuber
378e29e5df
Per Nikerabbit's comment on r53897 (i.e. fix for r53832, second attempt): changed "m" modifier to "D" so that $ really only matches the end of the string
2009-08-01 12:41:45 +00:00
Alexandre Emsenhuber
afe90f6ffc
Per Simetrical's comment on r53832: only trim if there're newlines
2009-07-28 20:16:17 +00:00
Alexandre Emsenhuber
d9944c772a
* (bug 17988) Spaces before [[Category:]] links are no longer ignored
...
* some code style fixes
2009-07-27 19:42:24 +00:00
Brion Vibber
43bf053fd0
* (bug 14080) Short notation links to subpages didn't work in edit summaries
...
Moved Parser::maybeDoSubpage guts to Linker to call from both locations.
Added some parser test cases.
Note that this might not behave exactly like the main parser in cases where the link text would get altered, but the links are functional. Yay!
2009-07-20 02:07:56 +00:00
Alex Z
95ef1b6fd6
(bug 19814) - Interwiki links from file links - [[File:Foo.jpg|link=de:Test]] - are no longer recorded in the pagelinks table
...
Also update Parser::makeImage() docs for the link option
2009-07-18 22:49:31 +00:00
Roan Kattouw
b18ec94952
* Fix typo in Linker.php
...
* Only call ParserOutput::setTOCHTML() if a TOC was really generated
2009-07-14 13:35:07 +00:00
Remember the dot
a70213071d
Removed repetition of URIs in the title attributes (tooltips) of external links. Web browsers typically display the target URIs of links in the status bar, making repeating the URIs in tooltips redundant. Some browsers, like Opera, can be configured to display the URIs in tooltips instead of the status bar without the web page having to supply title attributes at all.
...
As part of this process, I refactored some of Linker.php and removed an unused parameter from getExternalLinkAttributes.
2009-07-12 23:32:16 +00:00
Victor Vasiliev
9bc1e60cab
Add function-like tag hooks. They are tags, which content is not preprocessed. Those hooks has access to PPFrame and are parsed on preprocessing stage. They might be useful for built-in programming languages.
2009-07-11 13:03:35 +00:00
Andrew Garrett
9de04ff5b4
* Allow leading-> as syntax for quoting.
2009-07-09 15:17:56 +00:00
Remember the dot
05978d7cf3
Title attributes are now always blank on framed and thumbnailed images, and default to blank on inline images instead of defaulting to the image's filename. Additionally, the alt attribute now defaults to the filename on framed and thumbnailed images if no caption or alt attribute is specified.
...
I was unable to run the parser test suite ("MediaWiki internal error"), so the test suite may need to be updated to reflect these changes.
2009-07-03 05:13:58 +00:00
Roan Kattouw
82022f21bc
Core changes for NavigableTOC extension:
...
* Always generate the section tree, even when we're not generating a TOC
* Add Parser::mergeSectionTrees() to merge two section trees into one
* Add Linker::generateTOC() to generate the HTML for a TOC from a section tree, and add the section anchor to the section tree to facilitate this. This adds the ability to generate TOCs in extensions; haven't converted Parser.php to use it (yet?). As a side effect, this fixes API bug 18720
2009-06-25 11:05:22 +00:00
Roan Kattouw
7c199a872b
(bug 19323) Calls to recursiveTagParse() overwrite ParserOptions::$mSections, causing the real section tree to be overwritten in some cases
2009-06-21 12:52:24 +00:00
Roan Kattouw
ae130186e8
Core changes for NavigableTOC extension:
...
* Add TOC HTML to ParserOutput
* Add class tocsection-$section to <li> elements in the TOC representing sections in the current page (as opposed to transcluded sections)
2009-06-20 21:47:10 +00:00
Roan Kattouw
5097164dce
Add 'index', 'fromtitle', and 'byteoffset' fields to ParserOutput::getSections(). This makes these fields available through the API with action=parse&prop=sections . Also, the byte offset will be needed by the new NavigableTOC extension.
2009-06-20 18:25:30 +00:00
Andrew Garrett
046d986b16
Documentation I added while trying to figure out doBlockLevels, might be useful to others
2009-06-18 20:51:48 +00:00
Niklas Laxström
019a132ebf
Regression in r51797, anon signature links where prefixed with contributions/ because default value changed from '' to null
2009-06-15 15:17:40 +00:00
Siebrand Mazeland
38ca12aa82
* replace some use of deprecated makeKnownLinkObj() by link() in core
...
* use array type parameter instead of string to escapeLocalUrl(), getFullURL() and getFullUrl() for readability
* add FIXME in Parser.php and LogEventsList.php where I didn't know how to replace makeKnownLinkObj by link()
* return type for private method Skin::editUrlOptions() changed from string to array
* some code readability improvements
Linking this to r51559 for CodeReview as there is some discussion there, and these changes are very similar.
Todo: core special pages
2009-06-07 15:02:12 +00:00
Siebrand Mazeland
055fcbd7cb
* replace use of deprecated makeLinkObj() by link() in core
...
* add FIXME where makeLinkObj was used in documentation
2009-06-06 15:45:43 +00:00
Rotem Liss
b57bce94c5
Multiple whitespace in TOC anchors is now stripped, for consistency with the link from the edit comment.
2009-06-02 19:32:51 +00:00
Siebrand Mazeland
0d23260d81
(bug 19017) TOC level calculation error in an odd case. Patch by Brad Jorsch.
2009-06-01 16:39:18 +00:00
Shinjiman
21c11b8f40
* (bug 5755) Introduce {{CURRENTMONTH1}} and {{LOCALMONTH1}} to display the month number without the leading zero
...
* added {{CURRENTMONTH2}} and {{LOCALMONTH2}} as alias of {{CURRENTMONTH}} and {{LOCALMONTH}} for consistency with other magic words
2009-05-20 07:14:03 +00:00
Arash Boostani
28a9ea2b1c
Reverting the code that encloses article sections in their own div for the time being, because there are certain scenarios that break the document structure.
2009-05-19 15:12:05 +00:00
Arash Boostani
e1e727ec5d
Fixed a minor problem with $wgSectionContainers that was causing some divs to not be closed properly
2009-05-06 23:21:55 +00:00
Arash Boostani
127c44f4fc
Fixed problem with call to closeSectionContainers that contained references. Only the function definition needs to indicate that the input variable is a reference, not the function call.
2009-05-06 04:17:48 +00:00
Arash Boostani
f81f4c1fa6
Added an extension, called EditSectionHiliteLink, that highlights the appropriate section when the user mouses over the section edit links. Also, modified the Parser to enclose each section in a div if $wgSectionContainers is set.
2009-05-05 22:49:45 +00:00
Brion Vibber
eee6d975bd
Revert r49653 "Make the link regex non-greedy so that it is possible to add '|' to $wgLegalTitleChars and still be able to pipe
...
links."
Pipes would definitely not work in titles. The particular regex change here would for instance break image options if | were added to $wgLegalTitleChars.
2009-04-28 23:33:28 +00:00
Remember the dot
0d499494cd
Make the link regex non-greedy so that it is possible to add '|' to $wgLegalTitleChars and still be able to pipe
...
links. This change should have no effect on the default configuration, which does not include '|' in
$wgLegalTitleChars because including it still breaks other things.
2009-04-19 22:20:12 +00:00
Tim Starling
2e17030282
Move the circular reference check to *after* redirect resolution, to avoid infinite loops via redirects. Was causing sysadmin issues.
2009-04-05 15:01:25 +00:00
Aaron Schulz
41d6528eab
profiling fix
2009-04-05 01:10:52 +00:00
Alexandre Emsenhuber
82730b9de6
* (bug 18170) Fixed a PHP warning in Parser::preSaveTransform() in PHP 5.3: Parameter 2 was expected to be a reference but value given when $wgParser is unstubbed on that call
2009-04-02 19:16:24 +00:00
Arash Boostani
c32a1ef480
Fixed bug #11213 - [edit] section links in printable version interfere with cut-and-paste of article text
2009-03-18 23:27:48 +00:00
Chad Horohoe
56d4c64200
(bug 17897) Uninitialized string offset in <pre> tags. Patch by Luigi Corsaro. No parser test regressions.
2009-03-11 13:28:22 +00:00
Aaron Schulz
30c33a20ee
Don't show deleted user names
2009-03-09 08:52:04 +00:00
Nathaniel Herman
df7ba5f52c
(bug 10336) Added new magic word {{REVISIONUSER}}, which displays the user name of the last user to edit the page
2009-03-07 23:01:59 +00:00
Aaron Schulz
ee13359dd5
style/profiling tweaks
2009-03-06 02:25:28 +00:00