0

I have tried this.
Sample hello.php file:

<html>
<head>
  <title>PHP Test</title>
</head>
<body>
  <?php echo '<p>Hello World</p>'; ?> 
</body>
</html>

Sample ex.vbs VBScript file:

Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run "D:\Example\hello.php", 0

When I executed VBScript in command prompt output is not displaying.

Sindhu
  • 420
  • 1
  • 4
  • 16
  • 3
    You can run `php` and pass parameters (similar to http://stackoverflow.com/questions/9520090/how-to-execute-php-code-from-the-command-line), but looking at the body of the post you likely interesting in rendering of web page rather than just running script. Please clarify your question (and show what ways of running php you've already found in addition to one shown) – Alexei Levenkov Jan 19 '17 at 06:31
  • I am executing VBScript file which calls PHP file. I am executing in command prompt like, path\cscript ex.vbs. It is not showing any error. But i should get output as Hello World. – Sindhu Jan 19 '17 at 12:23

0 Answers0