Info: I am trying to read and write to a file at the same time, but if i have r+
it will only write and if i only have r
it will only read, but i need it do both so it can get the info into the document and the info out of it to a cmd window.
Question: Is there i way i can do this and that both will work?
$outputMXA = shell_exec($commandMXA);
$fhMXA = fopen('MXA.txt','r+');
fwrite($fhMXA,$outputMXA);
$MXA = fgets($fhMXA);