cgi-bin
directory or create a new one with permissions of execution enabled and copy there the executable cgiremote.exe
.
http://localhost/cgi-bin/cgiremote.exe
or similar if you used a different directory.
CGIRemote: Unable to connect to PC Remote Control
.
If your set of commands doesn't change frequently, or there is no way to make SSI working, you could also write one by one the commands inside the form above, like this:Create a simple web page with the appropiate extension (typically .shtml) so that the web server will take into account the SSI parts you write. Insert a web form with the following text:
<form action="/cgi-bin/cgiremote.exe" method="post">
<!--#exec cgi="/cgi-bin/cgiremote.exe"-->
<input type="submit" value="Execute command">
</form>The form above should show the selection box and to its right a button with the text Execute command
. If there is not selection box, perhaps there is a problem with the SSI. Try putting the .shtml file in the same directory where CGIRemote is.
<form action="/cgi-bin/cgiremote.exe" method="post">
<SELECT name=cmd>
<OPTION selected>First command</OPTION>
<OPTION>Second command</OPTION>
<OPTION>Third command</OPTION>
</SELECT>
<input type="submit" value="Execute command">
</form>
CGIRemote also allows the introduction of parameters in the URL string. You can directly type the commands on the location bar of the web browser, or create a set of links on a web page without relying on web forms. For example, the URL http://localhost/cgi-bin/cgiremote.exe?cmd=First command
would be equivalent to clicking the submit button on any of the forms above. Alternatively, a link to that same command in a web page would be like this: <a href="/cgi-bin/cgiremote.exe?cmd=First command">Link to First command</a>
Request/Query | Parameter | Function |
---|---|---|
<none> | <none> | Returns html code that shows a selection box filled with the commands of PCRC. Example: http://localhost/cgi-bin/cgiremote.exe |
cmd | <command> | Tells PCRC to execute the command sent as parameter. Example: http://localhost/cgi-bin/cgiremote.exe?cmd=Play song |
get | form | Returns a complete web form with a selection box filled with the commands of PCRC. Example: http://localhost/cgi-bin/cgiremote.exe?get=form |
list | Returns a simple text list of the commands of PCRC. Example: http://localhost/cgi-bin/cgiremote.exe?get=list |