Skip to content

Commit

Permalink
Coding Standards: Escape attachment URL in wp-admin/async-upload.php.
Browse files Browse the repository at this point in the history
Follow-up to [58279].

Props shyamkariya, pitamdey, nareshbheda, ketanniruke, desrosj.
Fixes #62434.

git-svn-id: https://develop.svn.wordpress.org/trunk@59407 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information
SergeyBiryukov committed Nov 16, 2024
1 parent 2e5e213 commit e6a16ac
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/wp-admin/async-upload.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,9 @@
}
?>
<span class="media-item-copy-container copy-to-clipboard-container edit-attachment">
<button type="button" class="button button-small copy-attachment-url" data-clipboard-text="<?php echo $file_url; ?>"><?php _e( 'Copy URL to clipboard' ); ?></button>
<button type="button" class="button button-small copy-attachment-url"
data-clipboard-text="<?php echo esc_url( $file_url ); ?>"
><?php _e( 'Copy URL to clipboard' ); ?></button>
<span class="success hidden" aria-hidden="true"><?php _e( 'Copied!' ); ?></span>
</span>
</div>
Expand Down

0 comments on commit e6a16ac

Please sign in to comment.