Add this rows at the end of your httpd.conf:
CGI Binary mode:
CGI Binary Settings
ScriptAlias /masquerade_dir/ "c:/php or folder where is php.exe file/"
AddType application/x-httpd-php .php
Action application/x-httpd-php "/masquerade_dir/php.exe"
The first row needs to masquerade the real folder where you put php.exe. In a CGI exploit the hacker check for folder named masquerade_dir not for folder php (security needed)
The secon and third row allow to associate .php extension of your PHP scripts for running with php.exe.
Check, before restarting Apache Web Server that you have copied the file php4ts.dll and set your php.ini file in C:\Windows\System32 directory.
Create a file named test.php like the following:
<?php
phpinfo()
and run on browser. If all is right you can get information about your PHP, Apache and Windows Environment variables.
I suggest you to read the chapter:
Installing PHP on Windows with Apache 1.3.x
if you have further problems.