Bottom Share Buttons Not Sharing Current URL

This topic is: Resolved

This is a PRIVATE forum for verified users only, to view the replies/answers, you must be logged in!

This topic contains 6 replies, has 3 voices, and was last updated by  Thakksy 1 year, 8 months ago.

  • Author
    Posts
  • #7918

    Thakksy
    Member
    Post count: 321

    hey folks,

    So i added the small Sparkle share buttons at the bottom of all posts and pages by adding the following html in content-single and content-page files.

    <div class="social-share-buttons pull-right style-color size-small" data-url="http://www.cruisehive.com/the-challenges-facing-quantum-of-the-seas-in-china/6271" data-title="The Challenges Facing Quantum of the Seas in China" data-source="http://www.cruisehive.com/" data-media="http://www.cruisehive.com/wp-content/uploads/2015/03/quantum11.jpg"><span title="Twitter" class="twitter" data-service="twitter" data-show="true"><i class="fa fa-twitter"></i><label class="hidden-xs">Twitter</label></span><span title="Facebook" class="facebook" data-service="facebook" data-show="true"><i class="fa fa-facebook-square"></i><label class="hidden-xs">Facebook</label></span><span title="Share on Google+" class="google-plus hidden" data-service="google-plus" data-show="false"><i class="fa fa-google-plus"></i><label class="hidden-xs hidden">Share on Google+</label></span><span title="Share on Linkedin" class="linkedin hidden" data-service="linkedin" data-show="false"><i class="fa fa-linkedin"></i><label class="hidden-xs hidden">Share on Linkedin</label></span><span title="Pin this Post" class="pinterest hidden" data-service="pinterest" data-show="false"><i class="fa fa-pinterest"></i><label class="hidden-xs hidden">Pin this Post</label></span><span title="Share on Tumblr" class="tumblr hidden" data-service="tumblr" data-show="false"><i class="fa fa-tumblr"></i><label class="hidden-xs hidden">Share on Tumblr</label></span><span title="More services" class="more" data-service="more" data-show="true"><i class="fa fa-ellipsis-h"></i><label class="hidden-xs hidden">More services</label></span></div>

    So my question is how to change the html so that the share buttons use the current page? I know i made a mistake at the top of the code.

  • #7925

    Max
    Staff
    Post count: 3150

    Hey there, You must be logged in to view this reply!

    Login | Register | Forgot Password?

  • #7976

    Thakksy
    Member
    Post count: 321

    sorry my php is really bad, what code do i use to add into a php block? i want to input the code in content-single.php

  • #7990

    Max
    Staff
    Post count: 3150

    Hey there, You must be logged in to view this reply!

    Login | Register | Forgot Password?

  • #8001

    Thakksy
    Member
    Post count: 321

    Didn’t work, got the following error:

    Warning: in_array() expects parameter 2 to be array, null given in /home/thakksy/public_html/wp-content/themes/sparkle-childtheme/content-single.php on line 171

  • #8018

    Jacob
    Staff
    Post count: 2323

    Hey there, You must be logged in to view this reply!

    Login | Register | Forgot Password?

  • #8027

    Thakksy
    Member
    Post count: 321

    it’s done, great. Thanks so much Maxxi and jacob your guys know your coding! i’m good with html but not with php!

You must be logged in to reply to this topic.

This is a PRIVATE forum for verified users only, to view the replies/answers, you must be logged in!