Installing Apache + PHP + MySQL


Recommended Posts

hi all :)

I have one question about MySQL. When I am installed it, I have already some users. There are: "@%", "@localhost", "root@%", "root@localhost". What is this means? :huh:

Can I make only 1 user with all privileges?

post-107-1095335600.jpg

Edited by RaiderOnline
hi all :)

I have one question about MySQL. When I am installed it, I have already some users. There are: "@%", "@localhost", "root@%", "root@localhost". What is this means? :huh:

Can I make only 1 user with all privileges?

The format is this: user@hostmask

"%" is a wild card. A blank username and a wildcard after the "@" means that "@%" is an anonymous user that can connect to your server from any host. I'd advise deleting the account. I'd advise deleting the anonymous user that can connect from localhost too. So, delete "@localhost" also.

"root@%" Means that root can connect from any host. You may or may not want this. Consider allowing root to connect from localhost only, or only from a box on the LAN. For example:

"root@192.168.0.%"

I would advise you to create a user for your own use, with priviledges granted for specific databases only.

  • 1 month later...
Is there a way to do the same thing for PHP 5?

584883037[/snapback]

I don't recommend using PHP5 to any novice users, as the only feature that catches my eye is very good OOP support. But, just change the code in httpd.conf to:

LoadModule php5_module "C:/PHP/php5apache2.dll"
AddType application/x-httpd-php .php

and copy php5ts.dll to your C:\WINDOWS\system32 directory.

PHP 5 is actually better to start learning now, as it is still in an early age, so by the time you have learned some of the things needed in scripts a stable release will be out and you can.

Also, since you install PHP, you want Apache to recognize index.php and make it the first page you see when you visit the directory, so you would have to do this aswell:

Open C:/Apache2/conf/httpd in Wordpad or Notepad or whatever you use and find:

DirectoryIndex

and after that you have to add

index.php

If you use home.php or something different just add home.php, etc.

The format is this: user@hostmask

"%" is a wild card. A blank username and a wildcard after the "@" means that "@%" is an anonymous user that can connect to your server from any host. I'd advise deleting the account. I'd advise deleting the anonymous user that can connect from localhost too. So, delete "@localhost" also.

"root@%" Means that root can connect from any host. You may or may not want this. Consider allowing root to connect from localhost only, or only from a box on the LAN. For example:

"root@192.168.0.%"

I would advise you to create a user for your own use, with priviledges granted for specific databases only.

584575295[/snapback]

wow :woot: thanks :D Now I can understand all this stuff :p

  • 3 weeks later...

Somehow it does not work for me...apache works fine....then on to step 2 PHP .... i cant'get that to work...

I did all that is listed in the guide

get this error

LoadModule takes two arguments, amodule name and the name of a shared object file to load it from

Edited by DrRip
  • 2 weeks later...
  • 1 month later...

Nice tutorial!!!

Although after i downloaded the php (installer exe) i found that none of the directories such as sapi and files such as php.ini-recommended were in the c:\php directory so i just downloaded the Zip file and extracted it in and all was well.

Thanks again!

  • 4 weeks later...
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.