You are here

function facebook_comments_block_configure in Facebook Comments Social Plugin 7

Implements hook_block_configure().

File

./facebook_comments.module, line 52
Facebook Comments Social Plugin module file.

Code

function facebook_comments_block_configure($delta = '') {
  $form = array();
  if ($delta == 'facebook-comments') {
    $form['facebook_comments_block_style'] = array(
      '#type' => 'select',
      '#title' => t('Color Scheme'),
      '#default_value' => variable_get('facebook_comments_block_style', 'light'),
      '#options' => array(
        'light' => t('Light'),
        'dark' => t('Dark'),
      ),
    );
    $form['facebook_comments_block_width'] = array(
      '#type' => 'textfield',
      '#title' => t('Facebook comment plugin width'),
      '#default_value' => variable_get('facebook_comments_block_width', 208),
      '#description' => t('The width of the Facebook comment plugin for the block, in pixels. Example: 208'),
    );
    $form['facebook_comments_block_width_fluid'] = array(
      '#type' => 'checkbox',
      '#title' => t('Fluid Facebook comment plugin width'),
      '#default_value' => variable_get('facebook_comments_block_width_fluid', 1),
      '#description' => t('Make the width of the Facebook comment plugin for the block fluid (100%). This overrules the width settings above.'),
    );
    $form['facebook_comments_block_amount'] = array(
      '#type' => 'select',
      '#title' => t('Amount of comments to display'),
      '#options' => array(
        1 => 1,
        2 => 2,
        3 => 3,
        5 => 5,
        7 => 7,
        10 => 10,
        15 => 15,
        20 => 20,
        30 => 30,
      ),
      '#default_value' => variable_get('facebook_comments_block_amount', 5),
    );
  }
  return $form;
}