Révision 74f6bef0
Ajouté par Assos Assos il y a plus de 10 ans
drupal7/sites/all/themes/adaptivetheme/at_core/inc/forms/settings.metatags.inc | ||
---|---|---|
4 | 4 |
* @file |
5 | 5 |
* Generate form elments for the Metatags for Mobile settings. |
6 | 6 |
*/ |
7 |
function at_core_metatags_form(&$form) { |
|
8 |
$form['at-settings']['meta'] = array( |
|
9 |
'#type' => 'fieldset', |
|
10 |
'#title' => t('Metatags'), |
|
11 |
'#description' => t('<h3>Mobile Metatags</h3><p>Configure metatags for mobile devices. To omit a metatag leave it empty.'), |
|
12 |
); |
|
13 |
$form['at-settings']['meta']['mobile'] = array( |
|
14 |
'#type' => 'fieldset', |
|
15 |
'#title' => t('Mobile Metatags'), |
|
16 |
); |
|
7 | 17 |
|
8 |
$form['at-settings']['meta'] = array(
|
|
9 |
'#type' => 'fieldset',
|
|
10 |
'#title' => t('Metatags'),
|
|
11 |
'#description' => t('<h3>Mobile Metatags</h3><p>Configure metatags for mobile devices. To omit a metatag leave it empty.'),
|
|
12 |
);
|
|
13 |
$form['at-settings']['meta']['mobile'] = array(
|
|
14 |
'#type' => 'fieldset',
|
|
15 |
'#title' => t('Mobile Metatags'),
|
|
16 |
); |
|
18 |
// Viewport
|
|
19 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_viewport'] = array(
|
|
20 |
'#type' => 'textfield',
|
|
21 |
'#title' => t('viewport'),
|
|
22 |
'#default_value' => check_plain(at_get_setting('adaptivetheme_meta_viewport')),
|
|
23 |
'#states' => array(
|
|
24 |
'invisible' => array('input[name="disable_responsive_styles"]' => array('checked' => TRUE)),
|
|
25 |
),
|
|
26 |
);
|
|
17 | 27 |
|
18 |
// Viewport
|
|
19 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_viewport'] = array(
|
|
20 |
'#type' => 'textfield', |
|
21 |
'#title' => t('viewport'),
|
|
22 |
'#default_value' => check_plain(at_get_setting('adaptivetheme_meta_viewport')),
|
|
23 |
'#states' => array( |
|
24 |
'invisible' => array('input[name="disable_responsive_styles"]' => array('checked' => TRUE)), |
|
25 |
), |
|
26 |
); |
|
28 |
// MobileOptimized
|
|
29 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_mobileoptimized'] = array(
|
|
30 |
'#type' => 'textfield',
|
|
31 |
'#title' => t('MobileOptimized'),
|
|
32 |
'#default_value' => check_plain(at_get_setting('adaptivetheme_meta_mobileoptimized')),
|
|
33 |
'#states' => array(
|
|
34 |
'invisible' => array('input[name="disable_responsive_styles"]' => array('checked' => TRUE)),
|
|
35 |
),
|
|
36 |
);
|
|
27 | 37 |
|
28 |
// MobileOptimized
|
|
29 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_mobileoptimized'] = array(
|
|
30 |
'#type' => 'textfield', |
|
31 |
'#title' => t('MobileOptimized'),
|
|
32 |
'#default_value' => check_plain(at_get_setting('adaptivetheme_meta_mobileoptimized')),
|
|
33 |
'#states' => array( |
|
34 |
'invisible' => array('input[name="disable_responsive_styles"]' => array('checked' => TRUE)), |
|
35 |
), |
|
36 |
); |
|
38 |
// HandheldFriendly
|
|
39 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_handheldfriendly'] = array(
|
|
40 |
'#type' => 'textfield',
|
|
41 |
'#title' => t('HandheldFriendly'),
|
|
42 |
'#default_value' => check_plain(at_get_setting('adaptivetheme_meta_handheldfriendly')),
|
|
43 |
'#states' => array(
|
|
44 |
'invisible' => array('input[name="disable_responsive_styles"]' => array('checked' => TRUE)),
|
|
45 |
),
|
|
46 |
);
|
|
37 | 47 |
|
38 |
// HandheldFriendly |
|
39 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_handheldfriendly'] = array( |
|
40 |
'#type' => 'textfield', |
|
41 |
'#title' => t('HandheldFriendly'), |
|
42 |
'#default_value' => check_plain(at_get_setting('adaptivetheme_meta_handheldfriendly')), |
|
43 |
'#states' => array( |
|
44 |
'invisible' => array('input[name="disable_responsive_styles"]' => array('checked' => TRUE)), |
|
45 |
), |
|
46 |
); |
|
48 |
// apple-mobile-web-app-capable |
|
49 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_apple_mobile_web_app_capable'] = array( |
|
50 |
'#type' => 'textfield', |
|
51 |
'#title' => t('apple-mobile-web-app-capable'), |
|
52 |
'#default_value' => check_plain(at_get_setting('adaptivetheme_meta_apple_mobile_web_app_capable')), |
|
53 |
'#description' => t('See <a target="_blank" href="!webkithelp">http://developer.apple.com...</a>', array('!webkithelp' => 'http://developer.apple.com/library/safari/#documentation/AppleApplications/Reference/SafariHTMLRef/Articles/MetaTags.html')), |
|
54 |
'#states' => array( |
|
55 |
'invisible' => array('input[name="disable_responsive_styles"]' => array('checked' => TRUE)), |
|
56 |
), |
|
57 |
); |
|
47 | 58 |
|
48 |
// apple-mobile-web-app-capable |
|
49 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_apple_mobile_web_app_capable'] = array( |
|
50 |
'#type' => 'textfield', |
|
51 |
'#title' => t('apple-mobile-web-app-capable'), |
|
52 |
'#default_value' => check_plain(at_get_setting('adaptivetheme_meta_apple_mobile_web_app_capable')), |
|
53 |
'#states' => array( |
|
54 |
'invisible' => array('input[name="disable_responsive_styles"]' => array('checked' => TRUE)), |
|
55 |
), |
|
56 |
); |
|
59 |
// IE Document mode |
|
60 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_ie_document_mode'] = array( |
|
61 |
'#type' => 'textfield', |
|
62 |
'#title' => t('IE Document Mode'), |
|
63 |
'#default_value' => at_get_setting('adaptivetheme_meta_ie_document_mode'), |
|
64 |
'#description' => t('Use to set legacy document mode - often used to set IE-Edge, for example "IE=edge, chrome=1". See <a target="_blank" href="!mshelp">http://msdn.microsoft.com...</a>', array('!mshelp' => 'http://msdn.microsoft.com/en-us/library/jj676915(v=vs.85).aspx')), |
|
65 |
); |
|
57 | 66 |
|
58 |
// Chrome Edge |
|
59 |
$form['at-settings']['meta']['mobile']['chrome_edge'] = array( |
|
60 |
'#type' => 'checkbox', |
|
61 |
'#title' => t('Enable Chrome Edge support for IE'), |
|
62 |
'#default_value' => at_get_setting('chrome_edge'), |
|
63 |
); |
|
64 |
|
|
65 |
// Clear type |
|
66 |
$form['at-settings']['meta']['mobile']['clear_type'] = array( |
|
67 |
'#type' => 'checkbox', |
|
68 |
'#title' => t('Enable Cleartype in IE Mobile devices'), |
|
69 |
'#default_value' => at_get_setting('clear_type'), |
|
70 |
); |
|
67 |
// Clear type |
|
68 |
$form['at-settings']['meta']['mobile']['adaptivetheme_meta_clear_type'] = array( |
|
69 |
'#type' => 'checkbox', |
|
70 |
'#title' => t('Enable Cleartype in IE Mobile devices'), |
|
71 |
'#default_value' => at_get_setting('adaptivetheme_meta_clear_type'), |
|
72 |
); |
|
73 |
} |
Formats disponibles : Unified diff
Weekly update of contrib modules