My project requires where i need to generate a front end (php) which has all the data input fiels. And using those data as input, I need to execute a TCL script. Once the execution is done, the php page should be able to get the output of the TCL script and show it.
I have generated a sample script but not able to execute it. can you guys please help me.
Thanks in advance
My php script is:
<!DOCTYPE html>
<html>
<body>
<?php
function print_procedure ($arg) {
echo exec("/usr/bin/tclsh /test.tcl");
}
$script_name='test.tcl';
print_procedure($script_name);
?>
</body>
</html>
My TCL script is:
set a 10
set b 20
set c [expr $a + $b]
return c