Php Connection with Sql server not working on Production Server -


enter image description here

enter image description here

i working php. want connect php sql server not working on production server.it worked on local machine, installed sql server driver in extension folder of php , activated in php-ini file.i confirmed driver has been loaded production driver hosted in windows server , not linux server.i need assistance,because same script connected local machine cloud sql server same script using connect php application same sql server not working. please, need help. take @ connection script works local machine.

  $servername = "remote sql server ip"; //a.b.c.d    $connectioninfo = array("database"=>"sqlserverdbname", "uid"=>"sqlsvruserid", "pwd"=>"sqlsvrpassword");    $conn = sqlsrv_connect($servername, $connectioninfo);    if($conn){        echo "connection established<br/>";    }else{     echo "connection not established<br/>";     die(print_r(sqlsvr_errors(),true));       } 

?> both php application , other application uses sql server on same domain, while php-app , other-app sub domain. kindly @ this. community anticipated advice/solution

please add server name(host) instead of remote sql server ip $servername = "remote sql server ip";

this solve problem think.


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -