https://github.com/PressForward/pressforward
Tip revision: 908d0bccb03b65dccff0fc104ee58f3f2e7ed534 authored by Boone B Gorges on 16 January 2024, 22:31:29 UTC
Merge branch '5.6.x'
Merge branch '5.6.x'
Tip revision: 908d0bc
nominate-this-buttons.tpl.php
<?php
/**
* Template for the bookmarklet-code block.
*
* @package PressForward
* @since 5.6.0
*/
?>
<?php wp_enqueue_script( 'pf-blocks-frontend' ); ?>
<?php wp_enqueue_style( 'pf-blocks-frontend' ); ?>
<div class="nominate-this-bookmarklet-code">
<p class="nominate-this-bookmarklet-wrapper">
<?php // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
<a class="nominate-this-bookmarklet" onclick="return false;" href="<?php echo htmlspecialchars( pf_get_shortcut_link() ); ?>"><span><?php esc_html_e( 'Nominate This', 'pressforward' ); ?></span></a>
<button type="button" class="button nominate-this-js-toggle js-show-nominate-this-code-wrap" aria-expanded="false" aria-controls="nominate-this-code-wrap">
<span class="dashicons dashicons-clipboard"></span>
<span class="screen-reader-text"><?php esc_html_e( 'Copy “Nominate This” bookmarklet code', 'pressforward' ); ?></span>
</button>
</p>
<div class="nominate-this-code-wrap clear">
<p id="nominate-this-code-desc">
<?php esc_html_e( 'If you can’t drag the bookmarklet to your bookmarks, copy the following code and create a new bookmark. Paste the code into the new bookmark’s URL field.', 'pressforward' ); ?>
</p>
<p>
<?php // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
<textarea class="js-nominate-this-code" rows="5" cols="120" readonly="readonly" aria-labelledby="nominate-this-code-desc"><?php echo htmlspecialchars( pf_get_shortcut_link() ); ?></textarea>
</p>
</div>
</div>