OCI8 with PHP7 - module not found
<p>I'm currently setting up a Windows 10 Pro x64 machine to work with Apache, PHP and its oci8 extension.
I successfully managed to get oci8 working on OSX 10.11 and Windows 2012 Server before, so I thought I knew what to do. But this was 32bit – now it's 64.</p>

<p>The software now installed is:</p>

<ul>
<li>Apache 2.4.18 x64</li>
<li>PHP 7.0.3 TS x64</li>
<li>Oracle Instant Client x64 (instantclient-basic-windows.x64-12.1.0.2.0)</li>
<li>oci8 2.1.0 TS x64</li>
</ul>

<p>I don't get it to work. The error message is:</p>

<blockquote>
  <p>Warning: PHP Startup: Unable to load dynamic library
  'ext\php_oci8_12c.dll' - Das angegebene Modul wurde nicht gefunden. <em>(Module not found.)</em></p>
  
  <p>in Unknown on line 0</p>
  
  <p>Extension 'oci8' not present.</p>
</blockquote>

<p>I installed the Oracle Instant Client by writing its directory into the PATH variable and copied the php_oci8_12c.dll file to the PHP ext dir and uncommented the corresponding line in the php.ini. Shouldn't that be enough?</p>

<p>I've read many postings here on Stackoverflow and other websites about similar problems, things I've tried:</p>

<ul>
<li>Moving all DLLs to C:\Windows\system32</li>
<li>Include the PHP extension dir in the PATH variable</li>
<li>Re-checked that every component is 64bit</li>
<li>Created ORACLE_HOME and ORACLE_BASE variables (which shouldn't be necessary)</li>
</ul>

<p>If I change the php_oci8_12c.dll x64 to the 32bit one, I get a different error message:</p>

<blockquote>
  <p>Warning: PHP Startup: Unable to load dynamic library 'ext\php_oci8_12c.dll' - %1 ist keine zulässige Win32-Anwendung. <em>(%1 is not a valid Win32 program.)</em></p>
  
  <p>in Unknown on line 0</p>
  
  <p>Extension 'oci8' not present.</p>
</blockquote>

<p>Any ideas what's wrong with all that?</p>

<p>Thank You!</p>