HEX
Server: Apache/2.4.49 (FreeBSD) OpenSSL/1.0.2s-freebsd PHP/5.6.36
System: FreeBSD hosting.icon.bg 11.3-RELEASE-p13 FreeBSD 11.3-RELEASE-p13 #0: Tue Sep 1 06:56:51 UTC 2020 root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64
User: ftpuser (1002)
PHP: 5.6.36
Disabled: NONE
Upload Files
File: /hosting/kak.bg/web/wp-content/plugins/yendif-player/includes/uninstall.php
<?php
/**
 * @package   Yendif Player
 * @author    Yendif Technologies Pvt Ltd. (email : admin@yendifplayer.com)
 * @license   GPL-2.0+
 * @link      http://yendifplayer.com/
 * @copyright 2014 Yendif Technologies Pvt Ltd.
 */

class Yendif_Player_Uninstall {

	/**
	 * Constructor of this class.
	 *
	 * @since     1.0.0
	 */
	private function __construct() {

	}
	
	/**
	 * Called when the plugin is deactivated.
	 *
	 * @since    1.0.0
	 */
	public static function deactivate() {

	}
	
	/**
	 * Called when the plugin is uninstalled.
	 *
	 * @since    1.0.0
	 */
	public static function uninstall() {
	
		global $wpdb;

		// Delete videopage post type
		$wpdb->query( 'DELETE FROM ' . $wpdb->prefix . 'posts WHERE post_type="videopage"' );
		
		// Delete playlist post type
		$wpdb->query( 'DELETE FROM ' . $wpdb->prefix . 'posts WHERE post_type="videoplaylist"' );
		
		// Delete settings table if exists
		$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'yendif_player_settings' );
	
		// Delete videos table if exists
		$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'yendif_player_media' );
		
		// Delete playlists table if exists
		$wpdb->query( 'DROP TABLE IF EXISTS ' . $wpdb->prefix . 'yendif_player_playlists' );
	
		// Delete options value if exists
		delete_option( YENDIF_PLAYER_VERSION_KEY, YENDIF_PLAYER_VERSION_NUM );
	
	}

}