function httpbl_request_whitelist in http:BL 7
Same name and namespace in other branches
- 5 httpbl.module \httpbl_request_whitelist()
- 6.2 httpbl.module \httpbl_request_whitelist()
- 6 httpbl.module \httpbl_request_whitelist()
Form to request a session whitelist.
1 string reference to 'httpbl_request_whitelist'
- httpbl_menu in ./
httpbl.module - Implementation of hook_menu().
File
- ./
httpbl.module, line 448 - Implementation of http:BL for Drupal. It provides IP-based blacklisting through http:BL and allows linking to a honeypot.
Code
function httpbl_request_whitelist($form, &$form_state) {
$form['reason'] = array(
'#type' => 'textarea',
'#title' => t('Reason you were blocked. (It\'s okay to say you don\'t know if you don\'t)'),
'#size' => 60,
'#required' => TRUE,
);
$form['block'] = array(
'#type' => 'textfield',
'#title' => t('LEAVE THIS BLANK! (This is where spiders fail, because they don\'t actually read!)'),
'#size' => 15,
);
$form['leave'] = array(
'#type' => 'textfield',
'#size' => 30,
'#attributes' => array(
'style' => 'display: none',
),
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Whitelist request'),
);
// Save incoming original destination as a hidden form value
$form['arrival'] = array(
'#type' => 'hidden',
'#default_value' => $_SESSION['httpbl_destination'],
);
return $form;
}