localhost

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

User avatar
sguy
New php-forum User
New php-forum User
Posts: 63
Joined: Sat Aug 09, 2003 11:26 pm

localhost

Postby sguy » Thu Aug 28, 2003 5:04 am

how to change the username & password, as i know, "root" & "" are the default username & password.

$Connect = mysql_connect("localhost", "root", "");

User avatar
swirlee
Moderator
Moderator
Posts: 2272
Joined: Sat Jul 05, 2003 1:18 pm
Location: A bunk in the back
Contact:

Postby swirlee » Thu Aug 28, 2003 6:29 am

Next time try the documentation first, please.

User avatar
tryton
New php-forum User
New php-forum User
Posts: 49
Joined: Wed Jul 09, 2003 8:25 am
Location: Joze
Contact:

Postby tryton » Thu Aug 28, 2003 6:33 am

To connect to the mysql client program:

mysql -u root -p

If you did not set a root password, just hit return. If you did, then enter your password.

Now use the grant command in mysql to set up a user to access mysql.

You can set the root password using grant, or more easily using
mysqladmin as follows:

mysqladmin -u root password MyNewPassword

NOTE: password in this is a command, MyNewPassword is what you want for your new password or you could use the SET Password SQL command.

User avatar
ruturajv
php-forum Super User
php-forum Super User
Posts: 1280
Joined: Sat Mar 22, 2003 9:42 am
Location: Mumbai, India
Contact:

mysql

Postby ruturajv » Thu Aug 28, 2003 9:26 pm

check the mysql db and check the user table
shows all the permission, grants, etc.


Return to “PHP coding => General”

Who is online

Users browsing this forum: No registered users and 1 guest

cron