Skip to content

Instantly share code, notes, and snippets.

@arcivanov
Created August 6, 2016 03:53
Show Gist options
  • Save arcivanov/29f64eb0563a38f51c1fced907bba736 to your computer and use it in GitHub Desktop.
Save arcivanov/29f64eb0563a38f51c1fced907bba736 to your computer and use it in GitHub Desktop.
--- content-singlestyle1.php~ 2016-07-28 15:47:42.000000000 -0400
+++ content-singlestyle1.php 2016-08-05 23:40:19.127662218 -0400
@@ -147,32 +147,32 @@
<h3><?php _e( 'SHARE', 'circleflip' ); ?></h3>
<ul>
<li>
- <a class="twitter popup" href="http://twitter.com/share?text=<?php the_title(); ?>&url=<?php the_permalink(); ?>" target="_blank" title="Share on Twitter"></a>
+ <a class="twitter popup" href="//twitter.com/share?text=<?php the_title(); ?>&url=<?php the_permalink(); ?>" target="_blank" title="Share on Twitter"></a>
</li>
<li>
<?php
$image_id = get_post_thumbnail_id( $post->ID );
$image_attributes = wp_get_attachment_image_src( $image_id );
?>
- <a class="popup pinterest" href="http://pinterest.com/pin/create/button/?url=<?php the_permalink(); ?>&amp;media=<?php echo esc_attr($image_attributes[0]) ?>" target="_blank" title="Share on Pinterest"></a>
+ <a class="popup pinterest" href="//pinterest.com/pin/create/button/?url=<?php the_permalink(); ?>&amp;media=<?php echo esc_attr($image_attributes[0]) ?>" target="_blank" title="Share on Pinterest"></a>
</li>
<li>
- <script src="http://platform.tumblr.com/v1/share.js"></script>
+ <script src="//platform.tumblr.com/v1/share.js"></script>
<a class="popup tumblr" href="http://www.tumblr.com/share/link?url=<?php echo urlencode( get_permalink() ) ?>&name=<?php echo urlencode( get_the_title() ) ?>" title="Share on Tumblr"></a>
</li>
<li>
- <a class="popup stumbleUpon" href="http://www.stumbleupon.com/submit?url=<?php the_permalink(); ?>&title=<?php the_title(); ?>" target="_blank" title="Share on StumbleUpon"></a>
+ <a class="popup stumbleUpon" href="//www.stumbleupon.com/submit?url=<?php the_permalink(); ?>&title=<?php the_title(); ?>" target="_blank" title="Share on StumbleUpon"></a>
</li>
<li>
<div class="googleplus">
<div class="googlehider">
- <script src="http://platform.linkedin.com/in.js" type="text/javascript"></script><script type="IN/Share" data-url="<?php the_permalink(); ?>" data-counter="right"></script>
+ <script src="//platform.linkedin.com/in.js" type="text/javascript"></script><script type="IN/Share" data-url="<?php the_permalink(); ?>" data-counter="right"></script>
</div>
<span class="linkedIn"></span>
</div>
</li>
<li>
- <a class="popup facebook" href="http://www.facebook.com/sharer.php?&amp;p[url]=<?php the_permalink(); ?>&amp;p[title]=<?php the_title(); ?>&amp;p[images][0]=<?php echo isset( $image_attributes[0] ) && ! empty( $image_attributes[0] ) ? $image_attributes[0] : ''; ?>" title="Share on Facebook" target="_blank" ></a>
+ <a class="popup facebook" href="//www.facebook.com/sharer.php?&amp;p[url]=<?php the_permalink(); ?>&amp;p[title]=<?php the_title(); ?>&amp;p[images][0]=<?php echo isset( $image_attributes[0] ) && ! empty( $image_attributes[0] ) ? $image_attributes[0] : ''; ?>" title="Share on Facebook" target="_blank" ></a>
</li>
<li>
<div class="googleplus">
--- content-singlestyle2.php~ 2016-07-28 15:47:42.000000000 -0400
+++ content-singlestyle2.php 2016-08-05 23:41:20.463553948 -0400
@@ -137,32 +137,32 @@
<h3><?php _e( 'SHARE', 'circleflip' ); ?></h3>
<ul>
<li>
- <a class="twitter popup" href="<?php echo esc_url( 'http://twitter.com/share?text=' . get_the_title() . '&url=' . get_the_permalink() ); ?>" title="Share on Twitter"></a>
+ <a class="twitter popup" href="<?php echo esc_url( '//twitter.com/share?text=' . get_the_title() . '&url=' . get_the_permalink() ); ?>" title="Share on Twitter"></a>
</li>
<li>
<?php
$image_id = get_post_thumbnail_id( $post->ID );
$image_attributes = wp_get_attachment_image_src( $image_id );
?>
- <a class="popup pinterest" href="<?php echo esc_url( 'http://pinterest.com/pin/create/button/?url=' . get_the_permalink() . '&amp;media=' . $image_attributes[0] ); ?>" title="Share on Pinterest"></a>
+ <a class="popup pinterest" href="<?php echo esc_url( '//pinterest.com/pin/create/button/?url=' . get_the_permalink() . '&amp;media=' . $image_attributes[0] ); ?>" title="Share on Pinterest"></a>
</li>
<li>
- <script src="http://platform.tumblr.com/v1/share.js"></script>
- <a class="popup tumblr" href="http://www.tumblr.com/share/link?url=<?php echo urlencode( get_permalink() ) ?>&name=<?php echo urlencode( get_the_title() ) ?>" title="Share on Tumblr"></a>
+ <script src="//platform.tumblr.com/v1/share.js"></script>
+ <a class="popup tumblr" href="//www.tumblr.com/share/link?url=<?php echo urlencode( get_permalink() ) ?>&name=<?php echo urlencode( get_the_title() ) ?>" title="Share on Tumblr"></a>
</li>
<li>
- <a class="popup stumbleUpon" href="http://www.stumbleupon.com/submit?url=<?php the_permalink(); ?>&title=<?php the_title(); ?>" target="_blank" title="Share on StumbleUpon"></a>
+ <a class="popup stumbleUpon" href="//www.stumbleupon.com/submit?url=<?php the_permalink(); ?>&title=<?php the_title(); ?>" target="_blank" title="Share on StumbleUpon"></a>
</li>
<li>
<div class="googleplus">
<div class="googlehider">
- <script src="http://platform.linkedin.com/in.js" type="text/javascript"></script><script type="IN/Share" data-url="<?php the_permalink(); ?>" data-counter="right"></script>
+ <script src="//platform.linkedin.com/in.js" type="text/javascript"></script><script type="IN/Share" data-url="<?php the_permalink(); ?>" data-counter="right"></script>
</div>
<span class="linkedIn"></span>
</div>
</li>
<li>
- <a class="popup facebook" href="http://www.facebook.com/sharer.php?&amp;p[url]=<?php the_permalink(); ?>&amp;p[title]=<?php the_title(); ?>&amp;p[images][0]=<?php echo isset( $image_attributes[0] ) && ! empty( $image_attributes[0] ) ? $image_attributes[0] : ''; ?>" title="Share on Facebook"></a>
+ <a class="popup facebook" href="//www.facebook.com/sharer.php?&amp;p[url]=<?php the_permalink(); ?>&amp;p[title]=<?php the_title(); ?>&amp;p[images][0]=<?php echo isset( $image_attributes[0] ) && ! empty( $image_attributes[0] ) ? $image_attributes[0] : ''; ?>" title="Share on Facebook"></a>
</li>
<li>
<div class="googleplus">
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment