Commit 9696035f authored by hass's avatar hass Committed by mikeytown2

Issue #1874764 by hass: Fix admin form wording and formatting.

parent ebe039ca
......@@ -10,50 +10,59 @@
*/
function httprl_admin_settings_form() {
$form['httprl_server_addr'] = array(
'#type' => 'textfield',
'#title' => t('IP Address to send all self server requests to'),
'#default_value' => variable_get('httprl_server_addr', FALSE),
'#description' => t('If left blank it will use the same server as the request. If set to -1 it will use the host name instead of an IP address. This controls the output of httprl_build_url_self()'),
'#type' => 'textfield',
'#title' => t('IP Address to send all self server requests to'),
'#default_value' => variable_get('httprl_server_addr', FALSE),
'#description' => t('If left blank it will use the same server as the request. If set to -1 it will use the host name instead of an IP address. This controls the output of httprl_build_url_self()'),
);
$form['timeous'] = array(
$form['timeouts'] = array(
'#type' => 'fieldset',
'#title' => t('Default Timeouts'),
'#title' => t('Default timeouts'),
'#collapsible' => TRUE,
'#collapsed' => TRUE,
'#description' => t('Set the default timeouts. These will be overridden if a different timeout is set in the options array.'),
);
$form['timeous']['httprl_dns_timeout'] = array(
'#type' => 'textfield',
'#title' => t('dns_timeout. Maximum number of seconds a DNS lookup request may take'),
'#default_value' => variable_get('httprl_dns_timeout', HTTPRL_DNS_TIMEOUT),
'#description' => t('Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_DNS_TIMEOUT)),
$form['timeouts']['httprl_dns_timeout'] = array(
'#type' => 'textfield',
'#title' => t('DNS timeout (<code>dns_timeout</code>)'),
'#default_value' => variable_get('httprl_dns_timeout', HTTPRL_DNS_TIMEOUT),
'#description' => t('Maximum number of seconds a DNS lookup request may take. Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_DNS_TIMEOUT)),
'#field_suffix' => t('seconds'),
'#size' => 5,
);
$form['timeous']['httprl_connect_timeout'] = array(
'#type' => 'textfield',
'#title' => t('connect_timeout. Maximum number of seconds establishing the TCP connection may take'),
'#default_value' => variable_get('httprl_connect_timeout', HTTPRL_CONNECT_TIMEOUT),
'#description' => t('Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_CONNECT_TIMEOUT)),
$form['timeouts']['httprl_connect_timeout'] = array(
'#type' => 'textfield',
'#title' => t('Connection timeout (<code>connect_timeout</code>)'),
'#default_value' => variable_get('httprl_connect_timeout', HTTPRL_CONNECT_TIMEOUT),
'#description' => t('Maximum number of seconds establishing the TCP connection may take. Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_CONNECT_TIMEOUT)),
'#field_suffix' => t('seconds'),
'#size' => 5,
);
$form['timeous']['httprl_ttfb_timeout'] = array(
'#type' => 'textfield',
'#title' => t('ttfb_timeout. Maximum number of seconds a connection may take to download the first byte'),
'#default_value' => variable_get('httprl_ttfb_timeout', HTTPRL_TTFB_TIMEOUT),
'#description' => t('Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_TTFB_TIMEOUT)),
$form['timeouts']['httprl_ttfb_timeout'] = array(
'#type' => 'textfield',
'#title' => t('Time to first byte (<code>ttfb_timeout</code>)'),
'#default_value' => variable_get('httprl_ttfb_timeout', HTTPRL_TTFB_TIMEOUT),
'#description' => t('Maximum number of seconds a connection may take to download the first byte. Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_TTFB_TIMEOUT)),
'#field_suffix' => t('seconds'),
'#size' => 5,
);
$form['timeous']['httprl_timeout'] = array(
'#type' => 'textfield',
'#title' => t('timeout. Maximum number of seconds the request may take'),
'#default_value' => variable_get('httprl_timeout', HTTPRL_TIMEOUT),
'#description' => t('Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_TIMEOUT)),
$form['timeouts']['httprl_timeout'] = array(
'#type' => 'textfield',
'#title' => t('Timeout (<code>timeout</code>)'),
'#default_value' => variable_get('httprl_timeout', HTTPRL_TIMEOUT),
'#description' => t('Maximum number of seconds the request may take. Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_TIMEOUT)),
'#field_suffix' => t('seconds'),
'#size' => 5,
);
$form['timeous']['httprl_global_timeout'] = array(
'#type' => 'textfield',
'#title' => t('global_timeout. Maximum number of seconds httprl_send_request() may take'),
'#default_value' => variable_get('httprl_global_timeout', HTTPRL_GLOBAL_TIMEOUT),
'#description' => t('Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_GLOBAL_TIMEOUT)),
$form['timeouts']['httprl_global_timeout'] = array(
'#type' => 'textfield',
'#title' => t('Global timeout (<code>global_timeout</code>)'),
'#default_value' => variable_get('httprl_global_timeout', HTTPRL_GLOBAL_TIMEOUT),
'#description' => t('Maximum number of seconds httprl_send_request() may take. Value can be a float. The default is %value seconds.', array('%value' => HTTPRL_GLOBAL_TIMEOUT)),
'#field_suffix' => t('seconds'),
'#size' => 5,
);
return system_settings_form($form);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment