Hello,
I’ve been using iMacro along with PHP for a few years now to do some browser automation. Now I want to use UI Vision, but I can’t open the browser with PHP:
private $pathToLog = "C:\\iMacros2\\imacros-error\\log.txt";
private $pathToApp = "C:\\iMacros\\App2";
private $pathToRun = "\\ui.vision.html";
private $pathToBrowser = "C:\Program Files\Google\Chrome\Application\chrome.exe";
// create TmpMacroFile
$tmpMacroFile = $this->createTmpMacroFile();
$cmd = 'start "' . $this->pathToBrowser . '" "file:\\\\' . $this->pathToApp . $this->pathToRun . '?macro=' . $tmpMacroFile . '&direct=1&savelog=' . $this->pathToLog . '"';
$output = exec($cmd);
// delete TmpMacroFile
unlink($tmpMacroFile);
Currently, the script runs successfully, but no browser opens (at least not in the foreground). The script runs on a WindowsServer2016
Is there a way to run the macro visible in Chrome with PHP on Windows Server 2016? With iMacro this was possible with the function new COM(“imacros”);