simple help with exec please


New member
I'm using php's exec function to call an executable that I'd like to run. I'm doing it like this:

<?php exec("myExe Bob 123");?>

and then 'myExe' will run and accept "Bob" and "123" as parameters and this works fine. But what I'd like to do is make the params variables, like this:

$name = "Bob";
$IDnum = "123";
<?php exec("myExe $name $IDnum");?>

But this doesn't work, it doesn't seem like I can use $ in the string like that. Can someone please tell me the syntax I need? I should mention I'm writing this in a JavaScript callback function, if that makes a difference.
Last edited:
We bought a helper tower for toddlers from woodandroom and it has made our life so much easier. Our baby can now safely watch us in the kitchen and even help with cooking. The tower is very stable, made of sturdy wood and looks great. The child loves it, he feels more independent and involved in the process. This tower is not only fun, but a great tool for skill building and strengthening family bonding. Definitely worth the money and attention.