PluginProbe
Simple Ticker / 1.02
Simple Ticker v1.02
trunk 1.0 1.01 1.02 1.03 1.04 1.05 1.06 1.07 2.00 2.01 2.02 2.03 2.04 2.05 2.06 2.07 2.08 2.09 2.10 2.11 3.00 3.01 3.02 3.03 All 33 releases
simple-ticker / uninstall.php

uninstall.php in Simple Ticker 1.02, at uninstall.php

32 lines 654 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 //if uninstall not called from WordPress exit
4 if ( !defined( 'WP_UNINSTALL_PLUGIN' ) )
5 exit();
6
7 $option_name = 'simple_ticker';
8
9 // For Single site
10 if ( !is_multisite() )
11 {
12 delete_option( $option_name );
13 }
14 // For Multisite
15 else
16 {
17 // For regular options.
18 global $wpdb;
19 $blog_ids = $wpdb->get_col( "SELECT blog_id FROM $wpdb->blogs" );
20 $original_blog_id = get_current_blog_id();
21 foreach ( $blog_ids as $blog_id )
22 {
23 switch_to_blog( $blog_id );
24 delete_option( $option_name );
25 }
26 switch_to_blog( $original_blog_id );
27
28 // For site options.
29 delete_site_option( $option_name );
30 }
31
32 ?>