Cmd.cgi

Description

Use this command to combine several commands to a single http request, that is, user can call two or more commands through Cmd.cgi.

Grammar

/Cmd.cgi?Cmd=sCommandName1 [&ParamName1=sParamValue1] [&ParamName2=sParamValue2][...] [Cmd=sCommandName2 [&ParamName1=sParamValue1] [&ParamName2=sParamValue2][...]] [Cmd=sCommandName3...] [JsVar=variable[&OnJs=function]] [&RedirectUrl=sUrl]

Remark

Some commands may use the same parameter's name, so the parameter's position should be in correct order. If you place parameters of sCommandName1 after sCommandName2, the behaviour of IP Camera is unexpectable.
If there are sub-commands that get information from IP Camera, (such as GetUser.cgi, PPPoE.cgi?Action=GetInfo), "RedirectUrl" should not be specified, otherwise the browser will be redirected to the address specified by "RedirectUrl", and certainly not what you want.

List of commands that can be combined with Cmd.cgi:
ChangeResolution.cgi
ChangeCompressRatio.cgi
ChangeBrightness.cgi
ChangeContrast.cgi
ChangeSaturation.cgi
ChangeHue.cgi
ChangeSharpness.cgi
SetMotionDetect.cgi
SetMonitorRect.cgi
MoveCamera.cgi
GetMyself.cgi
SetUser.cgi
DelUser.cgi
GetUser.cgi
SetUserCheck.cgi
SetMail.cgi
GetMail.cgi
SetFtp.cgi
GetFtp.cgi
SetTime.cgi
GetTime.cgi
SetIP.cgi
GetIP.cgi
PPPoE.cgi
SetHttp.cgi
GetHttp.cgi
SetName.cgi
GetName.cgi
GetLog.cgi
GetVer.cgi
Reboot.cgi

Example

1. Add user abc(password 123), and delete user cba:
/Cmd.cgi?Cmd=SetUser.cgi&User=abc&Pass=123&Cmd=DelUser.cgi&User=cba

<html>
<form action=/Cmd.cgi>
<input type=hidden name=Cmd value=SetUser.cgi>
<input name=User value=abc><br>
<input name=Pass value=123><br>
<br>
<input type=hidden name=Cmd value=DelUser.cgi><br>
<input name=User value=cba>
<input type=submit value=OK>
</form>
</html>

2. get the settings of ftp and email:
/Cmd.cgi?Cmd=GetFtp.cgi&Cmd=GetMail.cgi

<html>
<script>
function ShowResult(o)
{
alert(s);
}
</script>
<script src="/Cmd.cgi?Cmd=GetFtp.cgi&Cmd=GetMail.cgi?JsVar=s&OnJs=ShowResult"></script>
</html>