admin-menu-items
4 months ago
admin-menu-app.php
2 years ago
ajax.php
7 months ago
module.php
5 months ago
options.php
2 years ago
options.php
22 lines
| 1 | <?php |
| 2 | namespace Elementor\Modules\ElementManager; |
| 3 | |
| 4 | if ( ! defined( 'ABSPATH' ) ) { |
| 5 | exit; // Exit if accessed directly. |
| 6 | } |
| 7 | |
| 8 | class Options { |
| 9 | |
| 10 | public static function get_disabled_elements() { |
| 11 | return (array) get_option( 'elementor_disabled_elements', [] ); |
| 12 | } |
| 13 | |
| 14 | public static function update_disabled_elements( $elements ) { |
| 15 | update_option( 'elementor_disabled_elements', (array) $elements ); |
| 16 | } |
| 17 | |
| 18 | public static function is_element_disabled( $element_name ) { |
| 19 | return in_array( $element_name, self::get_disabled_elements() ); |
| 20 | } |
| 21 | } |
| 22 |