Form constructor for the OpenID login form.
function openid_login_form($form) {
$form['#attached']['library'][] = array(
'openid',
'drupal.openid',
);
$form['openid_identifier'] = array(
'#type' => 'textfield',
'#title' => t('OpenID'),
'#maxlength' => 255,
'#description' => l(t('What is OpenID?'), 'http://openid.net/', array(
'external' => TRUE,
)),
'#required' => TRUE,
);
$form['openid.return_to'] = array(
'#type' => 'hidden',
'#value' => url('openid/authenticate', array(
'absolute' => TRUE,
'query' => user_login_destination(),
)),
);
$form['actions'] = array(
'#type' => 'actions',
);
$form['actions']['submit'] = array(
'#type' => 'submit',
'#value' => t('Log in'),
);
return $form;
}