建立一個PHP文檔:名字好記就行如:shortcut.php
PHP文檔中的內容:
代碼
1 <?php
2 $Shortcut = "[InternetShortcut]
3 URL=http://www.zhangchu.net/
4 IDList=
5 [{000214A0-0000-0000-C000-000000000046}]
6 Prop3=19,2
7 ";
8 Header("Content-type: application/octet-stream");
9 header("Content-Disposition: attachment; filename=張楚網站.url;");
10 echo $Shortcut;
11 ?>
asp 代碼
1 <%
2 id=request("id")
3 gname=request("gname")
4 If gname="" Then gname="4usky小遊戲"
5 Shortcut = "[InternetShortcut] " & vbCrLf
6 Shortcut = Shortcut & "URL=http://www.4usky.com/swf/"&id&".htm?desktop" & vbCrLf
7 Shortcut = Shortcut & "IDList= " & vbCrLf
8 Shortcut = Shortcut & "[{000214A0-0000-0000-C000-000000000046}] " & vbCrLf
9 Shortcut = Shortcut & "Prop3=19,2 " & vbCrLf
10 Shortcut = Shortcut & " " & vbCrLf
11 Response.AddHeader "Content-Disposition", "attachment;filename="&gname&".url;"
12 Response.ContentType = "application/octet-stream"
13 Response.Write Shortcut
14 %>
要想出現表徵圖請先確保網站根目錄中有 favicon.ico 檔案
上傳到網站,訪問地址:如:http://www.zhangchu.net/shortcut.php 就會有提示下載一個名為 張楚網站.urll檔案,儲存在本地就是一個捷徑!
asp示範 http://www.4usky.com/shortcut/