-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy paththeme-settings.php
More file actions
58 lines (53 loc) · 1.76 KB
/
theme-settings.php
File metadata and controls
58 lines (53 loc) · 1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<?php
// $Id$
/**
* Implementation of THEMEHOOK_settings() function.
*
* @param $saved_settings
* array An array of saved settings for this theme.
* @return
* array A form array.
*/
function iwebkit_settings($saved_settings) {
// Set the default values for the theme variables
$defaults = array(
'iwebkit_theme' => 'default',
'iwebkit_menu_type' => 'popup',
);
// Merge the variables and their default values
$settings = array_merge($defaults, $saved_settings);
// Layout Type
$form['iwebkit_theme'] = array(
'#type' => 'select',
'#title' => t('Theme Type'),
'#default_value' => $settings['iwebkit_theme'],
'#options' => array(
'default' => t('Default'),
'black' => t('Black'),
'blue' => t('Blue'),
'brown' => t('Brown'),
'cyan' => t('Cyan'),
'gray' => t('Gray'),
'green' => t('Green'),
'olive' => t('Olive'),
'orange' => t('Orange'),
'pink' => t('Pink'),
'purple' => t('Purple'),
'red' => t('Red'),
'yellow' => t('Yellow'),
),
'#description' => t('This will determine the colour and appearance of your iPhone theme.'),
);
$form['iwebkit_menu_type'] = array(
'#type' => 'select',
'#title' => t('Primary Menu Layout'),
'#default_value' => $settings['iwebkit_menu_type'],
'#description' => t('Choose type of primary menu iwebkit theme should show.'),
'#options' => array(
'popup' => t('Popup menu - a button on top-bar right'),
'normal-every' => t('Normal list of menu appearing in page region - On every page'),
'normal-front' => t('Normal list of menu appearing in page region - On front page'),
),
);
return $form;
}