summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/jetpack/modules/sharedaddy/sharing-sources.php')
-rw-r--r--plugins/jetpack/modules/sharedaddy/sharing-sources.php14
1 files changed, 10 insertions, 4 deletions
diff --git a/plugins/jetpack/modules/sharedaddy/sharing-sources.php b/plugins/jetpack/modules/sharedaddy/sharing-sources.php
index a086e0f0..a77a6cbf 100644
--- a/plugins/jetpack/modules/sharedaddy/sharing-sources.php
+++ b/plugins/jetpack/modules/sharedaddy/sharing-sources.php
@@ -201,11 +201,12 @@ abstract class Sharing_Source {
$text = apply_filters( 'jetpack_sharing_display_text', $text, $this, $id, $args );
return sprintf(
- '<a rel="nofollow" data-shared="%s" class="%s" href="%s"%s title="%s"><span%s>%s</span></a>',
+ '<a rel="nofollow%s" data-shared="%s" class="%s" href="%s"%s title="%s"><span%s>%s</span></a>',
+ ( true == $this->open_link_in_new ) ? ' noopener noreferrer' : '',
( $id ? esc_attr( $id ) : '' ),
implode( ' ', $klasses ),
$url,
- ( true == $this->open_link_in_new ) ? ' rel="noopener noreferrer" target="_blank"' : '',
+ ( true == $this->open_link_in_new ) ? ' target="_blank"' : '',
$title,
( 'icon' == $this->button_style ) ? '></span><span class="sharing-screen-reader-text"' : '',
$text
@@ -532,7 +533,7 @@ class Share_Email extends Sharing_Source {
/** This filter is documented in modules/stats.php */
echo apply_filters( 'jetpack_static_url', plugin_dir_url( __FILE__ ) . 'images/loading.gif' ); ?>" alt="loading" width="16" height="16" />
<input type="submit" value="<?php esc_attr_e( 'Send Email', 'jetpack' ); ?>" class="sharing_send" />
- <a rel="nofollow" href="#cancel" class="sharing_cancel"><?php _e( 'Cancel', 'jetpack' ); ?></a>
+ <a rel="nofollow" href="#cancel" class="sharing_cancel" role="button"><?php _e( 'Cancel', 'jetpack' ); ?></a>
<div class="errors errors-1" style="display: none;">
<?php _e( 'Post was not sent - check your email addresses!', 'jetpack' ); ?>
@@ -589,7 +590,12 @@ class Share_Twitter extends Sharing_Source {
* @param string $string Twitter Username.
* @param array $args Array of Open Graph Meta Tags and Twitter Cards tags.
*/
- $twitter_site_tag_value = apply_filters( 'jetpack_twitter_cards_site_tag', '', array() );
+ $twitter_site_tag_value = apply_filters(
+ 'jetpack_twitter_cards_site_tag',
+ '',
+ /** This action is documented in modules/sharedaddy/sharing-sources.php */
+ array( 'twitter:creator' => apply_filters( 'jetpack_sharing_twitter_via', '', $post->ID ) )
+ );
/*
* Hack to remove the unwanted behavior of adding 'via @jetpack' which