Skip to content

planestepper/django-socialsharing

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Socialsharing

This project is a simple integration of various social sharing services for quick integration into Django projects. See the list of supported sharing in the Usage section below.

Installation

Add socialsharing to INSTALLED_APPS in settings.py.

Usage

addthis

The addthis templatetag will insert the necessary scripts to make use of the AddThis widget.

Basic usage:

{% addthis %}

Global settings:

The only required argument is pubid. Of course it can be overriden.

Add a dictionary of properties to your settings.py that will be added to the AddThis Javascript configuration code whenever the templatetag addthis is used. These are meant for site-wide configurations, and should be overriden locally (upon templatetag call) when required.

ADDTHIS_CONFIG = { 
        'pubid': 'your-pub-id',
        'ui-language': 'pt',
        'etc' : 'yet another value'
}

See the AddThis Client API for more information on the available configuration parameters.

Local (per-template) settings:

The addthis templatetag accepts any number of keyword arguments, that will be specifically used to generate the addthis_share configuration:

{% addthis url="http://www.some-domain.ext/some/path/page.html" description="Some relevant description" %}

See the AddThis Client API: Sharing Configuration for information on the available sharing configuration parameters.

About

Simple integration of social sharing widgets (such as AddThis) in Django projects.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%