How to call exe on server from javascript? [duplicate] - javascript

This question already has answers here:
Launch local executable from web browser
(2 answers)
Closed 6 months ago.
Javascript is inaccurate, but I need a very precise answers to a quartic equation. I want to slove it with c++, that i compiled into an exe file and will update the answers in a javascript file that I include in the HTML. I need to run the exe file that is in the same folder as the .html file on the server, and pass 5 parameters to it. It will update the javascript file, but I have no idea how to run that exe file. Can anyone help me?
----EDIT----
Thanks #Quentin webassembly worked!

You can't. That would be a severe security vulnerability, if any random web page could execute any random file on your computer.
So, web pages can't execute files on your computer.

Related

The mysterious widgets.map file [duplicate]

This question already has answers here:
How can I use JavaScript source maps (.map files)?
(5 answers)
Closed 1 year ago.
I am working on an HCL Commerce project and I receive this error when I load cart page locally:
File not found: /MyWebExtSitesSAS/javascript/widgets.map
I cannot find anywhere in the web references for widgets.map. Can you describe me what is this file used for, and if I can ignore this error?
I repost the answer in the comment by #disinfor because it answered my question
You can ignore that. A map file is used for debugging purposes. When
you minify code, e.g. js, css, etc. it obviously becomes hard to read
to find any errors. The map file is used by a browser to show where in
the original, unminified code the error is coming from.

Use Javascript to run Bash script in background [duplicate]

This question already has answers here:
How to execute shell command in Javascript
(16 answers)
Closed 5 years ago.
I currently have a project site ( interact.rdarellano.com ) which uses PHP forms to run Bash scripts on my webserver. I'm not happy with this PHP method because it reloads the site every time that the button is clicked.
I've read that Javascript may be able to handle this task in the background. I've never experimented with Javascript so I'm hoping to find somebody that can help me achieve this or guide me on how to set this up.
Read about JSON and AJAX. Start with Jquery which has methods to deal with this.

How to get the file absolute path using javascript or ...? [duplicate]

This question already has answers here:
how to get client side path of the uploded file
(2 answers)
Closed 9 years ago.
I have a javascript that used to upload files.
The problem is I can't get the absolute path using javascript. Is there any other client-side scripting language that can be used to get the absolute path of the file and pass it to my javascript? I don't want to used server-side scripting language like php. Is this possible?
Just to get the path is fine..
You can't get the file path in client browsers. For security concern it is restricted. You will be given only the fake path is shown with file name.

How to download .exe file from server at a predefined location using window.open method or xmlhttprequest onject? [duplicate]

This question already has answers here:
How to download file in computer silently using PHP? [closed]
(3 answers)
Closed 10 years ago.
My problem is that i want to read an .exe file from server and save it to a predefined location. Currently I am using window.open method but it is opening a window and asking for the path. please tell me if know any such method and javascript or GWT is preferable.
Then I also tried to attach progress event with xmlhttprequest object which could tell me whether downloading is done or not but it is also not working fine and desired output is not coming.
Please help me with these two problems.
Hop to get a reply soon. Thanks in advance!!!
You can't save to a predefined location due to security implications.

compress a javascript [duplicate]

This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
How can I obfuscate JavaScript?
I want my js not to be understood by anyone. I have read some similar posts on this site but can get an exe or a full desktop application for it. Whatever I get are online tools.
OR how to sense '\n' character in js?
UglifyJS / UglifyJS2:
JavaScript parser / mangler / compressor / beautifier toolkit
You can download "yui compressor" to compress the javascript. But I does not means that no-one can read you scripts.
Their are again tool which make your compressed javascript files again readable :(

Categories