$line) { $gefunden = strpos($line,$inputMuster); if($gefunden > 0 ) { //echo "Line #{$line_num} : " . htmlspecialchars($line) . "
\n"; $lines[$line_num] = $replaceString; // echo "NewLine #{$line_num} : " . htmlspecialchars($lines[$line_num]) . "
\n"; $fp = fopen('status.json', 'w'); foreach($lines as $values) fputs($fp, $values); fclose($fp); } } } if(isset( $_GET['asiOutputSelect']) ) { $asiOutput = $_GET['asiOutputSelect']; $intInput = intval($asiOutput); if (is_numeric($asiOutput) && $intInput == $asiOutput && ( $asiOutput < 0 || $asiOutput > 6) ) { echo "Command Failed - Value Out of Range"; } else if( is_numeric($asiOutput) &&($asiOutput >= 0 && $asiOutput <= 6 && $intInput == $asiOutput ) ) { echo "Command Done - asiOutputSelect="; echo $asiOutput; $outPutString = ' "asiOutputSelect": '.$asiOutput.", \r\n"; // echo $outPutString; writeIt( "asiOutputSelect", $outPutString); }else { echo "Command Failed - Value Not Accepted"; } }else if(isset( $_GET['remuxInputMask']) ) { $remuxInput = $_GET['remuxInputMask']; $intInput = intval($remuxInput); if (is_numeric($remuxInput) && $intInput == $remuxInput && ( $remuxInput < 0 || $remuxInput > 7) ) { echo "Command Failed - Value Out of Range"; } else if( is_numeric($remuxInput) &&($remuxInput >= 0 && $remuxInput <= 7 && $intInput == $remuxInput ) ) { echo "Command Done - RemuxInputMask="; echo $remuxInput; $outPutString = ' "remuxInputMask": '.$remuxInput.", \r\n"; // echo $outPutString; writeIt( "remuxInputMask", $outPutString); }else { echo "Command Failed - Value Not Accepted"; } } else if(isset( $_GET['remuxBitrate']) ) { $remuxBitrate = $_GET['remuxBitrate']; $intInput = intval($remuxBitrate*10000); $remuxBitrate =$intInput/10000; if (is_numeric($intInput) && ( $intInput < 500 || $intInput > 1000000) ) { echo "Command Failed - Value Out of Range"; } else if( is_numeric($intInput) &&($intInput >= 500 && $intInput <= 1000000) ) { echo "Command Done - RemuxInputMask="; echo $remuxBitrate; $outPutString = ' "remuxBitrate": '.$remuxBitrate.", \r\n"; // echo $outPutString; writeIt( "remuxBitrate", $outPutString); }else { echo "Command Failed - Value Not Accepted"; } } ?>