Index: trunk/phase3/includes/parser/Parser.php |
— | — | @@ -3883,8 +3883,9 @@ |
3884 | 3884 | |
3885 | 3885 | # Inhibit editsection links if requested in the page |
3886 | 3886 | if ( isset( $this->mDoubleUnderscores['noeditsection'] ) ) { |
3887 | | - $showEditLink = 0; |
| 3887 | + $maybeShowEditLink = $showEditLink = false; |
3888 | 3888 | } else { |
| 3889 | + $maybeShowEditLink = true; /* Actual presence will depend on ParserOptions option */ |
3889 | 3890 | $showEditLink = $this->mOptions->getEditSection(); |
3890 | 3891 | } |
3891 | 3892 | if ( $showEditLink ) { |
— | — | @@ -4139,7 +4140,7 @@ |
4140 | 4141 | ); |
4141 | 4142 | |
4142 | 4143 | # give headline the correct <h#> tag |
4143 | | - if ( $sectionIndex !== false ) { |
| 4144 | + if ( $maybeShowEditLink && $sectionIndex !== false ) { |
4144 | 4145 | // Output edit section links as markers with styles that can be customized by skins |
4145 | 4146 | if ( $isTemplate ) { |
4146 | 4147 | # Put a T flag in the section identifier, to indicate to extractSections() |