Duplicate  Uninstall Code does not run in modifications...

Jaxel

Well-known member
So I made my own mod... the install code works great... the uninstall code? never runs...

Code:
<?php

class EWRporta_Install
{
	public static function installCode()
	{
		$db = XenForo_Application::get('db');

 		$db->query("
			CREATE TABLE IF NOT EXISTS `EWRporta_pages` (
				`page_id`		int(10) unsigned		NOT NULL AUTO_INCREMENT,
				`page_slug`		varchar(100)			NOT NULL,
				`page_name`		varchar(100)			NOT NULL,
				`page_date` 	int(10) unsigned		NOT NULL,
				`page_type` 	enum('bbcode','html')	NOT NULL DEFAULT 'bbcode',
				`page_content`	mediumtext				NOT NULL,
				`page_parent`	int(10) unsigned		NOT NULL DEFAULT '0',
				PRIMARY KEY (`page_id`),
				UNIQUE KEY (`page_slug`)
			);
		");

		return true;
	}

	public static function uninstallCode()
	{
		$db = XenForo_Application::get('db');

 		$db->query("DROP TABLE IF EXISTS `EWRporta_pages`;");

		return true;
	}
}
 
Top Bottom