GeoMashup
[ class tree: GeoMashup ] [ index: GeoMashup ] [ all elements ]

Source for file uninstall.php

Documentation is available at uninstall.php

  1. <?php
  2. /** 
  3.  * Geo Mashup uninstall procedure.
  4.  *
  5.  * @package GeoMashup
  6.  */
  7.  
  8. // Make sure this is a legitimate uninstall request
  9. ifdefined'ABSPATH'or defined('WP_UNINSTALL_PLUGIN'or current_user_can'delete_plugins' ) )
  10.     exit();
  11.  
  12. /**
  13.  * Drop Geo Mashup database tables.
  14.  * 
  15.  * @since 1.3
  16.  * @access public
  17.  */
  18.     global $wpdb;
  19.     $tables array'geo_mashup_administrative_names''geo_mashup_location_relationships''geo_mashup_locations' );
  20.     foreach$tables as $table {
  21.         $wpdb->query'DROP TABLE IF EXISTS ' $wpdb->prefix $table );
  22.     }
  23. }
  24.  
  25. /**
  26.  * Delete Geo Mashup saved options.
  27.  * 
  28.  * @since 1.3
  29.  * @access public
  30.  */
  31.     delete_option'geo_mashup_temp_kml_url' );
  32.     delete_option'geo_mashup_db_version' );
  33.     delete_option'geo_mashup_activation_log' );
  34.     delete_option'geo_mashup_options' );
  35.     delete_option'geo_locations' );
  36.     // Leave the google_api_key option 
  37.     // Still belongs to this site, and may be used by other plugins
  38. }
  39.  
  40. // I'm afraid to do this - started a trac ticket http://core.trac.wordpress.org/ticket/11850
  41. // geo_mashup_uninstall_db();
  42. ?>

Documentation generated on Sat, 09 Jul 2011 21:55:00 -0700 by phpDocumentor 1.4.3