Changeset 95
- Timestamp:
- 02/21/06 23:36:53 (3 years ago)
- Files:
-
- bureau/class/m_mysql.php (modified) (4 diffs)
- bureau/class/m_quota.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
bureau/class/m_mysql.php
r94 r95 1 1 <?php 2 2 /* 3 $Id: m_mysql.php,v 1. 8 2003/06/09 20:01:40 root Exp $3 $Id: m_mysql.php,v 1.9 2003/06/09 20:13:40 root Exp $ 4 4 ---------------------------------------------------------------------- 5 5 AlternC - Web Hosting System … … 266 266 *****************************************************************************/ 267 267 function new_mysql($password) { 268 global $db,$err,$mem ;268 global $db,$err,$mem,$quota; 269 269 $err->log("mysql","new_mysql"); 270 270 if (strlen($password)>16) { … … 285 285 exec("/usr/lib/alternc/db_create ".$this->uid." /var/alternc/db/".$mem->user["login"]); 286 286 $db->query("FLUSH PRIVILEGES;"); 287 $quota->inc("mysql"); 287 288 return true; 288 289 } … … 307 308 } 308 309 310 function alternc_quota_check($id) { 311 global $err,$quota; 312 $err->log("mysql","alternc_quota_check"); 313 $c=$this->get_dblist($id); 314 if (is_array($c)) { 315 $quota->setquota("mysql",count($c),1,$id); 316 } else { 317 $quota->setquota("mysql",0,1,$id); 318 } 319 return true; 320 } 321 309 322 function alternc_del_member($id) { 310 323 global $db,$err; 311 $err->log("mysql"," del_member");324 $err->log("mysql","alternc_del_member"); 312 325 $c=$this->get_dblist($id); 313 326 if (is_array($c)) { bureau/class/m_quota.php
r94 r95 1 1 <?php 2 2 /* 3 $Id: m_quota.php,v 1. 3 2003/06/09 20:01:40 root Exp $3 $Id: m_quota.php,v 1.4 2003/06/09 20:13:40 root Exp $ 4 4 ---------------------------------------------------------------------- 5 5 AlternC - Web Hosting System … … 175 175 /*****************************************************************************/ 176 176 function checkquota($id=-1) { 177 global $err ;177 global $err,$classes; 178 178 $err->log("quota","checkquota",$id); 179 179 if ($id==-1) $id=$this->uid; … … 181 181 for($i=0;$i<count($classes);$i++) { 182 182 if (method_exists($GLOBALS[$classes[$i]],"alternc_quota_check")) { 183 $GLOBALS[$classes[$i]]->alternc_quota_check($ uid);183 $GLOBALS[$classes[$i]]->alternc_quota_check($id); 184 184 } 185 185 }
