function fbconnect_autoconnect_form in Facebook Connect 6.2
Same name and namespace in other branches
- 5 fbconnect.module \fbconnect_autoconnect_form()
- 6 fbconnect.module \fbconnect_autoconnect_form()
This form is submitted by javascript when facebook session is detected.
2 string references to 'fbconnect_autoconnect_form'
- fbconnect_footer in ./
fbconnect.module - Implements hook_footer().
- fbconnect_init in ./
fbconnect.module - Implements hook_init().
File
- ./
fbconnect.module, line 468 - Integration with Facebook Connect API.
Code
function fbconnect_autoconnect_form() {
$form['#id'] = 'fbconnect-autoconnect-form';
if (arg(0) == 'user' && in_array(arg(1), array(
'login',
'register',
'password',
)) && !isset($_REQUEST['destination'])) {
$form['#action'] = url('user');
}
else {
$form['#action'] = url($_GET['q'], array(
'query' => drupal_get_destination(),
));
}
$form['connect'] = array(
'#type' => 'submit',
'#value' => 'Connect',
);
return $form;
}