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

📄 netconfig.asp

📁 50个完整的ASP小例子
💻 ASP
字号:
<%@ Language="VBScript" %>
<% Option Explicit %>
<html>
<head>
    <title>查看网络设置</title>
</head>
<body bgcolor="#FFFFFF">
<%
    dim strHost
    dim oShell,oFS,oTF
    dim i,Data,tempData
    strHost="ipconfig"
    Set oShell = Server.CreateObject("Wscript.Shell")
    oShell.Run "%ComSpec% /c ipconfig > C:\" & strHost & ".txt", 0, True
    Set oFS = Server.CreateObject("Scripting.FileSystemObject")
    Set oTF = oFS.OpenTextFile("C:\" & strHost & ".txt")
    Do While Not oTF.AtEndOfStream
        Data = Trim(oTF.Readline)
            If i > 2 Then 
                tempData = tempData & Data & "<BR>"
            End If
        i = (i + 1)
    Loop
    response.write tempData
    oTF.Close
    oFS.DeleteFile "C:\" & strHost & ".txt"
    Set oFS = Nothing
%>
</font>
</body>
</html>

 

⌨️ 快捷键说明

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