Solved

Bat-cgi-sripts om a NT server

Posted on 1997-03-08
1
293 Views
Last Modified: 2013-12-25
I have written some cgi scripts in java and need to call the interpeter and the class file from a bat-file.
Bat file : jview xxx  (where xxx = xxx.class).

The problem is that my Nt-web-server(IIS 2.0) will not run the bat-file. How do I fix the setup on the web server so it run's the files??

Or am I far from geting anything out from the scripts I've written??
0
Comment
Question by:esolem
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 

Accepted Solution

by:
henryj earned 100 total points
ID: 1827491
Try this:

Use the registry editor to find:

HKEY_LOCAL_MACHINE
   SYSTEM
      CurrentControlSet
         Services
            W3SVC
               Parameters
                  ScriptMap

Using the Edit Menu choose New. On the pop up menu which appears choose String Value. A new line should appear highlighted in the
name column on the right hand side of the Registry Editor screen.

Type .bat (don't forget the '.') and press return.

Now highlight the .bat line which should be in your registry listing and double click it. You should get an Edit String
dialogue box. In the Value Data box add a few %s's with spaces
between them ie:  %s %s %s %s (however many you like). These
should allow you to pass parameters to your batch files.

Choose exit from the registry menu.

This *SHOULD* allow you to run .bat files as scripts on your
server. However, you should be careful:

1) Be very aware of the security implications and make sure
your /scripts directory is very secure from misuse.

2) Be aware of potential misuse of any parameters passed to
batch files (ie. if you have a batch file that deletes the
file passed to it as an argument be aware that people could
call it directly with *.* as the argument!!!).

3) I haven't tried this myself so I can't guarantee it works but I'm pretty certain it will as this is how you enable other scripting languages not supported by default.

4) You could probably achieve something similar by using perl
or another programming language and simply spawning your program
from the code...

Good luck!

henry

0

Featured Post

Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It is becoming increasingly popular to have a front-page slider on a web site. Nearly every TV website,  magazine or online news has one on their site, and even some e-commerce sites have one. Today you can use sliders with Joomla, WordPress or …
I hope you'll find this tutorial useful and interesting. So let's try to extend Tcl with a new package.  For anyone more deeply interested please check out the book "Practical Programming in Tcl and Tk". It's really one of the best written books abo…
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question