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

// File to upgrade Esvon Classifieds from 3.0.787 to 3.0.788
// 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_PAY_PEND." ADD ip varchar(30) NOT NULL");

mysql_query("ALTER TABLE ".TBL_AD." ADD ip varchar(30) NOT NULL");

mysql_query("ALTER TABLE ".TBL_USER." ADD reg_ip varchar(30) NOT NULL");

mysql_query("ALTER TABLE ".TBL_PAY_LOG." ADD ip varchar(30) NOT NULL");

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

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

if(hwModGetState('Banner_Ads')){
  mysql_query("ALTER TABLE ".hwModTable('Banner_Ads','banner')." CHANGE cid cid TEXT NOT NULL");
}

$f_ok = 0; 
// FS Options changed ?
$A_OPT = array(
  'THUMB_MAX' => 4,
);

foreach($A_OPT as $k=>$v){
  foreach(array_keys($O_HW->A_OPT['HW_FSET']) as $fs){
    if(!isset($O_HW->A_OPT['HW_FSET'][$fs][$k])){ $O_HW->A_OPT['HW_FSET'][$fs][$k] = $v; $f_ok = 1; }
  }
}
if($f_ok) $O_HW->UpdateDB();

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


?>
Return current item: Esvon Personals