HI:
Ya, That really works! At least for php 4.0.1. Are you sure you have following the instruction of my mini-howto at:
http://www.silen.net/openlink-php-odbc.txt
?
You have to put .odbc.ini (installed in the process of openlink installation) under the home directory of the user who need to use openlink-php. and don't forget to edit your /etc/udbc.ini to add data source. You can test openlink connectivity like this (run php like normal binary):
$ php
<?
echo $conn_id = odbc_connect("dsn=THE_DSN_NAME_SET_IN_YOUR_UDBC_INI",
"YOUR_DB_USER_NAME","YOUR_DB_USER_PASSWORD");
D( press ctrl+D )
( wait for a while to connect, then ...)
Content-type: text/html
Resource id #1
$ _
If you compile php4 with apache, keep in mind which user role your apache is run under. Normally, that is "nobody", in Linux, the home of nobody user is usually "/", so you got to put a .odbc.ini under "/"...
regards,
Silen