开发者

Setting HOSTNAME when connecting to Sybase from PHP

开发者 https://www.devze.com 2023-03-03 11:53 出处:网络
I have an Apache server running PHP 5.3.3.Our sybase ASE servers use HOSTNAME on connect for rudimentary ID and filtering - make sure prod hosts connect to prod, etc.

I have an Apache server running PHP 5.3.3. Our sybase ASE servers use HOSTNAME on connect for rudimentary ID and filtering - make sure prod hosts connect to prod, etc.

Is there any way to have sybase_con开发者_高级运维nect() supply HOSTNAME on connection?

I also have ODBC configured (with DataDirect drivers); or is there a way to supply HOSTNAME on ODBC connects?


Use the source Luke...

The sybase_connect() code takes CT_HOSTNAME info from the INI string "sybct.hostname"

ini_set("sybct.hostname", $_SERVER['SERVER_NAME']);

Worked for me in Apache::PHP

Thanks all.

0

精彩评论

暂无评论...
验证码 换一张
取 消