Fix deprecated string interpolation.

Fixes https://www.mediawiki.org/wiki/Topic:Xwfopidoqfv9r291
This commit is contained in:
Daniel Kraus
2024-01-04 07:23:37 +01:00
parent 57a4db65be
commit 30ef824308
2 changed files with 9 additions and 9 deletions

View File

@ -181,7 +181,7 @@ class Special extends \SpecialPage {
$submitButtonLabel = $this->msg( 'linktitles-special-submit' ); $submitButtonLabel = $this->msg( 'linktitles-special-submit' );
$output->addHTML( $output->addHTML(
<<<EOF <<<EOF
<form method="post" action="${url}"> <form method="post" action="{$url}">
<input type="submit" value="$submitButtonLabel" /> <input type="submit" value="$submitButtonLabel" />
<input type="hidden" name="s" value="0" /> <input type="hidden" name="s" value="0" />
</form> </form>
@ -206,8 +206,8 @@ EOF
$output->addHTML( // TODO: do not use the style attribute (to make it work with CSP-enabled sites) $output->addHTML( // TODO: do not use the style attribute (to make it work with CSP-enabled sites)
<<<EOF <<<EOF
<div style="width:100%; padding:2px; border:1px solid #000; position: relative; margin-bottom:16px;"> <div style="width:100%; padding:2px; border:1px solid #000; position: relative; margin-bottom:16px;">
<span style="position: absolute; left: 50%; font-weight:bold; color:#555;">${percent}%</span> <span style="position: absolute; left: 50%; font-weight:bold; color:#555;">{$percent}%</span>
<div style="width:${progress}%; background-color:#bbb; height:20px; margin:0;"></div> <div style="width:{$progress}%; background-color:#bbb; height:20px; margin:0;"></div>
</div> </div>
EOF EOF
); );
@ -226,10 +226,10 @@ EOF
private function getReloaderForm( $url, $start, $end, $reloads ) { private function getReloaderForm( $url, $start, $end, $reloads ) {
return return
<<<EOF <<<EOF
<form method="post" name="linktitles" action="${url}"> <form method="post" name="linktitles" action="{$url}">
<input type="hidden" name="s" value="${start}" /> <input type="hidden" name="s" value="{$start}" />
<input type="hidden" name="e" value="${end}" /> <input type="hidden" name="e" value="{$end}" />
<input type="hidden" name="r" value="${reloads}" /> <input type="hidden" name="r" value="{$reloads}" />
</form> </form>
<script type="text/javascript"> <script type="text/javascript">
document.linktitles.submit(); document.linktitles.submit();

View File

@ -180,7 +180,7 @@ class Cli extends \Maintenance {
); );
$numPages = $res->numRows(); $numPages = $res->numRows();
$context = \RequestContext::getMain(); $context = \RequestContext::getMain();
$this->output( "Processing ${numPages} pages, starting at index ${index}...\n" ); $this->output( "Processing {$numPages} pages, starting at index {$index}...\n" );
$numProcessed = 0; $numProcessed = 0;
foreach ( $res as $row ) { foreach ( $res as $row ) {