We often see on websites that you can directly save the website to your computer as a shortcut, and then just click to access the Internet. So how do you add a webpage to the desktop shortcut in PHP?
The function is simple and you can directly enter the code.
The code is as follows
|
Copy code
|
Mars Age IT Development
代码如下 |
复制代码 |
$Shortcut = "
[InternetShortcut]
URL=http://www.bKjia.c0m
IDList=IconFile=http://www.bKjia.c0m/favicon.ico
Prop3=19,2";
header("Content-Type: application/octet-stream");
header("Content-Disposition: attachment; filename=111cn.url");
echo $Shortcut;
|
代码如下 |
复制代码 |
$Shortcut = "[InternetShortcut]
URL=http://www.bKjia.c0m/
IDList=
[{000214A0-0000-0000-C000-000000000046}]
Prop3=19,2
";
Header("Content-type: application/octet-stream");
header("Content-Disposition: attachment; filename=11cn.url;");
echo $Shortcut;
?>
|
|
shortcuts.php code
The code is as follows
|
Copy code
$Shortcut = "
[InternetShortcut]
URL=http://www.bKjia.c0m
IDList=IconFile=http://www.bKjia.c0m/favicon.ico
Prop3=19,2";
header("Content-Type: application/octet-stream");
header("Content-Disposition: attachment; filename=111cn.url");
echo $Shortcut;
There is also a method below
The code is as follows
|
Copy code
|
$Shortcut = "[InternetShortcut] <🎜>
URL=http://www.bKjia.c0m/ <🎜>
IDList= <🎜>
[{000214A0-0000-0000-C000-000000000046}] <🎜>
Prop3=19,2 <🎜>
"; <🎜>
Header("Content-type: application/octet-stream"); <🎜>
header("Content-Disposition: attachment; filename=11cn.url;"); <🎜>
echo $Shortcut; <🎜>
?>
http://www.bkjia.com/PHPjc/631577.htmlwww.bkjia.comtruehttp: //www.bkjia.com/PHPjc/631577.htmlTechArticleWe often see on websites that you can directly save the website to your computer as a shortcut, and then just You can enter the Internet by clicking on it, so how do you add a web page to...
|
|
|