Hi,
I've written a small CGI application which tries to connect to a MySQL server. The application writes "Success" on the standard output if the connection is succesful or "Failure" if the connection fails.
When I execute the application in a console (/opt/lampp/cgi-bin/test.cgi), "Success" is written. This shows my program and the MySQL server are both OK. When I call the CGI application from a browser (http://myserver/cgi-bin/test.cgi), "Failure" is written. The problem is libmysqlclient.so can't be loaded for a reason I don't understand. The user who runs Apache is allowed to run the application and I added "SetEnv LD_LIBRARY_PATH /opt/lampp/cgi-bin" in /opt/lampp/etc/httpd.conf (/opt/lampp/cgi-bin is the directory where libmysqlclient.so is copied).
Where does the problem stem from ? Any idea ?
Many thanks in advance.