You are here

function ws_pinterest_button_data in Service links 7.2

Same name and namespace in other branches
  1. 6.2 services/widget_services.module \ws_pinterest_button_data()

Callback function for Pinterest Button.

1 string reference to 'ws_pinterest_button_data'
widget_services_service_links in services/widget_services.module
Implements hook_service_links().

File

services/widget_services.module, line 214
Extends Service Links with dynamic buttons.

Code

function ws_pinterest_button_data(&$service, $subst) {
  static $pb_settings;
  if (!isset($pb_settings)) {
    $pb_settings = array(
      'countlayout' => check_plain(variable_get('service_links_pb_countlayout', 'horizontal')),
    );
    drupal_add_js(array(
      'ws_pb' => $pb_settings,
    ), 'setting');
  }
}