Create a Windows Desktop Link from PHP

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
asterinex
Forum Commoner
Posts: 52
Joined: Thu Nov 25, 2004 7:01 am
Location: Belgium

Create a Windows Desktop Link from PHP

Post by asterinex »

Hello Everyone,

What I want to do is give my customers an opportunity to make a desktop icon that directly link to a website. De url has to contain the username and unixdate of creation.
So wenn someone starts his computer. He klicks on that icon . Internet explorer pops up and he is logged.

Is it possible to create dynamiccaly a desktop icon with php. Lets say wenn the user klicks a button.


Thanks in advance,

Gert
User avatar
anjanesh
DevNet Resident
Posts: 1679
Joined: Sat Dec 06, 2003 9:52 pm
Location: Mumbai, India

Post by anjanesh »

There is something known as window.external.AddDesktopComponent in Javascript which works only in IE+Windows and your Windows should have Active Desktop enabled.

AddDesktopComponent

The other option is to use ActiveX objects to create a desktop link.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

yes. Unfortunately, current shortcuts are binary files. It's best to provide the user with the link information and let them create it. This also avoids people not wanting to download your created one because they can contain viruses/trojans/etc
User avatar
anjanesh
DevNet Resident
Posts: 1679
Joined: Sat Dec 06, 2003 9:52 pm
Location: Mumbai, India

Post by anjanesh »

asterinex - if you really want this done then goto many good porn sites - Im sure you'll get the answer.
But I think they too use ActiveX. Not sure if they could do this using Javascript.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

now, maybe you're talking more about a .url file instead of a .lnk?

http://www.cyanwerks.com/file-format-url.html
Post Reply