PluginProbe ʕ •ᴥ•ʔ
Everest Forms – Contact Form, Payment Form, Quiz, Survey & Custom Form Builder with AI / 3.6.0
Everest Forms – Contact Form, Payment Form, Quiz, Survey & Custom Form Builder with AI v3.6.0
3.6.0 3.5.3 3.5.2 3.5.1 3.5.0 3.4.8 3.4.7 3.4.6 1.1.0 1.1.1 1.1.2 1.1.3 1.1.4 1.1.5 1.1.5.1 1.1.6 1.1.7 1.1.8 1.1.9 1.2.0 1.2.1 1.2.2 1.2.3 1.2.4 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.4.0 1.4.1 1.4.2 1.4.3 1.4.4 1.4.5 1.4.6 1.4.7 1.4.8 1.4.9 1.5.0 1.5.1 1.5.10 1.5.2 1.5.3 1.5.4 1.5.5 1.5.6 1.5.7 1.5.8 1.5.9 1.6.0 1.6.1 1.6.2 1.6.3 1.6.4 1.6.5 1.6.6 1.6.6.1 1.6.7 1.7.0 1.7.0.1 1.7.0.2 1.7.0.3 1.7.1 1.7.2 1.7.2.1 1.7.2.2 1.7.3 1.7.4 1.7.5 1.7.5.1 1.7.5.2 1.7.6 1.7.7 1.7.7.1 1.7.7.2 1.7.8 1.7.9 1.8.0 1.8.0.1 1.8.1 1.8.2 1.8.2.1 1.8.2.2 1.8.2.3 1.8.3 1.8.4 1.8.5 1.8.6 1.8.7 1.8.8 1.8.9 1.9.0 1.9.0.1 1.9.1 1.9.2 1.9.3 1.9.4 1.9.4.1 1.9.5 1.9.6 1.9.7 1.9.8 1.9.9 2.0.0 2.0.0.1 2.0.1 2.0.2 2.0.3 2.0.3.1 2.0.4 2.0.4.1 2.0.5 2.0.6 2.0.7 2.0.8 2.0.8.1 2.0.9 3.0.0 3.0.0.1 3.0.1 3.0.2 3.0.3 3.0.3.1 3.0.4 3.0.4.1 3.0.4.2 3.0.5 3.0.5.1 3.0.5.2 3.0.6 3.0.6.1 3.0.7.1 3.0.8 3.0.8.1 3.0.9 3.0.9.1 3.0.9.2 3.0.9.3 3.0.9.4 3.0.9.5 3.1.0 3.1.1 3.1.2 3.2.0 3.2.1 3.2.2 3.2.3 3.2.4 3.2.5 3.2.6 3.3.0 3.4.0 3.4.1 3.4.2 3.4.2.1 3.4.3 3.4.4 3.4.5 trunk 1.0 1.0.1 1.0.2 1.0.3
everest-forms / uninstall.php
everest-forms Last commit date
addons 1 day ago assets 1 day ago bin 6 months ago dist 1 day ago docs 1 month ago includes 1 day ago languages 1 day ago src 1 day ago templates 1 day ago traits 1 year ago vendor 1 month ago composer.json 6 months ago everest-forms.php 1 day ago license.txt 8 years ago readme.txt 1 day ago uninstall.php 3 years ago wp 1 year ago wpml-config.xml 5 years ago
uninstall.php
50 lines
1 <?php
2 /**
3 * EverestForms Uninstall
4 *
5 * Uninstalls the plugin deletes user roles, tables, and options.
6 *
7 * @package EverestForms\Uninstaller
8 * @version 1.0.0
9 */
10
11 defined( 'WP_UNINSTALL_PLUGIN' ) || exit;
12
13 global $wpdb;
14
15 wp_clear_scheduled_hook( 'everest_forms_cleanup_logs' );
16 wp_clear_scheduled_hook( 'everest_forms_cleanup_sessions' );
17
18 /*
19 * Only remove ALL data if EVF_REMOVE_ALL_DATA constant is set to true in user's
20 * wp-config.php. This is to prevent data loss when deleting the plugin from the backend
21 * and to ensure only the site owner can perform this action.
22 */
23 if ( ( defined( 'EVF_REMOVE_ALL_DATA' ) && true === EVF_REMOVE_ALL_DATA ) || 'yes' === get_option( 'everest_forms_uninstall_option' ) ) {
24 include_once dirname( __FILE__ ) . '/includes/class-evf-install.php';
25
26 // Roles + caps.
27 EVF_Install::remove_roles();
28
29 // Tables.
30 EVF_Install::drop_tables();
31
32 // Pages.
33 wp_trash_post( get_option( 'everest_forms_default_form_page_id' ) );
34
35 // Delete options.
36 $wpdb->query( "DELETE FROM $wpdb->options WHERE option_name LIKE 'evf\_%';" );
37 $wpdb->query( "DELETE FROM $wpdb->options WHERE option_name LIKE 'everest_forms\_%';" );
38
39 // Delete usermeta.
40 $wpdb->query( "DELETE FROM $wpdb->usermeta WHERE meta_key LIKE 'evf\_%';" );
41 $wpdb->query( "DELETE FROM $wpdb->usermeta WHERE meta_key LIKE 'everest_forms\_%';" );
42
43 // Delete posts + data.
44 $wpdb->query( "DELETE FROM {$wpdb->posts} WHERE post_type IN ( 'everest_form' );" );
45 $wpdb->query( "DELETE meta FROM {$wpdb->postmeta} meta LEFT JOIN {$wpdb->posts} posts ON posts.ID = meta.post_id WHERE posts.ID IS NULL;" );
46
47 // Clear any cached data that has been removed.
48 wp_cache_flush();
49 }
50