• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 372
  • Last Modified:

HTML link to launch cmd file

Hi Everyone,

I'm creating a simple html page. On the page I've got a hyperlink, pointing to a command file (.cmd). I'm running Windows 7.

When I click the link, it asks me to 'save the file or launch it'. How can I bypass this question and just launch the file?
0
SvenIA
Asked:
SvenIA
  • 2
  • 2
2 Solutions
 
plusone3055Commented:
simple solution is launch the .cmd file through a .bat  or .vbs  script and have the URL link to the .bat or .vbs script
0
 
Big MontySenior Web Developer / CEO of ExchangeTree.org Commented:
you cannot launch a command file on the users local file, the most you can do is prompt them to download the file (which you have done) and have them launch it manually. to do it automatically would be a huge security risk,

think about it, would you want to visit a site that could run commands on your local computer?

if you're trying to run the command file on the server, plusobe's solution would be the easiest.
0
 
plusone3055Commented:
Monty

Agreed
my thought was that this was a local server task :)
0
 
Big MontySenior Web Developer / CEO of ExchangeTree.org Commented:
i'm hoping it is, be a lot easier to resolve :)
0
 
SvenIAAuthor Commented:
Thanks guys. There's no server involved actually. I'm just trying to create a small html dashboard for someone who isn't very handy with a pc.

My idea was to create a simple html page with some buttons, to launch some scripts and applications.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now