title: How can I configure PHP 7.4 on Apache?
body: <p>I am trying to configure PHP 7.4 and Apache 2.4 on my machine, but it is returning the following error:</p>
  <pre><code>httpd.exe: Syntax error on line 542 of C:/XIDServer/Apache24/conf/httpd.conf: 
  Can't locate API module structure 'php7_module' in file C:/XIDServer/php/php7.dll: No error
  </code></pre>
  <p>The bottom of my httpd.conf has the code:</p>
  <pre><code># PHP7 module
  AddHandler application/x-httpd-php .php
  AddType application/x-httpd-php .php .html
  LoadModule php7_module &quot;C:/XIDServer/php/php7.dll&quot;
  PHPIniDir &quot;C:/XIDServer/php&quot;
  </code></pre>
  <p>I've done already:</p>
  <ul>
  <li>Copy/paste php7.4 on the location: 'C:\XIDServer\php'</li>
  <li>Edited the php.ini file on 'C:\XIDServer\php\php.ini', enabling some modules:</li>
  <li>extension=curl</li>
  <li>extension=gd2</li>
  <li>extension=mbstring</li>
  <li>extension=mysql</li>
  <li>extension=pdo_mysql</li>
  <li>extension=xmlrpc</li>
  <li>Created the environment variable for php appointing to 'C:\XIDServer\php'</li>
  <li>Copy/paste Apache 2.4 64 bits to the folder: 'C:\XIDServer\Apache24'</li>
  <li>Edited the httpd.conf file, to appoint to the new location ('C:\XIDServer\Apache24')</li>
  <li>Installed the Windows Service of Apache 2.4</li>
  <li>Added the above lines on the bottom of file 'httpd.conf'</li>
  </ul>
  <p>I'm doing it on a Windows Server 2012 machine.</p>