Index: trunk/phase3/includes/parser/Parser.php |
— | — | @@ -511,6 +511,22 @@ |
512 | 512 | } |
513 | 513 | |
514 | 514 | /** |
| 515 | + * Recursive parser entry point that can be called from an extension tag |
| 516 | + * hook. |
| 517 | + * |
| 518 | + * @param $text String: text to be expanded |
| 519 | + * @param $frame PPFrame: The frame to use for expanding any template variables |
| 520 | + * @return String |
| 521 | + */ |
| 522 | + public function recursivePreprocess( $text, $frame = false ) { |
| 523 | + wfProfileIn( __METHOD__ ); |
| 524 | + $text = $this->replaceVariables( $text, $frame ); |
| 525 | + $text = $this->mStripState->unstripBoth( $text ); |
| 526 | + wfProfileOut( __METHOD__ ); |
| 527 | + return $text; |
| 528 | + } |
| 529 | + |
| 530 | + /** |
515 | 531 | * Process the wikitext for the ?preload= feature. (bug 5210) |
516 | 532 | * |
517 | 533 | * <noinclude>, <includeonly> etc. are parsed as for template transclusion, |