SQL Databse credetials?

Hey, i'm trying to connect to SQL database with this code, but it refuses to connect what ever i type in there, i don't know wich user/password/ip i need to type in.

<?php
date_default_timezone_set('UTC');

define("", "");

$db_host     = "";
$db_user     = "";
$db_password = "";
Marcus PAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Ryan ChongBusiness Systems Analyst , ex-Senior Application EngineerCommented:
but it refuses to connect what ever i type in there, i don't know wich user/password/ip i need to type in.
well, you need to know what that error message means, share it here if necessary

it could be different reasons why you can't connect to your database via your php codes.
1
David Johnson, CD, MVPOwnerCommented:
it also depends upon the database itself. Each database product has different ways of connecting and deciding what IP addresses are allowed. .
1
Ryan ChongBusiness Systems Analyst , ex-Senior Application EngineerCommented:
if you mean connecting to:

MS SQL
Sample code to connect to an MS SQL database using php
https://support.winhost.com/kb/a687/sample-code-to-connect-to-an-ms-sql-database-using-php.aspx

MySQL
How to connect to MySQL using PHP
https://www.a2hosting.sg/kb/developer-corner/mysql/connect-to-mysql-using-php
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Ryan ChongBusiness Systems Analyst , ex-Senior Application EngineerCommented:
any further assistance needed here?
0
Ryan ChongBusiness Systems Analyst , ex-Senior Application EngineerCommented:
as proposed
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
SQL

From novice to tech pro — start learning today.