You are here

function similarterms_block_save in Similar By Terms 7

Same name and namespace in other branches
  1. 6 similarterms.module \similarterms_block_save()

Perform the "save" op for hook_block().

Parameters

$delta: String specifying which block to proocess.

$edit: Array containg the form input.

Return value

None. Values are saved as system variables.

File

./similarterms.module, line 138
Similar By Terms module displays a block with similar content based on taxonomy terms.

Code

function similarterms_block_save($delta = '', $edit = array()) {
  variable_set('similarterms_count_' . $delta, $edit['count']);
  variable_set('similarterms_sametype_' . $delta, $edit['sametype']);
  variable_set('similarterms_showcurrentnode_' . $delta, $edit['showcurrentnode']);

  //Only conditionally shown in the edit form, so not always set.
  if (isset($edit['ignoreterms'])) {
    variable_set('similarterms_ignoreterms_' . $delta, $edit['ignoreterms']);
  }
}