Hi,
please post the contents of c:\oracle and c:\oracle\ora92. Try to change the code to:
<?
putenv("ORACLE_SID=JOHN");
putenv("ORACLE_BASE=c:\\oracle");
putenv("ORACLE_HOME=c:\\oracle\\ora92");
putenv("TNS_ADMIN=c:\\oracle\\ora92\\network\\admin");
putenv("ORA_NLS33=c:\\oracle\\ora92\\ocommon\\nls\\admin\\data");
putenv("NLS_LANG=German_Germany.WE8ISO8859P1");
if ($c=ora_logon("system@JOHN","john2")) {
echo "Successfully connected to Oracle.<br>\n";
ora_logoff($c);
} else {
echo "Oracle Connect Error " . ora_error()."<br>\n";
}
echo "john<br>\n";
?>
You might need to adjust the variables depending on the Oracle installation. The NLS_LANG variable has to be adjusted to your oracle instance settings.
Did you adjust tnsnames.ora so that it includes an entry for the instance you want to connect to ?
Another way would be to define the environment variables as windows environment variables. You wouldn't then need to define them in your php scripts.