*

Ghany

  • ****
  • 227 posts
Social share Osclass blog
« on: May 10, 2020, 08:05:11 AM »
is that possible to add social sharing options on the blog to share in social media easily?
and while sharing to social media, the link was not displaying the pic of an article, instead of blog main pic, a favicon is reflecting .. how to get blog main pic in the link?
Unlock the power of visibility without breaking the bank - https://www.adycart.in/

*

MB Themes

Re: Social share Osclass blog
« Reply #1 on: May 11, 2020, 08:20:19 AM »
@abdul
You may use code from your theme to create sharing buttons.
File that generates article:
oc-content/plugins/blog/form/article.php
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Ajit Sahane

  • ****
  • 156 posts
  • https://bestclassifiedsusa.com
Re: Social share Osclass blog
« Reply #2 on: July 14, 2020, 05:38:52 PM »
Add below code in article.php

<!-- Facebook --> Share to -
<a href="whatsapp://send?text=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>" target="_blank"> WhatsApp <i class="fa fa-whatsapp"></i></a>

<a href="https://www.facebook.com/sharer.php?u=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>" target="_blank" rel="noopener noreferrer nofollow"> FaceBook <i class="fa fa-facebook-square"></i></a>

<!-- Twitter -->
<a href="https://twitter.com/share?url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>&text=Blog Article&hashtags=nearmeadsblogarticle" target="_blank" rel="noopener noreferrer nofollow">Twitter <i class="fa fa-twitter"></i></a>

<!-- Digg -->
<a href="https://www.digg.com/submit?url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>" target="_blank" rel="noopener noreferrer nofollow">Digg <i class="fa fa-digg" aria-hidden="true"></i></a>

<!-- Reddit -->
<a href="https://reddit.com/submit?url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>&title=Blog Article" target="_blank" rel="noopener noreferrer nofollow">Reddit <i class="fa fa-reddit" aria-hidden="true"></i></a>

<!-- LinkedIn -->
<a href="http://www.linkedin.com/shareArticle?mini=true&url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>" target="_blank">LinkedIn <i class="fa fa-linkedin" aria-hidden="true"></i></a>

<!-- StumbleUpon-->
<a href="https://www.stumbleupon.com/submit?url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>&title=Blog Article" target="_blank" rel="noopener noreferrer nofollow">StumbleUpon <i class="fa fa-stumbleupon" aria-hidden="true"></i> </a>

*

Ghany

  • ****
  • 227 posts
Re: Social share Osclass blog
« Reply #3 on: July 15, 2020, 12:06:24 AM »
Add below code in article.php

<!-- Facebook --> Share to -
<a href="whatsapp://send?text=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>" target="_blank"> WhatsApp <i class="fa fa-whatsapp"></i></a>

<a href="https://www.facebook.com/sharer.php?u=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>" target="_blank" rel="noopener noreferrer nofollow"> FaceBook <i class="fa fa-facebook-square"></i></a>

<!-- Twitter -->
<a href="https://twitter.com/share?url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>&text=Blog Article&hashtags=nearmeadsblogarticle" target="_blank" rel="noopener noreferrer nofollow">Twitter <i class="fa fa-twitter"></i></a>

<!-- Digg -->
<a href="https://www.digg.com/submit?url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>" target="_blank" rel="noopener noreferrer nofollow">Digg <i class="fa fa-digg" aria-hidden="true"></i></a>

<!-- Reddit -->
<a href="https://reddit.com/submit?url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>&title=Blog Article" target="_blank" rel="noopener noreferrer nofollow">Reddit <i class="fa fa-reddit" aria-hidden="true"></i></a>

<!-- LinkedIn -->
<a href="http://www.linkedin.com/shareArticle?mini=true&url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>" target="_blank">LinkedIn <i class="fa fa-linkedin" aria-hidden="true"></i></a>

<!-- StumbleUpon-->
<a href="https://www.stumbleupon.com/submit?url=<?php echo 'https://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; ?>&title=Blog Article" target="_blank" rel="noopener noreferrer nofollow">StumbleUpon <i class="fa fa-stumbleupon" aria-hidden="true"></i> </a>
Thank you sir
Unlock the power of visibility without breaking the bank - https://www.adycart.in/