You are here

function _fblikebutton_ds_field in Facebook Like Button 7.2

Callback for ds button.

1 string reference to '_fblikebutton_ds_field'
fblikebutton_ds_fields_info in ./fblikebutton.module
Implements hook_ds_fields_info().

File

./fblikebutton.module, line 232
Adds Facebook's "Like" button to each selected node type. Adds a block with a global static value where users can "Like" the URL set by admins.

Code

function _fblikebutton_ds_field($field) {
  if (!user_access('access fblikebutton')) {
    return '';
  }
  $uri = entity_uri($field['entity_type'], $field['entity']);
  $url = url($uri['path'], array(
    'absolute' => TRUE,
  ));
  $conf = fblikebutton_conf();
  return _fblikebutton_field($url, $conf);
}