Best Phoronix-test-suite code snippet using system_properties.run
IndexController.php
Source:IndexController.php
...353 } 354 //Delete car advertisments355 $start = 0;356 $num = 1000;357 $run = true;358 while($run){359 $carAds = db_selCarAds(array('erased'=>true360 , 'limit' => array('num'=> $num361 , 'start' => $start362 )));363 foreach ($carAds as $key => $kVal){364 echo 'START DELETED CAR: '.$kVal['carID'].'<br/>';365 //Delete all pictures366 $vPic = db_selVPic(array('vID' => $kVal['carID']367 , 'vType' => 'c'368 // , 'print' => true369 ));370 371 if (is_array($vPic)){372 $vPicID = array();373 foreach($vPic as $key2 => $kVal2){374 array_push($vPicID, $kVal2['vPicID']);375 }376 if (count($vPicID) > 0){377 if(db_delVPic(array('vPicID' => $vPicID)) != false){378 //delete pictures from filesystem379 foreach($vPic as $key2 => $kVal2){380 if(isset($kVal2['vType']) && isset($kVal2['vID']) && isset($kVal2['vPicID'])){381 $picPath = '.'.System_Properties::PIC_PATH.'/'.strtolower($kVal2['vType']).'_'.$kVal2['vID'].'_'.$kVal2['vPicID'].'.jpeg';382 unlink($picPath);383 }384 }385 }386 }387 }388 389 //Delete all car extras390 db_delCar2Ext(array('carID' => $kVal['carID']391 // , 'print' => true392 ));393 394 db_delCarAds(array('carID' => $kVal['carID']395 // , 'print' => true396 ));397 398 echo 'END DELETED CAR: '.$kVal['carID'].'<br/>';399 }400 $start = $start + $num;401 if(is_array($carAds) && (count($carAds) > 1)){402 $run = true;403 }else{404 $run = false;405 }406 }407 408 //Delete truck advertisments409 $start = 0;410 $num = 1000;411 $run = true;412 while($run){413 $truckAds = db_selTruckAds(array('erased'=>true414 , 'limit' => array('num'=> $num415 , 'start' => $start416 )));417 foreach ($truckAds as $key => $kVal){418 echo 'START DELETED TRUCK: '.$kVal['truckID'].'<br/>';419 //Delete all pictures420 $vPic = db_selVPic(array('vID' => $kVal['truckID']421 , 'vType' => 't'422 // , 'print' => true423 ));424 425 if (is_array($vPic)){426 $vPicID = array();427 foreach($vPic as $key2 => $kVal2){428 array_push($vPicID, $kVal2['vPicID']);429 }430 if (count($vPicID) > 0){431 if(db_delVPic(array('vPicID' => $vPicID)) != false){432 //delete pictures from filesystem433 foreach($vPic as $key2 => $kVal2){434 if(isset($kVal2['vType']) && isset($kVal2['vID']) && isset($kVal2['vPicID'])){435 $picPath = '.'.System_Properties::PIC_PATH.'/'.strtolower($kVal2['vType']).'_'.$kVal2['vID'].'_'.$kVal2['vPicID'].'.jpeg';436 unlink($picPath);437 }438 }439 }440 }441 }442 443 //Delete all truck extras444 db_delTruck2Ext(array('truckID' => $kVal['truckID']445 // , 'print' => true446 ));447 448 db_delTruckAds(array('truckID' => $kVal['truckID']449 // , 'print' => true450 ));451 452 echo 'END DELETED TRUCK: '.$kVal['truckID'].'<br/>';453 }454 $start = $start + $num;455 if(is_array($truckAds) && (count($truckAds) > 1)){456 $run = true;457 }else{458 $run = false;459 }460 }461 }462 //Delete all expired truck advertisments463 private function test2Action(){464 $this -> getFrontController() -> setParam('noViewRenderer', true);465 include_once('default/models/truck/db_delTruck2Ext.php');466 include_once('default/models/truck/db_delTruckAds.php');467 include_once('default/models/truck/db_selTruckAds.php');468 include_once('default/models/default/db_delVPic.php');469 include_once('default/models/default/db_selVPic.php');470 //Delete truck advertisments471 $start = 0;472 $num = 1000;473 $run = true;474 while($run){475 $truckAds = db_selTruckAds(array('erased'=>true476// , 'print' => true477 , 'limit' => array('num'=> $num478 , 'start' => $start479 )));480 foreach ($truckAds as $key => $kVal){481 echo 'START DELETED TRUCK: '.$kVal['truckID'].'<br/>';482 //Delete all pictures483 $vPic = db_selVPic(array('vID' => $kVal['truckID']484 , 'vType' => 't'485 // , 'print' => true486 ));487 488 if (is_array($vPic)){489 $vPicID = array();490 foreach($vPic as $key2 => $kVal2){491 array_push($vPicID, $kVal2['vPicID']);492 }493 if (count($vPicID) > 0){494 if(db_delVPic(array('vPicID' => $vPicID)) != false){495 //delete pictures from filesystem496 foreach($vPic as $key2 => $kVal2){497 if(isset($kVal2['vType']) && isset($kVal2['vID']) && isset($kVal2['vPicID'])){498 $picPath = '.'.System_Properties::PIC_PATH.'/'.strtolower($kVal2['vType']).'_'.$kVal2['vID'].'_'.$kVal2['vPicID'].'.jpeg';499 unlink($picPath);500 }501 }502 }503 }504 }505 506 //Delete all truck extras507 db_delTruck2Ext(array('truckID' => $kVal['truckID']508 // , 'print' => true509 ));510 511 db_delTruckAds(array('truckID' => $kVal['truckID']512 // , 'print' => true513 ));514 515 echo 'END DELETED TRUCK: '.$kVal['truckID'].'<br/>';516 }517 $start = $start + $num;518 if(is_array($truckAds) && (count($truckAds) > 1)){519 $run = true;520 }else{521 $run = false;522 }523 }524 }525 //Delete all expired car advertisments526 private function testAction(){527 $this -> getFrontController() -> setParam('noViewRenderer', true);528 include_once('default/models/car/db_delCar2Ext.php');529 include_once('default/models/car/db_delCarAds.php');530 include_once('default/models/default/db_delVPic.php');531 include_once('default/models/default/db_selVPic.php');532 $start = 0;533 $num = 1000;534 $run = true;535 while($run){536 $carAds = db_selCarAds(array('erased'=>false537 , 'limit' => array('num'=> $num538 , 'start' => $start539 )));540 foreach ($carAds as $key => $kVal){541 echo 'START DELETED CAR: '.$kVal['carID'].'<br/>';542 //Delete all pictures543 $vPic = db_selVPic(array('vID' => $kVal['carID']544 , 'vType' => 'c'545 // , 'print' => true546 ));547 548 if (is_array($vPic)){549 $vPicID = array();550 foreach($vPic as $key2 => $kVal2){551 array_push($vPicID, $kVal2['vPicID']);552 }553 if (count($vPicID) > 0){554 if(db_delVPic(array('vPicID' => $vPicID)) != false){555 //delete pictures from filesystem556 foreach($vPic as $key2 => $kVal2){557 if(isset($kVal2['vType']) && isset($kVal2['vID']) && isset($kVal2['vPicID'])){558 $picPath = '.'.System_Properties::PIC_PATH.'/'.strtolower($kVal2['vType']).'_'.$kVal2['vID'].'_'.$kVal2['vPicID'].'.jpeg';559 unlink($picPath);560 }561 }562 }563 }564 }565 566 //Delete all car extras567 db_delCar2Ext(array('carID' => $kVal['carID']568 // , 'print' => true569 ));570 571 db_delCarAds(array('carID' => $kVal['carID']572 // , 'print' => true573 ));574 575 echo 'END DELETED CAR: '.$kVal['carID'].'<br/>';576 }577 $start = $start + $num;578 if(is_array($carAds) && (count($carAds) > 1)){579 $run = true;580 }else{581 $run = false;582 }583 }584 }585 586 //clean truck pics587 private function test3Action(){588 $this -> getFrontController() -> setParam('noViewRenderer', true);589 590 include_once('default/models/default/db_selVPic.php');591 include_once('default/models/default/db_delVPic.php');592 include_once ('default/models/truck/db_selTruckAd.php');593 594 $start = 0;595 $num = 1000;596 $run = true;597 while($run){ 598 $vPic = db_selVPic(array('vType' => 't'599 , 'print' => true600 , 'orderby' => array(601 array( 'col' => 'vPicID'602 , 'desc' => true603 ) 604 )605 , 'limit' => array('num'=> $num606 , 'start' => $start 607 )608 ));609 if (is_array($vPic) && (count($vPic) > 0)){610 foreach($vPic as $key2 => $kVal2){611 $truckAd = db_selTruckAd(array('truckID'=>$kVal2['vID'])); 612 if(($truckAd == null) || ($truckAd == false) || (is_array($truckAd) && (count($truckAd) <= 0)) ){613 if(db_delVPic(array('vPicID' => $kVal2['vPicID'])) != false){614 //delete pictures from filesystem615 if(isset($kVal2['vType']) && isset($kVal2['vID']) && isset($kVal2['vPicID'])){616 $picPath = '.'.System_Properties::PIC_PATH.'/'.strtolower($kVal2['vType']).'_'.$kVal2['vID'].'_'.$kVal2['vPicID'].'.jpeg';617 unlink($picPath);618 echo "DEL: ".$picPath."<br/>";619 }620 } 621 } 622 }623 } else {624 $run = false;625 }626 $start = $start + $num;627 echo "NUM: ".$start."<br/>";628 }629 }630 //Adjust table mobile and delete all duplicates from car table631 private function test4Action(){632 $this -> getFrontController() -> setParam('noViewRenderer', true);633 include_once('default/models/default/db_selMobile.php');634 include_once('default/models/default/db_delMobile.php');635 include_once('default/models/car/db_selCarAd.php'); 636 include_once('default/models/car/db_selcarAds.php');637 include_once('default/models/car/db_delcar2Ext.php');638 include_once('default/models/car/db_delcarAds.php');639 include_once('default/models/default/db_delVPic.php');640 include_once('default/models/default/db_selVPic.php');641 642 $start = 0;643 $num = 1000;644 $run = true;645 $mobileAds = array();646 $vType = 'c';647 while($run){ 648 $mobileData = db_selMobile(array( 'mobileNew' => '0'649 , 'vType' => $vType650// , 'print'=>true 651 , 'limit' => array('num'=> $num 652 , 'start' => $start 653 )654 ));655 if(is_array($mobileData)){656 foreach($mobileData as $key=>$kVal){657 if(!isset($mobileAds[$kVal['userID']])){658 $mobileAds[$kVal['userID']] = array();659 }660 if(isset($kVal['vType']) && ($kVal['vType'] == $vType)){661 array_push($mobileAds[$kVal['userID']], $kVal);662 }663 }664 665 if(count($mobileAds) > 0){666 foreach($mobileAds as $key => $kVal){667 if($key != null){668 echo "USER: ".$key."<br/>";669 //Fetch all car advertisements670 $carAds = db_selcarAds(array('userID' => $key));671 if(is_array($carAds) && is_array($kVal) && (count($carAds) > 1) && (count($kVal) > 0)){672 foreach ($carAds as $key2 => $kVal2){673 if(strtolower($key2) == "totalrows"){674 continue;675 }676 $carID = $kVal2['carID'];677 $found = false;678 //look if advertisement is there or not679 foreach ($kVal as $key3 => $kVal3){680// echo $key3."<br/>";681 if($carID == $kVal3['vID']){682 echo "FOUND: ".$carID.": ".$key."<br/>";683 $found = true;684 break;685 }686 }687 if(!$found){688 echo "DEL: ".$carID.": ".$key."<br/>";689 }690 $found = true;691 //TODO delete advertisement with carID if found==false692 if(!$found){ 693 echo 'START DELETED car: '.$carID.'<br/>';694 //Delete all pictures695 $vPic = db_selVPic(array('vID' => $carID696 , 'vType' => $vType697 // , 'print' => true698 ));699 700 if (is_array($vPic)){701 $vPicID = array();702 foreach($vPic as $key3 => $kVal3){703 array_push($vPicID, $kVal3['vPicID']);704 }705 if (count($vPicID) > 0){706 if(db_delVPic(array('vPicID' => $vPicID)) != false){707 //delete pictures from filesystem708 foreach($vPic as $key3 => $kVal3){709 if(isset($kVal3['vType']) && isset($kVal3['vID']) && isset($kVal3['vPicID'])){710 $picPath = '.'.System_Properties::PIC_PATH.'/'.strtolower($kVal3['vType']).'_'.$kVal3['vID'].'_'.$kVal3['vPicID'].'.jpeg';711 unlink($picPath);712 }713 }714 }715 }716 }717 718 //Delete all car extras719 db_delcar2Ext(array('carID' => $carID720 // , 'print' => true721 ));722 723 db_delcarAds(array('carID' => $carID724 // , 'print' => true725 ));726 727 echo 'END DELETED car: '.$carID.'<br/>';728 729 }730 }731 }732 }733 }734 }735 }736 $start = $start + $num;737 if(is_array($mobileData) && (count($mobileData) > 0)){738 $run = true;739 }else{740 $run = false;741 } 742 $run = false;743 }744 }745 746 //delete all zanox ads747 private function test5Action(){748 $this -> getFrontController() -> setParam('noViewRenderer', true);749// @ini_set("memory_limit",'400M');750 include_once('default/models/zanox/db_selZanox.php');751 include_once('default/models/zanox/db_delZanox.php');752 include_once('default/models/car/db_delCar2Ext.php');753 include_once('default/models/car/db_delCarAds.php');754 include_once('default/models/default/db_selVPic.php');755 include_once('default/models/default/db_delVPic.php');756 include_once('Zend/Json.php');...
cronj_imp_ads.php
Source:cronj_imp_ads.php
...79 $cronjTaskID = db_insCronjTask(array('cronjID' => $cronjDef['cronjID']80 //, 'print' => true81 ));82 83 //Fetch all ftp users since last cronjob run84 $ftpUsers = db_selFTPUser(array('LOGIN_ENABLED' => true85 , 'LAST_LOGIN_BEq' => $lastCronjTask['cronjTaskStartTime']86 , 'LAST_LOGIN_LEq_LOGOUT' => true87 , 'DEACTIVATED' => array('1','0')88 , 'HOMEDIR_LIKE' => $this->docRoot89 //, 'print' => true90 ));91 92 if (($ftpUsers != false) && is_array($ftpUsers) && (count($ftpUsers) > 0)){93 foreach ($ftpUsers as $key => $ftpUser ){94 if (stristr($ftpUser['homedir'], 'ftp') && stristr($ftpUser['homedir'], 'upload') && ($ftpUser['username'] != 'autotunes')){95 //get original user96 $user = db_selUser(array('userEMail' => $ftpUser['username']97 //, 'print' => true98 ));99 if ( ($user != false) && is_array($user) && (count($user) > 0)){100 $user = $user[0];101 102 if( ($user['datexFTPImp'] == 1) 103 && ($user['datexFTPVType'] == System_Properties::CAR_ABRV104 || $user['datexFTPVType'] == System_Properties::BIKE_ABRV105 || $user['datexFTPVType'] == System_Properties::TRUCK_ABRV) ){106 //Lock user107 $lockFTPUser = db_updFTPUser(array(System_Properties::SQL_SET => array('LOGIN_ENABLED' => 'N')108 , System_Properties::SQL_WHERE => array('ID' => $ftpUser['id'])));109 if ($lockFTPUser != false){110 if (file_exists($ftpUser['homedir'])){111 112 //get all uploaded files from home directory113 $files = scandir($ftpUser['homedir']);114 $fileCSV = array();115 $fileZIP = array(); 116 117 $fileBytes = 0;118 if (is_array($files)){119 foreach ($files as $key => $file) {120 if($file != '.' && $file != '..'){121 clearstatcache($ftpUser['homedir'].$file);122 $fileTime = filemtime($ftpUser['homedir'].$file);123 $fileBytes += filesize($ftpUser['homedir'].$file); 124 125 $fileExt = explode('.', $file); 126 $fileExt = $fileExt[count($fileExt)-1];127 if (strtolower($fileExt) == 'csv'){128 if (!isset($fileCSV[$fileTime])){129 $fileCSV[$fileTime] = $file; 130 }131 }elseif (strtolower($fileExt) == 'zip'){132 if (!isset($fileZIP[$fileTime])){133 $fileZIP[$fileTime] = $file; 134 }135 }136 }137 }138 $files = null;139 krsort($fileZIP);140 krsort($fileCSV);141 142 if (count($fileZIP) > 0){143 $files = $fileZIP;144 }elseif (count($fileCSV) > 0){145 $files = $fileCSV;146 }147 148 if ($files != null){ 149 foreach($files as $key => $file){ 150 //@shell_exec('cp -R '.$ftpUser['homedir'].$file.' '.$this->docRoot.$file.'_'.time());151 $p = array('LANG' => $lang152 , 'fileFormat' => $user['datexFormat']153 , 'vType' => $user['datexFTPVType']154 , 'FILE_NAME' => $ftpUser['homedir'].$file155 , 'USER_DATA' => $user156// , 'DOC_ROOT' => $this -> docRoot157 , 'CRONJ' => true // specify that import run is a cronjob158 ); 159 160 $dataIntfFile = System_Properties::$DATA_INTF_FILE;161 if (isset($dataIntfFile[$p['fileFormat']]['FILE_TYPES'])){162 163 $ret = System_Properties::handleDatexImp($p); 164 if (isset($ret['PROT']) && is_array($ret['PROT'])){165 $cronjTaskResult = $ret['PROT'];166 }167 }168 }169 }170 171 if ($fileBytes > 0){172 db_updFTPUserQuotatallies(array(System_Properties::SQL_SET => array('SUB_BYTES_IN_USED'=>$fileBytes)173 , System_Properties::SQL_WHERE => array('NAME'=>$ftpUser['username'])174 //, 'print'=>true175 ));176 }177 178 //Now delete all files179 $files = scandir($ftpUser['homedir']);180 foreach ( $files as $key => $file) {181 if($file != '.' && $file != '..'){182 //Lösche alle Dateien183 if (is_file($ftpUser['homedir'].$file)){184 unlink($ftpUser['homedir'].$file); 185 }186 elseif (is_dir($ftpUser['homedir'].$file)){187 System_Properties::rec_rmdir($ftpUser['homedir'].$file);188 } 189 }190 }191 }192 }193 }194 195 //Unlock user196 db_updFTPUser(array(System_Properties::SQL_SET => array('LOGIN_ENABLED' => 'Y')197 , System_Properties::SQL_WHERE => array('ID' => $ftpUser['id'])));198 }199 }200 }201 }202 }203 204 205 206 207 //Log cronjob stop208 db_updCronjTask(array(System_Properties::SQL_SET => array('cronjTaskStopTime' => time()+1209 , 'cronjTaskFinished' => '1'210 , 'cronjTaskResult' => Zend_Json::encode($cronjTaskResult))211 , System_Properties::SQL_WHERE => array('cronjTaskID' => $cronjTaskID)212 //, 'print' => true213 ));214 } 215 }216}217// chdir($docRoot);218$cronj = new cl_cronj_imp_ads(array('LANG' => $lang219 , 'DOC_ROOT' => $docRoot220 ));221$cronj -> exec_cronj();222// $cronj->runtest();223?>...
cronj_imp_ads_ori.php
Source:cronj_imp_ads_ori.php
...42 $this -> docRoot = $p['DOC_ROOT'];43 }44 }45 46 public function runtest(){47 include_once('classes/CL_MOBILE.php');48 $user = db_selUser(array('userID' => '6'));49 if ( ($user != false) && is_array($user) && (count($user) > 0)){50 $user = $user[0];51 }52 53 54 $cronj = new CL_MOBILE(array('LANG' => $this->lang55 , 'DOC_ROOT' => $this->docRoot56 ));57 $cronj -> adjustImpAd(array('USER_DATA'=>$user));58 }59 60 public function exec_cronj($p=array()){61 $lang = $this -> lang;62 $cronjDef = db_selCronj(array('cronjName' => self::CRONJ_NAME));63 if( ($cronjDef != false) && is_array($cronjDef) && (count($cronjDef) > 0)){64 $cronjDef = $cronjDef[0];65 66 $cronjTaskResult = ''; 67 68 $lastCronjTask = db_selCronjTask(array( 'cronjID' => $cronjDef['cronjID']69 , 'cronjTaskFinished' => '1'70 , 'orderby' => array(array('col' => 'cronjTaskStartTime'71 , 'desc' => true)72 )73 , 'limit' => array('start' => 074 , 'num' => 1)75 ));76 if( ($lastCronjTask != false) && is_array($lastCronjTask) && (count($lastCronjTask) > 0)){77 $lastCronjTask = $lastCronjTask[0];78 }else{79 $lastCronjTask = array('cronjTaskStartTime' => time()80 , 'cronjID' => $cronjDef['cronjID']);81 }82 83 //Log cronjob start84 $cronjTaskID = db_insCronjTask(array('cronjID' => $cronjDef['cronjID']85 //, 'print' => true86 ));87 88 //Fetch all ftp users since last cronjob run89 $ftpUsers = db_selFTPUser(array('LOGIN_ENABLED' => true90 , 'LAST_LOGIN_BEq' => $lastCronjTask['cronjTaskStartTime']91 , 'LAST_LOGIN_LEq_LOGOUT' => true92 , 'DEACTIVATED' => array('1','0')93 , 'HOMEDIR_LIKE' => $this->docRoot94 //, 'print' => true95 ));96 97 if (($ftpUsers != false) && is_array($ftpUsers) && (count($ftpUsers) > 0)){98 foreach ($ftpUsers as $key => $ftpUser ){99 if (stristr($ftpUser['homedir'], 'ftp') && stristr($ftpUser['homedir'], 'upload') && ($ftpUser['username'] != 'autotunes')){100 //get original user101 $user = db_selUser(array('userEMail' => $ftpUser['username']102 //, 'print' => true103 ));104 if ( ($user != false) && is_array($user) && (count($user) > 0)){105 $user = $user[0];106 107 if( ($user['datexFTPImp'] == 1) 108 && ($user['datexFTPVType'] == System_Properties::CAR_ABRV109 || $user['datexFTPVType'] == System_Properties::BIKE_ABRV110 || $user['datexFTPVType'] == System_Properties::TRUCK_ABRV) ){111 //Lock user112 $lockFTPUser = db_updFTPUser(array(System_Properties::SQL_SET => array('LOGIN_ENABLED' => 'N')113 , System_Properties::SQL_WHERE => array('ID' => $ftpUser['id'])));114 if ($lockFTPUser != false){115 if (file_exists($ftpUser['homedir'])){116 117 //get all uploaded files from home directory118 $files = scandir($ftpUser['homedir']);119 $fileCSV = array();120 $fileZIP = array(); 121 122 $fileBytes = 0;123 if (is_array($files)){124 foreach ($files as $key => $file) {125 if($file != '.' && $file != '..'){126 clearstatcache($ftpUser['homedir'].$file);127 $fileTime = filemtime($ftpUser['homedir'].$file);128 $fileBytes += filesize($ftpUser['homedir'].$file); 129 130 $fileExt = explode('.', $file); 131 $fileExt = $fileExt[count($fileExt)-1];132 if (strtolower($fileExt) == 'csv'){133 if (!isset($fileCSV[$fileTime])){134 $fileCSV[$fileTime] = $file; 135 }136 }elseif (strtolower($fileExt) == 'zip'){137 if (!isset($fileZIP[$fileTime])){138 $fileZIP[$fileTime] = $file; 139 }140 }141 }142 }143 $files = null;144 krsort($fileZIP);145 krsort($fileCSV);146 147 if (count($fileZIP) > 0){148 $files = $fileZIP;149 }elseif (count($fileCSV) > 0){150 $files = $fileCSV;151 }152 153 if ($files != null){ 154 foreach($files as $key => $file){ 155 //@shell_exec('cp -R '.$ftpUser['homedir'].$file.' '.$this->docRoot.$file.'_'.time());156 $p = array('LANG' => $lang157 , 'fileFormat' => $user['datexFormat']158 , 'vType' => $user['datexFTPVType']159 , 'FILE_NAME' => $ftpUser['homedir'].$file160 , 'USER_DATA' => $user161 , 'DOC_ROOT' => $this -> docRoot162 , 'CRONJ' => true // specify that import run is a cronjob163 ); 164 165 $dataIntfFile = System_Properties::$DATA_INTF_FILE;166 if (isset($dataIntfFile[$p['fileFormat']]['FILE_TYPES'])){167 168 $ret = System_Properties::handleDatexImp($p); 169 if (isset($ret['PROT']) && is_array($ret['PROT'])){170 $cronjTaskResult = $ret['PROT'];171 }172 }173 }174 }175 176 if ($fileBytes > 0){177 db_updFTPUserQuotatallies(array(System_Properties::SQL_SET => array('SUB_BYTES_IN_USED'=>$fileBytes)178 , System_Properties::SQL_WHERE => array('NAME'=>$ftpUser['username'])179 //, 'print'=>true180 ));181 }182 183 //Now delete all files184 $files = scandir($ftpUser['homedir']);185 foreach ( $files as $key => $file) {186 if($file != '.' && $file != '..'){187 //Lösche alle Dateien188 if (is_file($ftpUser['homedir'].$file)){189 unlink($ftpUser['homedir'].$file); 190 }191 elseif (is_dir($ftpUser['homedir'].$file)){192 System_Properties::rec_rmdir($ftpUser['homedir'].$file);193 } 194 }195 }196 }197 }198 }199 200 //Unlock user201 db_updFTPUser(array(System_Properties::SQL_SET => array('LOGIN_ENABLED' => 'Y')202 , System_Properties::SQL_WHERE => array('ID' => $ftpUser['id'])));203 }204 }205 }206 }207 }208 209 210 211 212 //Log cronjob stop213 db_updCronjTask(array(System_Properties::SQL_SET => array('cronjTaskStopTime' => time()+1214 , 'cronjTaskFinished' => '1'215 , 'cronjTaskResult' => Zend_Json::encode($cronjTaskResult))216 , System_Properties::SQL_WHERE => array('cronjTaskID' => $cronjTaskID)217 //, 'print' => true218 ));219 } 220 }221}222// chdir($docRoot);223$cronj = new cl_cronj_imp_ads(array('LANG' => $lang224 , 'DOC_ROOT' => $docRoot225 ));226$cronj -> exec_cronj();227// $cronj->runtest();228?>...
run
Using AI Code Generation
1$system_properties = new system_properties();2$system_properties->run();3$system_properties = new system_properties();4$system_properties->run();5$system_properties = new system_properties();6$system_properties->run();7$system_properties = new system_properties();8$system_properties->run();9$system_properties = new system_properties();10$system_properties->run();11$system_properties = new system_properties();12$system_properties->run();13$system_properties = new system_properties();14$system_properties->run();15$system_properties = new system_properties();16$system_properties->run();17$system_properties = new system_properties();18$system_properties->run();19$system_properties = new system_properties();20$system_properties->run();21$system_properties = new system_properties();22$system_properties->run();23$system_properties = new system_properties();24$system_properties->run();25$system_properties = new system_properties();26$system_properties->run();27$system_properties = new system_properties();28$system_properties->run();29$system_properties = new system_properties();30$system_properties->run();31$system_properties = new system_properties();32$system_properties->run();
run
Using AI Code Generation
1$sys = new system_properties();2$sys->run();3$sys = new system_properties();4$sys->run();5$sys = new system_properties();6$sys->run();7$sys = new system_properties();8$sys->run();9$sys = new system_properties();10$sys->run();11$sys = new system_properties();12$sys->run();13$sys = new system_properties();14$sys->run();15$sys = new system_properties();16$sys->run();17$sys = new system_properties();18$sys->run();19$sys = new system_properties();20$sys->run();21$sys = new system_properties();22$sys->run();23$sys = new system_properties();24$sys->run();25$sys = new system_properties();26$sys->run();27$sys = new system_properties();28$sys->run();29$sys = new system_properties();30$sys->run();31$sys = new system_properties();32$sys->run();33$sys = new system_properties();34$sys->run();
run
Using AI Code Generation
1$system_properties = new system_properties();2$system_properties->run();3$system_properties = new system_properties();4$system_properties->run();5$system_properties = new system_properties();6$system_properties->run();7$system_properties = new system_properties();8$system_properties->run();9$system_properties = new system_properties();10$system_properties->run();11$system_properties = new system_properties();12$system_properties->run();13$system_properties = new system_properties();14$system_properties->run();15$system_properties = new system_properties();16$system_properties->run();17$system_properties = new system_properties();18$system_properties->run();19$system_properties = new system_properties();20$system_properties->run();21$system_properties = new system_properties();22$system_properties->run();23$system_properties = new system_properties();24$system_properties->run();25$system_properties = new system_properties();26$system_properties->run();27$system_properties = new system_properties();28$system_properties->run();
run
Using AI Code Generation
1$obj = new system_properties();2$obj -> run();3$obj = new system_properties();4$obj -> run();5$obj = new system_properties();6$obj -> run();7$obj = new system_properties();8$obj -> run();9$obj = new system_properties();10$obj -> run();11$obj = new system_properties();12$obj -> run();13$obj = new system_properties();14$obj -> run();15$obj = new system_properties();16$obj -> run();17$obj = new system_properties();18$obj -> run();19$obj = new system_properties();20$obj -> run();21$obj = new system_properties();22$obj -> run();23$obj = new system_properties();24$obj -> run();25$obj = new system_properties();26$obj -> run();27$obj = new system_properties();28$obj -> run();29$obj = new system_properties();30$obj -> run();31$obj = new system_properties();32$obj -> run();33$obj = new system_properties();34$obj -> run();35$obj = new system_properties();36$obj -> run();
run
Using AI Code Generation
1require_once('system_properties.php');2$system_properties = new system_properties();3$system_properties->run();4class system_properties {5public function run() {6$properties = array(7'PHP_VERSION' => phpversion(),8'PHP_OS' => php_uname(),9'PHP_SAPI' => php_sapi_name(),10'PHP_MAX_EXECUTION_TIME' => ini_get('max_execution_time'),11'PHP_MAX_INPUT_TIME' => ini_get('max_input_time'),12'PHP_MEMORY_LIMIT' => ini_get('memory_limit'),13'PHP_MAX_POST_SIZE' => ini_get('post_max_size'),14'PHP_MAX_UPLOAD_SIZE' => ini_get('upload_max_filesize')15);16";17";18";19";20";21";22";23";24}25}
Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Execute automation tests with run on a cloud-based Grid of 3000+ real browsers and operating systems for both web and mobile applications.
Test now for FreeGet 100 minutes of automation test minutes FREE!!