奶头挺立呻吟高潮av全片,成人试看120秒体验区,性欧美极品v,A片高潮抽搐揉捏奶头视频

php語言

php網頁怎樣清除病毒清

時間:2024-07-25 18:06:29 php語言 我要投稿
  • 相關推薦

php網頁怎樣清除病毒清

  很多人的網頁經常被無故的在php,asp,html,js 等文件后臺加上一些木馬地址,造成了很大的困擾,你知道要怎么清除php網頁病毒嗎?下面小編給大家整理了php網頁病毒清除的方法,供大家參閱。

  首先們要讀取 $checkFile 文件這個文章是判斷一個文章 是否被感染了,如果是就會執行$savafile變量里面的txt文件路徑的所有文件,進行按你infecFile病毒列表清除一次.

  復制代碼 代碼如下:

  Class clear_virus{

  //public $content;

  public $infectFile ='virus.txt';//病毒文件列表文件

  public $savefile ="save.txt";//所在查看病毒的文件列表

  public $timep ='time.txt';//些記錄清除病毒時間

  public $checkFile ='e.php';//這里是設置

  public $run =0;

  public $virus_type;

  public $replace ;

  public $filepath ;

  public $tag =0;

  function open_file(){

  $this->read_virus();

  $this->check_File();

  if($this->run){

  $this->update_time();

  $this->read_file() ;

  foreach($this->filepath as $tmppath){

  if(file_exists($tmppath)){

  $tmp_file =file_get_contents($tmppath);

  print_r( $this->virus_type);

  for( $i=0;$ivirus_type);$i++ ){

  if( strrpos($tmp_file,$this->virus_type[$i])!== false){

  $tmp_file =str_replace($this->virus_type[$i],'',$tmp_file);

  $this->tag =1;

  }

  }

  if( $this->tag ){

  $handle =fopen($tmppath,'w');

  fwrite($handle,$tmp_file);

  fclose($handle);

  unset($tmp_file);

  }

  }else{

  ;

  }

  }

  }

  }

  function check_File(){

  if(file_exists($this->checkFile) ){

  $temp =file_get_contents($this->checkFile) ;

  echo $temp;

  foreach( $this->virus_type as $v_tmp ){

  if( strrpos($temp,$v_tmp)!== false ){

  $this->run =1;

  break;

  }

  }

  echo $this->run;

  unset($temp);

  }else{

  $this->show_error(5);

  }

  }

  function update_time(){

  if(file_exists($this->timep) ){

  $tmp_time =date("Y-m-d H:i:s").chr(13).'|';

  $tmp_fp =fopen($this->timep,'a+');

  fwrite($tmp_fp,$tmp_time);

  fclose($tmp_fp);

  }

  }

  function read_File(){

  if(file_exists($this->savefile) ){

  $this->content =file($this->savefile);

  if(is_array($this->content)){

  $this->filepath =$this->content;

  }else{

  $this->show_error(3);

  }

  }else{

  $this->show_error(4);

  }

  }

  function read_virus(){

  if(file_exists($this->infectFile) ){

  $this->replace =file($this->infectFile);

  if(is_array($this->replace)){

  $this->virus_type=$this->replace;

  }else{

  $this->show_error(1);

  }

  }else{

  $this->show_error(2);

  }

  }

  function show_error($number){

  $array = array(

  '1'=>'病毒文件未不能讀取!',

  '2'=>'病毒文件列表不存在!',

  '3'=>'文件列表不存了',

  '4'=>'查殺的文件不存',

  '5'=>$this->$checkFile.'不存在了,請設置病毒感染文件'

  );

  echo $array[$number];

  }

  }

  $virus =new clear_virus;

  $virus->open_file();

  ?>

【php網頁怎樣清除病毒清】相關文章:

svchost是什么 怎樣清除svchost.exe病毒07-25

如何清除cmd.exe病毒09-10

怎樣學習PHP內容09-17

php銀聯網頁支付實現方法08-16

優秀的PHP程序員是怎樣練成的08-02

怎樣制作網頁 制作網頁詳細操作步驟09-02

怎樣才能成為PHP高手09-06

怎樣才能成為PHP高手?06-16

PHP的cURL庫有效地抓網頁的技巧05-22

如何利用PHP代碼在網頁上生成圖片10-12

主站蜘蛛池模板: 仁怀市| 徐水县| 石首市| 四子王旗| 红原县| 黄山市| 宁国市| 明水县| 铁岭市| 林西县| 富宁县| 珠海市| 九江市| 家居| 仲巴县| 东方市| 江西省| 定结县| 阳信县| 尉犁县| 宁远县| 镇雄县| 隆化县| 潜江市| 彩票| 阿拉善右旗| 沭阳县| 洪泽县| 绥棱县| 湖南省| 上饶县| 民丰县| 铁岭市| 顺义区| 苏尼特右旗| 高台县| 龙江县| 嘉鱼县| 普安县| 宝清县| 永寿县|