关闭

js打开本地磁盘

236人阅读 评论(0) 收藏 举报
<html>

<head>
<title>打开本地磁盘</title>
</head>
<body bgcolor=e0e0ff oncontextmenu="return false" ondragstart="return false" onselectstart="return false">
<center>
  <table border=1 bordercolor=7070ff width=500>
   <tr align="center">
      <td colspan="7">
       强行打开驱动器
      </td>
    </tr>
    <tr align="center">
      <td colspan=7>你在网吧里上网吗?网吧里有没有安装了软件隐藏了驱动器?可你却正好要放点刚下载的文件急用?呵呵,没有关系,点击下面的按钮,让我们来强行打开各个驱动器吧!^_^</td>
    </tr>
    <tr align="center" height="30">
      <td>
          <input type=submit value="打开C盘" onClick="open_disk('c')">
      </td>
      <td>
          <input type=submit value="打开D盘" onClick="open_disk('d')">
      </td>
      <td>
          <input type=submit value="打开E盘" onClick="open_disk('e')">
      </td>
      <td>
          <input type=submit value="打开F盘" onClick="open_disk('f')">
      </td>
      <td>
          <input type=submit value="打开G盘" onClick="open_disk('g')">
      </td>
      <td>
          <input type=submit value="打开H盘" onClick="open_disk('h')">
      </td>
      <td>
          <input type=submit value="打开A盘" onClick="open_disk('a')">
      </td>
    </tr>
   <tr align="center">
<td colspan=7>下面几个按钮也有特殊用途的哦,让所有的限制在我们面前都成为一堆废铁吧!</td>
</tr>
    <tr align="center" height="30">
      <td>
          <input type=submit value="打开我的电脑" onClick="window.open('file:///::{20D04FE0-3AEA-1069-A2D8-08002B30309D}')">
      </td>
      <td>
          <input type=submit value="打开网上邻居" onClick="window.open('file:///::{208D2C60-3AEA-1069-A2D7-08002B30309D}')">
      </td>
      <td>
          <input type=submit value="打开回收站" onClick="window.open('file:///::{645FF040-5081-101B-9F08-00AA002F954E}')">
      </td>
      <td>
          <input type=submit value="打开我的文档" onClick="window.open('file:///::{450D8FBA-AD25-11D0-98A8-0800361B1103}')">
      </td>
      <td>
          <input type=submit value="打开打印机" onClick="window.open('file:///::{20D04FE0-3AEA-1069-A2D8-08002B30309D}/::{2227A280-3AEA-1069-A2DE-08002B30309D}')">
      </td>
      <td>
          <input type=submit value="打开控制面板" onClick="window.open('file:///::{20D04FE0-3AEA-1069-A2D8-08002B30309D}/::{21EC2020-3AEA-1069-A2DD-08002B30309D}')">
      </td>
      <td>
          <input type=submit value="打开计划任务" onClick="window.open('file:///::{20D04FE0-3AEA-1069-A2D8-08002B30309D}/::{D6277990-4C6A-11CF-8D87-00AA0060F5BF}')">
      </td>
      </tr>
  </table>
</center>
</body>
</html>
<script>
function open_disk(disk)
{
try
{
window.open('file://'+disk+':\\');
}
catch(e)
{
try{window.open('file:///'+disk+':');}catch(e){alert("打不开我也没办法了:(");}
}
}
</script>
0
0

查看评论
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
    个人资料
    • 访问:146027次
    • 积分:3800
    • 等级:
    • 排名:第8403名
    • 原创:234篇
    • 转载:83篇
    • 译文:1篇
    • 评论:6条