⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 search.php

📁 通达OA2007SE源代码 非常好的
💻 PHP
📖 第 1 页 / 共 4 页
字号:
  ob_end_clean ();
  header ('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
  header ((('Last-Modified: '.gmdate ('D, d M Y H:i:s')).' GMT'));
  header ('Cache-Control: no-cache, must-revalidate');
  header ('Pragma: no-cache');
  include 'prive/conf.php';
  $racine = $DISK_PATH;
  if (($langue == ''))
  {
    $langue = $dft_langue;
  }
  require (((''.'include/').$langue).'.php');
  if (file_exists ((((''.'logs/').$id).'.php')))
  {
    include (((''.'logs/').$id).'.php');
  }
  switch ($action)
  {
    case 'aide':
    {
      include $hautpage;
      include (((''.'include/').$langue).'_help.htm');
      break;
    }
    case 'telecharger':
    {
      $NomFichier = basename ($fichier);
      $taille = filesize ((((''.$racine).'/').$fichier));
      ob_end_clean ();
      header ((((''.'Content-Type: application/force-download; name="').$NomFichier).'"'));
      header ('Content-Transfer-Encoding: binary');
      header (((''.'Content-Length: ').$taille));
      header ((((''.'Content-Disposition: attachment; filename="').$NomFichier).'"'));
      header ('Expires: 0');
      header ('Cache-control: private');
      header ('Pragma: no-cache');
      readfile ((((''.$racine).'/').$fichier));
      exit ();
      break;
    }
    case 'editer':
    {
      if (!connecte ($id))
      {
        header ('Location:netdisk.php');
        exit ();
      }
      include $hautpage;
      $code = stripslashes ($code);
      if (($save == 1))
      {
        $code = str_replace ('&lt;', '<', $code);
        $fp = fopen ((((''.$racine).'/').$fic), 'w');
        fputs ($fp, $code);
        fclose ($fp);
        enlever_controlm ((((''.$racine).'/').$fic));
        echo '        ';
        echo '<s';
        echo 'cript>alert(\'文件已保存!\');</script>
';
      }
      echo '<div align=center class=big1>
';
      echo ((((''.$mess['52']).' <b>').$fic).'</b><br>');
      echo '<form name="form1" action="netdisk.php" method="post">
';
      echo (((''.'<input type="hidden" name="DISK_ID" value="').$DISK_ID).'">
');
      echo (((''.'<input type="hidden" name="id" value="').$id).'">
');
      echo (((''.'<input type="hidden" name="fic" value="').$fic).'">
');
      echo (((''.'<input type="hidden" name="rep" value="').$rep).'">
');
      echo '<input type="hidden" name="save" value="1">
';
      echo '<input type="hidden" name="action" value="editer">
';
      echo (((''.'<input type="hidden" name="ordre" value="').$ordre).'">
');
      echo (((''.'<input type="hidden" name="sens" value="').$sens).'">
');
      echo '<TEXTAREA NAME="code" rows="20" cols="80" wrap="OFF" class=BigInput >
';
      $fp = fopen ((((''.$racine).'/').$fic), 'r');
      if ($fp)
      {
        while (!feof ($fp))
        {
          $tmp = fgets ($fp, 4096);
          $tmp = str_replace ('<', '&lt;', $tmp);
          echo (''.$tmp);
        }
        fclose ($fp);
      }
      echo (''.$fichier);
      echo '</TEXTAREA>
';
      echo '<br><br>
';
      echo (((((''.'<input type="image" src="images/enregistrer.gif" alt="').$mess['53']).'" border="0"><a href=# onclick=\'javascript:document.form1.submit()\'><span class=Big1>').$mess['53']).'</span></a>
');
      echo (((((((((((((((''.'<a href="netdisk.php?DISK_ID=').$DISK_ID).'&id=').$id).'&rep=').$rep).'&ordre=').$ordre).'&sens=').$sens).'"><img src="images/fermer.gif" alt="').$mess['86']).'" border="0"><span class=Big1>').$mess['86']).'</span></a>
');
      echo '</form>
';
      echo '</div>
';
      break;
    }
    case 'copier':
    {
      if (!connecte ($id))
      {
        header ('Location:netdisk.php');
        exit ();
      }
      include $hautpage;
      echo '<div align=center class=big1>
';
      echo '<table class=TableContent>
';
      echo (((((''.'<tr><td><img src="images/copier.gif" width="20" height="20" align="ABSMIDDLE"> ').$mess['67']).' : </td><td><b>').$fic).'</b></td></tr>
');
      echo (((''.'<tr><td><img src="images/coller.gif" width="20" height="20" align="ABSMIDDLE"> ').$mess['68']).' : </td><td>');
      if (($dest == ''))
      {
        echo '/';
      }
      else
      {
        echo (''.$dest);
      }
      echo '</td></tr>
';
      echo '</table>
';
      echo (((''.'<br>').$mess['69']).' :<br><br>
');
      echo '<table class=TableContent>';
      $handle = opendir ((((''.$racine).'/').$dest));
      while ($fichier = readdir ($handle))
      {
        if (($fichier == '..'))
        {
          $up = dirname ($dest);
          if ((($up == $dest) OR ($up == '.')))
          {
            $up = '';
          }
          if (($up != $dest))
          {
            echo (((((((((((((((((''.'<td><img src="images/parent.gif"></td><td><a href="netdisk.php?DISK_ID=').$DISK_ID).'&id=').$id).'&action=copier&ordre=').$ordre).'&sens=').$sens).'&dest=').$up).'&fic=').$fic).'&rep=').$rep).'">').$mess['24']).'</td>');
            continue;
          }
          continue;
        }
        if (((($fichier != '..') AND ($fichier != '.')) AND is_dir ((((((''.$racine).'/').$dest).'/').$fichier))))
        {
          $liste_dir[] = $fichier;
          continue;
        }
      }
      closedir ($handle);
      if (is_array ($liste_dir))
      {
        asort ($liste_dir);
        while (list ($cle, $val) = each ($liste_dir))
        {
          echo (((((''.'<tr><td><img src="images/dossier.gif"></td><td><a href="netdisk.php?DISK_ID=').$DISK_ID).'&id=').$id).'&action=copier&dest=');
          if (($dest != ''))
          {
            echo ((''.$dest).'/');
          }
          echo ((((((((((((''.$val).'&rep=').$rep).'&ordre=').$ordre).'&sens=').$sens).'&fic=').$fic).'">').$val).'</a></tr>
');
        }
      }
      echo '</table><br>';
      echo '<table>
';
      echo '<tr>
';
      echo '<td>
';
      echo '<form action="netdisk.php" method="post">
';
      echo (((''.'<input type="hidden" name="DISK_ID" value="').$DISK_ID).'">
');
      echo '<input type="hidden" name="action" value="copier_suite">
';
      echo (((''.'<input type="hidden" name="fic" value="').$fic).'">
');
      echo (((''.'<input type="hidden" name="dest" value="').$dest).'">
');
      echo (((''.'<input type="hidden" name="rep" value="').$rep).'">
');
      echo (((''.'<input type="hidden" name="id" value="').$id).'">
');
      echo (((''.'<input type="hidden" name="sens" value="').$sens).'">
');
      echo (((''.'<input type="hidden" name="ordre" value="').$ordre).'">
');
      echo '<input type="submit" class=BigButton value="确定">&nbsp;
';
      echo '</form>
';
      echo '</td>
';
      echo '<td>
';
      echo '<form action="netdisk.php" method="post">
';
      echo (((''.'<input type="hidden" name="DISK_ID" value="').$DISK_ID).'">
');
      echo (((''.'<input type="hidden" name="id" value="').$id).'">
');
      echo (((''.'<input type="hidden" name="rep" value="').$rep).'">
');
      echo (((''.'<input type="hidden" name="ordre" value="').$ordre).'">
');
      echo (((''.'<input type="hidden" name="sens" value="').$sens).'">
');
      echo (((''.'<input type="submit" class=BigButton value="').$mess['54']).'">
');
      echo '</form>
';
      echo '</td>
';
      echo '</tr>
';
      echo '</table>
';
      echo '</div>
';
      break;
    }
    case 'copier_suite':
    {
      if (!connecte ($id))
      {
        header ('Location:netdisk.php');
        exit ();
      }
      $destination = ((''.$racine).'/');
      if (($dest != ''))
      {
        ($destination .= ((''.$dest).'/'));
      }
      ($destination .= basename ($fic));
      if ((file_exists ((((''.$racine).'/').$fic)) AND ((((''.$racine).'/').$fic) != $destination)))
      {
        copy ((((''.$racine).'/').$fic), $destination);
      }
      header (((((((((((''.'Location:netdisk.php?DISK_ID=').$DISK_ID).'&rep=').$rep).'&id=').$id).'&ordre=').$ordre).'&sens=').$sens));
      exit ();
      break;
    }
    case 'voir':
    {
      $nomdufichier = basename ($fichier);
      if (is_image ($fichier))
      {
        readfile ((((''.$racine).'/').$fichier));
        exit ();
      }
      echo '<html>
';
      echo (((((''.'<head><title>').$mess['23']).' : ').$nomdufichier).'</title></head>
');
      $fp = fopen ((''.$hautpage), 'r');
      if ($fp)
      {
        while (!feof ($fp))
        {
          $buffer = fgets ($fp, 4096);
          if (eregi ('<body', $buffer))
          {
            $tmp = split ('<', $buffer);
            while (list ($cle, $val) = each ($tmp))
            {
              if (eregi ('body', $val))
              {
                $val = str_replace ('>', '', $val);
                $val = str_replace (chr (10), '', $val);
                $val = str_replace (chr (13), '', $val);
                echo (((''.'<').$val).' onload="self.focus()">
');
                continue;
              }
            }
            break;
          }
        }
        fclose ($fp);
      }
      echo (((''.'<div align=center class=big1>').$mess['23']).' : ');
      echo (('<img src="images/'.mimetype ((((''.$racine).'/').$fichier), 'image')).'" align="ABSMIDDLE">
');
      echo (('<b>'.$nomdufichier).'</b><br><br><hr>
');
      echo (((((''.'<a href="javascript:window.print()"><img src="images/imprimer.gif" alt="').$mess['90']).'" border="0">').$mess['90']).'</a>
');
      echo '<a href="javascript:window.close()"><img src="images/fermer.gif" alt="关闭" border="0">关闭</a>
';
      echo '<br>
';
      echo '<hr><br>';
      echo '</div>
';
      $fp = fopen ((((''.$racine).'/').$fichier), 'r');
      if ($fp)
      {
        echo '
';
        while (!feof ($fp))
        {
          $buffer = fgets ($fp, 4096);
          $buffer = txt_vers_html ($buffer);
          $buffer = str_replace ('	', '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;', $buffer);
          echo ($buffer.'<br>');
        }
        fclose ($fp);
        echo '
';
      }
      echo '<hr>
';
      echo (((((''.'<a href="javascript:window.print()"><img src="images/imprimer.gif" alt="').$mess['90']).'" border="0">').$mess['90']).'</a>
');
      echo '<a href="javascript:window.close()"><img src="images/fermer.gif" alt="关闭" border="0">关闭</a>
';
      echo '<hr></div>
';
      echo '</body>
';
      echo '</html>
';
      exit ();
      break;
    }
    case 'deplacer':
    {
      if (!connecte ($id))
      {
        header ('Location:netdisk.php');
        exit ();
      }
      include $hautpage;
      echo '<div align=center class=big1>
';
      echo '<table class=TableContent>
';
      echo (((((''.'<tr><td><img src="images/couper.gif" width="20" height="20" align="ABSMIDDLE"> ').$mess['67']).' : </td><td><b>').$fic).'</b></td></tr>
');
      echo (((''.'<tr><td><img src="images/coller.gif" width="20" height="20" align="ABSMIDDLE"> ').$mess['68']).' : </td><td>');
      if (($dest == ''))
      {
        echo '/';
      }
      else
      {
        echo (''.$dest);
      }
      echo '</td></tr>
';
      echo '</table>
';
      echo (((''.'<br>').$mess['69']).' :<br><br>
');
      echo '<table class=TableContent>';
      $handle = opendir ((((''.$racine).'/').$dest));
      while ($fichier = readdir ($handle))
      {
        if (($fichier == '..'))
        {
          $up = dirname ($dest);
          if ((($up == $dest) OR ($up == '.')))
          {
            $up = '';
          }
          if (($up != $dest))
          {
            echo ((((((((((((((((''.'<td><img src="images/parent.gif"></td><td><a href="netdisk.php?DISK_ID=').$DISK_ID).'&id=').$id).'&ordre=').$ordre).'&sens=').$sens).'&action=deplacer&dest=').$up).'&fic=').$fic).'&rep=').$rep).'">').$mess['24']);
            continue;
          }
          continue;
        }
        if (((($fichier != '..') AND ($fichier != '.')) AND is_dir ((((((''.$racine).'/').$dest).'/').$fichier))))
        {
          $liste_dir[] = $fichier;
          continue;
        }
      }
      closedir ($handle);
      if (is_array ($liste_dir))
      {
        asort ($liste_dir);
        while (list ($cle, $val) = each ($liste_dir))
        {
          echo (((((''.'<tr><td><img src="images/dossier.gif"></td><td><a href="netdisk.php?DISK_ID=').$DISK_ID).'&id=').$id).'&action=deplacer&dest=');
          if (($dest != ''))
          {
            echo ((''.$dest).'/');
          }
          echo ((((((((((((''.$val).'&rep=').$rep).'&ordre=').$ordre).'&sens=').$sens).'&fic=').$fic).'">').$val).'</a></tr>
');
        }
      }
      echo '</table><br>';
      echo '<table>
';
      echo '<tr>
';
      echo '<td>
';
      echo '<form action="netdisk.php" method="post">
';
      echo (((''.'<input type="hidden" name="DISK_ID" value="').$DISK_ID).'">
');
      echo '<input type="hidden" name="action" value="deplacer_suite">
';
      echo (((''.'<input type="hidden" name="fic" value="').$fic).'">
');
      echo (((''.'<input type="hidden" name="dest" value="').$dest).'">
');
      echo (((''.'<input type="hidden" name="rep" value="').$rep).'">
');
      echo (((''.'<input type="hidden" name="id" value="').$id).'">
');
      echo (((''.'<input type="hidden" name="ordre" value="').$ordre).'">
');
      echo (((''.'<input type="hidden" name="sens" value="').$sens).'">
');
      echo '<input type="submit" class=BigButton value="确定">&nbsp;
';
      echo '</form>
';
      echo '</td>
';
      echo '<td>
';
      echo '<form action="netdisk.php" method="post">
';
      echo (((''.'<input type="hidden" name="DISK_ID" value="').$DISK_ID).'">
');
      echo (((''.'<input type="hidden" name="id" value="').$id).'">
');
      echo (((''.'<input type="hidden" name="rep" value="').$rep).'">
');
      echo (((''.'<input type="hidden" name="ordre" value="').$ordre).'">
');
      echo (((''.'<input type="hidden" name="sens" value="').$sens).'">
');
      echo '<input type="submit" class=BigButton value="取消">
';
      echo '</form>
';
      echo '</td>
';
      echo '</tr>
';
      echo '</table>
';
      echo '</div>
';

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -