Location: PHPKode > projects > Esvon Personals > esvon-personals/upgrades/v3_to_v4/upgrade300-301.php
<?php

// File to upgrade Esvon Classifieds from 3.0 to 3.0.2
// After use this, you can delete it

//*********************************************

define('DB_UPGRADE', 1);

if(!defined('SITE_PATH')){
  if(!file_exists('./inc/application.php')) die("File Not Found: application.php");
  require_once './inc/application.php';
}
 
mysql_query("ALTER TABLE ".TBL_AD." ADD v_zip varchar(255) NOT NULL");

mysql_query("ALTER TABLE ".TBL_AD." ADD hw_color varchar(255) NOT NULL");

mysql_query("INSERT INTO ".TBL_RESERV_FLD." VALUES ('hw_color', 'A')");

mysql_query("ALTER TABLE ".TBL_USER." ADD hw_sid varchar(32) NOT NULL");

mysql_query("INSERT INTO ".TBL_RESERV_FLD." VALUES ('hw_sid', 'U')");

mysql_query("ALTER TABLE ".TBL_USER." add v_255_12 varchar(255) NOT NULL");

mysql_query("ALTER TABLE ".TBL_AD." ADD user_approved tinyint(3) DEFAULT '1' NOT NULL");

mysql_query("UPDATE ".TBL_AD." SET user_approved='1'");

mysql_query("INSERT INTO ".TBL_RESERV_FLD." VALUES ('user_approved', 'A')");

echo 'Esvon Classifieds Tables Updated, Ok.. ('.basename(__FILE__).')';

?>
Return current item: Esvon Personals