Social Dropdown

Download

You can drop me an E-mail at Ready725 atgmail.com.

Progress on this project has stalled as it is no longer convenient for me to update the plugin. Contributers to the plugin are welcomed.

A project related to this plugin is a Social Bookmarking generator which generates the Social Bookmarks (as links) using the drag and drop feature. A nice way of trying out the drag and drop feature of the plugin without actually using it.

Introduction

Social dropdown

Social bookmarks are places where you can store your bookmarks into one place. However, they are unlike normal bookmarks in that they can be shared between people (hence "social"). Social bookmarking sites give immense traffic to popular articles bookmarked, hence is seen as a valuable source of traffic for most sites.

In order to bookmark a post, you will need to click on an icon that corresponds to the bookmarking site. You can hover your mouse over the icons to show the name of the bookmarking site. Once you click on the link, you will submit the page for bookmarking. Some bookmarking sites require registration before you can submit a page.

Description

This plugin displays several social bookmarking options in a dropdown. Unlike other social bookmarking displays, this does not cause clutter and takes up little screen space.
Social Dropdown

Some of the supported social bookmarks are:

A complete list is found at the Social Bookmark service page.

Installation

By installing the plugin, you agree to Tevine's policies.

  1. Upload the "socialdropdown" folder into the "/wp-content/plugins/" directory. This folder contains the following files and directories:

    • readme.txt
    • dropdown.js
    • style.css
    • socialdropdown.php
    • icons/
  2. Login to your Wordpress Administration Panel

  3. Go to the plugins tab, and activate the "Social Dropdown" plug-in. If there are no error messages, the plugin is properly installed.

  4. Add the following line of code to your Wordpress template: <?php Show_Dropdown(); ?>. This should be in the Wordpress loop (i.e. where your posts are generated). The Wordpress loop is commonly found in the index.php and single.php files.

  5. Customize the bookmark through the options panel (Options » Social Dropdown).
    Social Dropdown configuration using Drag and Drop

Feel free to poke around the internals of the plug-in.

Update

Upgrading requires only the replacement of plug-in files. There is no need to edit your Wordpress template.

  1. Deactivate the Social Dropdown plugin

  2. Upload the "socialdropdown" folder into the "/wp-content/plugins/" directory. This folder contains the following files and directories:

    • readme.txt
    • dropdown.js
    • style.css
    • style_black.css
    • style_white (default).css
    • socialdropdown.php
    • icons/
  3. Activate the "Social Dropdown" plug-in. If there are no error messages, the plugin is properly updated.

Requirements

  1. A working Wordpress install

  2. Your WordPress theme must contain a call to the get_header() function

  3. Your WordPress theme must contain the Wordpress loop

Customization

Within socialdropdown.php, these are some areas you can edit to influence how the dropdown appears.

Prior to 1.3.0., you can use the GenerateAll() function to re-arrange how the items appear, add new items or remove them. In versions 1.3.0 and later, you can customize bookmarks via `Options > Social Dropdown`.

Creating bookmarks

Each social bookmark is generated using the GenerateLink() function, and the URLs used are created using the GenerateURL() function. The parameters are as followed: GenerateLink($type), where $type is the name of the social bookmark (e.g. Digg is represented as 'digg').

In order to add a new bookmark, add the following lines of code after an item [i.e. after break;] in the GenerateURL() function. An example is shown

case '[name of social bookmarking site]':
?>
[URL to social bookmark page]
<?php
break;

In this example, when you call GenerateURL('yahoo'), the link for this item is generated. The link is the direct link to the submitting URL, usually available as an API on the social bookmarking site. Within the URL, there is some PHP code. the_title() represents the post title, while echo get_the_permalink() represents the URL of the post.

After adding the code, don't forget to put in GenerateLink('[name of social bookmark site]') in GenerateAll()

Screenshots

Bookmarks displayed in a dropdown - Screenshot
Bookmarks displayed in a dropdown

Bookmarks displayed in non-Javascript mode - Screenshot
Bookmarks displayed in non-Javascript mode

Plugin configuration page, Drag and drop to arrange bookmarks - Screenshot
Plugin configuration page, Drag and drop to arrange bookmarks

Original dropdown - Screenshot
Original dropdown