I have just installed Apache 2.4 on Windows Server 2016 Datacenter (AWS EC2 instance). Web server seems to be working fine, I can access 'http://localhost/' and get the 'It Works!' page.
Location: C:\Apache24\
I then installed LiveCode Community Server by unzipping contents to Location: C:\LiveCode
The executable in this folder is 'livecode-community-server.exe'
My site folder is Location: C:\MySite
I then modified the httpd file as follows
Change DocumentRoot to
DocumentRoot "c:/mysite"
Change Directory directive to
<Directory "c:/mysite">
Add the following into the Directory directive
Order allow,deny Allow from all AddHandler livecode-script .lc Action livecode-script "/livecode-cgi/livecode-community-server.exe"
Add the following new Directory directive
<Directory "c:/livecode"> Options ExecCGI Order allow,deny Require all granted Allow from all </Directory>
Add the following into "IfModule alias_module"
ScriptAlias /livecode-cgi/ "c:/livecode/"
After saving httpd and then restarting Apache, I open a browser and go to the URL "http://localhost/test.lc"
The response from the browser is simply the 2 characters "MZ" - (when viewing source just those 2 characters are sent back)
In this case 'test.lc' is a file in C:\MySite. This response is given for any .lc file in this folder. Any .html file in this folder works as expected.
There is no entry the Apache error.log. The access.log has the following entry
::1 - - [23/Mar/2017:14:27:01 +0000] "GET /test.lc HTTP/1.1" 200 3
Googling this reveals absolutely nothing so I can only assume it is some obvious thing I've missed. Any help or hints as to what might be going on would be hugely appreciated.
*Edit: I forgot to mention that the following line is live (not commented out) in the httpd, I presume this is all I need for the CGI module to load?
LoadModule cgi_module modules/mod_cgi.so
*Edit: I have also tried with the following ScriptAlias, and got the exact same result (MZ returned and 200 success code in the access.log)
ScriptAlias /livecode-cgi/livecode-community-server.exe "c:/livecode/livecode-community-server.exe"
*Edit: This post seems to be about the same problem (albeit with perl instead of LiveCode) https://stackoverflow.com/questions/14792978/perl-apache-perl-script-displayed-as-plain-text
The problem seems to be that in Apache 2.4 some radical changes were made that has caused a few problems. Does the linked post help? Thanks again for your time