Hello All,
I've recently installed APEX. Everything from "apex" development point of view works just fine. But I amm having a hard time setting up/enabling CGI/Perl script in the Apache server.
I have used the standard setup therefor, my http server is http://myserver:7777/pls/apex. Now I've modified my http.conf file with the follwoing entries:
AddType application/x-httpd-cgi .cgi
AddType application/x-httpd-cgi .pl
ScriptAlias /cgi-bin/ "/opt/oracle/product/10.2.0/apex/Apache/Apache/images/cgi-bin/"
# "/opt/oracle/product/10.2.0/oms10g/Apache/Apache/cgi-bin" should be changed to whatever your ScriptAliased
# CGI directory exists, if you have that configured.
#
<Directory "/opt/oracle/product/10.2.0/apex/Apache/Apache/images/cgi-bin">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>
I have change the permission on the folder and create a file called test.pl. When I run it I always get 500 Internal error. After checking the logs it complains about some premature headers and then states that the file does nto exist. This should really not be the case, because the test.pl is just about the simplest form possible and the apache settings ( at least I think, are to be correct). I test this by doing:
http://myserver:7777/cgi-bin/test.pl
#!/usr/bin/perl
print "Content-type: text/plain\n\n";
print "testing...\n";
Did I go wrong somewhere? Can anybody direct me in the correct direction. I have also ran the following to get some info on my env.
begin
owa_util.print_cgi_env;
end;
/
Here is the output:
PLSQL_GATEWAY = WebDb
GATEWAY_IVERSION = 3
SERVER_SOFTWARE = Oracle-Application-Server-10g/10.1.2.0.2 Oracle-HTTP-Server
GATEWAY_INTERFACE = CGI/1.1
SERVER_PORT = 7777
SERVER_NAME = myserver
REQUEST_METHOD = POST
PATH_INFO = /wwv_flow.show
SCRIPT_NAME = /pls/apex
REMOTE_ADDR = 10.6.100.47
SERVER_PROTOCOL = HTTP/1.1
REQUEST_PROTOCOL = HTTP
REMOTE_USER = APEX_PUBLIC_USER
HTTP_CONTENT_LENGTH = 292
HTTP_CONTENT_TYPE = application/x-www-form-urlencoded
HTTP_USER_AGENT = Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.8.1.20) Gecko/20081217 Firefox/2.0.0.20
HTTP_HOST = myserver:7777
HTTP_ACCEPT = text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
HTTP_ACCEPT_LANGUAGE = en-us,en;q=0.5
HTTP_ACCEPT_CHARSET = ISO-8859-1,utf-8;q=0.7,*;q=0.7
HTTP_REFERER = http://myserver:7777/pls/apex/f?p=4500:1003:1620410303274728::NO:::
HTTP_ORACLE_ECID = 81038208787,1
HTTP_ORACLE_CACHE_VERSION = 10.1.2
WEB_AUTHENT_PREFIX =
DAD_NAME = apex
DOC_ACCESS_PATH = docs
DOCUMENT_TABLE = wwv_flow_file_objects$
PATH_ALIAS =
REQUEST_CHARSET = UTF8
REQUEST_IANA_CHARSET = UTF-8
SCRIPT_PREFIX = /pls
HTTP_COOKIE = LOGIN_USERNAME_COOKIE=admin; ORA_WWV_REMEMBER_UN=ADMIN:ORIFLAME; ORA_WWV_USER=7E9E816ED5CDC688; ys-active_tab=s%3Atab_1;ys-ext-comp-1026=o%3Acollapsed%3Db%253A1; ys-ext-comp-1081=o%3Awidth%3Dn%253A800%5Eheight%3Dn%253A465%5Ex%3Dn%253A240%5Ey%3Dn%253A108; ys-east-panel=o%3Acollapsed%3Db%253A0; ys-purchase-panel=o%3Acollapsed%3Db%253A0; ys-chart-region-1=o%3Acollapsed%3Db%253A0; WWV_CUSTOM-F_2787700778075484_123=1F474351E340C827; ys-ext-comp-1286=o%3Awidth%3Dn%253A1100%5Eheight%3Dn%253A652%5Ex%3Dn%253A90%5Ey%3Dn%253A117
Thank you in advance for any assitance anybody can provide.
Regards
Jan