如何使Main()链接到commandajax()
使用commandajax(),您可以使用这两个指令
“savecmd”和“catcmd”吗?
//The initial loading screen
function Main()
{
//Read floag
alert("Main:");
var savecmd = "echo -n \"save"+"\" > /app/Web/cgi-bin/login.txt";
var catcmd = "cat /app/Web/cgi-bin/login.txt";
var floag = funtion(command, isMsg);
命令功能:
function commandajax(command, isMsg)
{
var ReturnString = "";
var ipAddress = location.protocol+"//"+location.hostname+"/cgi-bin/";
var URLs = ipAddress + "PProduceXml.php";
alert(2);
// var savecmd = "echo -n \"save"+"\" > /app/Web/cgi-bin/login.txt";
// var catcmd = "cat /app/Web/cgi-bin/login.txt";
// alert("Action=TransmissionStart&submitString="+(savecmd,catcmd));
$.ajax(
{
----
{
alert("msg:"+msg);
if(isMsg == true)
{
ReturnString = msg;
}
},
error:function(xhr, ajaxOptions, thrownError)
{
}
});
return ReturnString;
}