1 | <?php |
||
26 | class Kirki extends Kirki_Init { |
||
27 | |||
28 | /** |
||
29 | * Absolute path to the Kirki folder. |
||
30 | * |
||
31 | * @static |
||
32 | * @access public |
||
33 | * @var string |
||
34 | */ |
||
35 | public static $path; |
||
36 | |||
37 | /** |
||
38 | * URL to the Kirki folder. |
||
39 | * |
||
40 | * @static |
||
41 | * @access public |
||
42 | * @var string |
||
43 | */ |
||
44 | public static $url; |
||
45 | |||
46 | /** |
||
47 | * An array containing all configurations. |
||
48 | * |
||
49 | * @static |
||
50 | * @access public |
||
51 | * @var array |
||
52 | */ |
||
53 | public static $config = array(); |
||
54 | |||
55 | /** |
||
56 | * An array containing all fields. |
||
57 | * |
||
58 | * @static |
||
59 | * @access public |
||
60 | * @var array |
||
61 | */ |
||
62 | public static $fields = array(); |
||
63 | |||
64 | /** |
||
65 | * An array containing all panels. |
||
66 | * |
||
67 | * @static |
||
68 | * @access public |
||
69 | * @var array |
||
70 | */ |
||
71 | public static $panels = array(); |
||
72 | |||
73 | /** |
||
74 | * An array containing all sections. |
||
75 | * |
||
76 | * @static |
||
77 | * @access public |
||
78 | * @var array |
||
79 | */ |
||
80 | public static $sections = array(); |
||
81 | |||
82 | /** |
||
83 | * Modules object. |
||
84 | * |
||
85 | * @access public |
||
86 | * @since 3.0.0 |
||
87 | * @var object |
||
88 | */ |
||
89 | public $modules; |
||
90 | |||
91 | /** |
||
92 | * Get the value of an option from the db. |
||
93 | * |
||
94 | * @static |
||
95 | * @access public |
||
96 | * @param string $config_id The ID of the configuration corresponding to this field. |
||
97 | * @param string $field_id The field_id (defined as 'settings' in the field arguments). |
||
98 | * @return mixed The saved value of the field. |
||
99 | */ |
||
100 | public static function get_option( $config_id = '', $field_id = '' ) { |
||
104 | |||
105 | /** |
||
106 | * Sets the configuration options. |
||
107 | * |
||
108 | * @static |
||
109 | * @access public |
||
110 | * @param string $config_id The configuration ID. |
||
111 | * @param array $args The configuration options. |
||
112 | */ |
||
113 | public static function add_config( $config_id, $args = array() ) { |
||
119 | |||
120 | /** |
||
121 | * Create a new panel. |
||
122 | * |
||
123 | * @static |
||
124 | * @access public |
||
125 | * @param string $id The ID for this panel. |
||
126 | * @param array $args The panel arguments. |
||
127 | */ |
||
128 | public static function add_panel( $id = '', $args = array() ) { |
||
141 | |||
142 | /** |
||
143 | * Create a new section. |
||
144 | * |
||
145 | * @static |
||
146 | * @access public |
||
147 | * @param string $id The ID for this section. |
||
148 | * @param array $args The section arguments. |
||
149 | */ |
||
150 | public static function add_section( $id, $args ) { |
||
164 | |||
165 | /** |
||
166 | * Create a new field. |
||
167 | * |
||
168 | * @static |
||
169 | * @access public |
||
170 | * @param string $config_id The configuration ID for this field. |
||
171 | * @param array $args The field arguments. |
||
172 | */ |
||
173 | public static function add_field( $config_id, $args ) { |
||
201 | |||
202 | /** |
||
203 | * Gets a parameter for a config-id. |
||
204 | * |
||
205 | * @static |
||
206 | * @access public |
||
207 | * @since 3.0.10 |
||
208 | * @param string $id The config-ID. |
||
209 | * @param string $param The parameter we want. |
||
210 | * @return string |
||
211 | */ |
||
212 | public static function get_config_param( $id, $param ) { |
||
219 | } |
||
220 |