Themes: Use esc_url() for theme screenshots on the Themes screen.

This brings consistency with how screenshots are escaped elsewhere.

Follow-up to [52020], [52947].

See #53370.

git-svn-id: https://develop.svn.wordpress.org/trunk@52949 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2022-03-18 13:42:34 +00:00
parent 7222112803
commit 22167a2d80

View File

@ -388,7 +388,7 @@ foreach ( $themes as $theme ) :
<div class="theme<?php echo $active_class; ?>">
<?php if ( ! empty( $theme['screenshot'][0] ) ) { ?>
<div class="theme-screenshot">
<img src="<?php echo esc_attr( $theme['screenshot'][0] . '?ver=' . $theme['version'] ); ?>" alt="" />
<img src="<?php echo esc_url( $theme['screenshot'][0] . '?ver=' . $theme['version'] ); ?>" alt="" />
</div>
<?php } else { ?>
<div class="theme-screenshot blank"></div>