innoweb/silverstripe-social-share

Adds sharing links and buttons for Facebook, Twitter, Instagram, Pinterest and Google+ as well as AddThis to the site.

Installs: 1 380

Dependents: 0

Suggesters: 2

Security: 0

Stars: 0

Watchers: 2

Forks: 2

Open Issues: 0

Type:silverstripe-vendormodule

3.0.3 2020-08-21 05:31 UTC

This package is auto-updated.

Last update: 2021-03-21 07:04:25 UTC


README

Version License

Overview

Adds sharing links and buttons for Facebook, Twitter, Instagram, Pinterest and Google+ as well as AddThis to the site.

Requirements

  • SilverStripe CMS 4.x

Note: this version is compatible with SilverStripe 4. For SilverStripe 3, please see the 1.0 release line.

Installation

Install the module using composer:

composer require innoweb/silverstripe-social-share dev-master

or download or git clone the module into a ‘social-share’ directory in your webroot.

Then run dev/build.

Configuration

The module adds a new tab to the SiteConfig in the CMS where the sharing options can be managed.

To add the sharing links to your site, add the following include to your Page.ss template:

<% include PageShareLinks %>

This will activate sharing for the current page.

You can also activate sharing of the base URL of the site for all pages. For that, activate the following setting in your config.yml:

Innoweb\SocialShare\Extensions\ConfigExtension:
  enable_base_share: true

You also have to add the following include to your Page.ss file:

<% include BaseShareLinks %>

MultiSites support

The module supports the [multisites module] (https://github.com/silverstripe-australia/silverstripe-multisites) and by default adds the config options to the Sites.

If you want to manage the social links globally, please add the following settings in your config.yml:

Innoweb\SocialShare\Extensions\ConfigExtension:
  multisites_enable_global_settings: true

This will add the fields to your SiteConfig instead of Site.

License

BSD 3-Clause License, see License