PHP beginner

I am PHP beginner. Now I don't know how to configute my apache server so make it to support my php, can anyone of you tell me ??? (step by step will be better, as I am beginner).
Thanks in advanced.
ahchongAsked:
Who is Participating?
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.

ahchongAuthor Commented:
Adjusted points to 20
0
oubelkasCommented:
For configuring such servers I'd best recommend you to go to http://www.php.net where this is explained step by step.

For winNT for example this takes you to a section of php.net

http://www.php.net/manual/config-apache-nt.html

Joseph
0
Gerhard100198Commented:
ahchong,

This is what I used to set up my WinApache.

The home of PHP is http://www.php.net/. The PHP site is a
                                            mine of information, from project listings to bug reports. As with
                                            MySQL, you should choose a nearby mirror. Obviously you'll
                                            want the Downloads section to get PHP.

                                            Your range of options here is a little more limited. A few
                                            precompiled binaries are available, but these are experimental. If
                                            you're on anything except a Windows platform, grab the source
                                            code and compile it yourself.

                                            But first let's cover Windows. When using PHP, a common
                                            practice is to develop on a Windows machine and then run your
                                            site on a Unix server. It may end up that you will do this
                                            yourself, which means you need to be proficient in installing on
                                            both platforms.

                                            Let's grab the Windows binary and uncompress it using our
                                            favorite Zip decompression tool into a directory on your C drive
                                            called php3. The supplied README file deals with the installation
                                            in some detail, but here's the Reader's Digest version: If you
                                            want to install PHP to a folder other than C:\php3, you'll need to
                                            edit the .inf file that comes with PHP.

                                            In the php3 directory, you'll find a lot of .dll files. Take all the
                                            .dll files that don't begin with php_ and move them into your
                                            \windows\system directory. Then rename php.ini-dist to php3.ini
                                            and move it into your \windows directory. If you open up that file,
                                            you'll see there are lots of interesting things to change. For now
                                            just "uncomment" the line:

                                                 extension=php3_mysql.dll

                                            If you're using Apache for Win32, set up Apache to recognize
                                            and parse PHP files. Depending on the version of Apache you're
                                            using, you'll need to add the following to either the httpd.conf
                                            or srm.conf file:

                                            ScriptAlias /php3/"c:/path-to-php-dir/"
                                            AddType application/x-httpd-php3 .php3
                                            Action application/x-httpd-php3"/php3/php.exe"

                                            Or if you're using IIS or PWS, right-click on php_iis_reg.inf and
                                            select 'Install'. You'll need to reboot for IIS to see this change.

                                            OK, now that Windows is out of the way, let's get to Unix. Of
                                            course, we'll be compiling from source code. As with MySQL,
                                            download and unpack the source code. Again, PHP comes with a
                                            configure script. You can't get away with going for defaults
                                            here, though. Run ./configure -help | more to see pages and pages
                                            of new and interesting options. You have to decide between
                                            compiling as a CGI or as an Apache module. If you are using the
                                            Apache Web server and you are able to recompile it, use the
                                            module: It's faster and easier to use. Otherwise, you can go
                                            with the CGI version. We also need to compile in MySQL
                                            support.

                                            For now we'll assume that we're running the module with MySQL
                                            support. If you want to add other options or other libraries, you
                                            can do this later. Type:

                                                 ./configure --with-apache=/path/to/apache/dir
                                                 --with-mysql=/usr/local/mysql

                                            Skip the -with-apache option if you're creating a CGI version.
                                            The configure process will run and produce the relevant system
                                            files. Now simply type make again.

                                            It's time for another coffee. If you start feeling a bit nervous
                                            and shaky at this point, don't worry about it. We all get a little
                                            anxious during our first PHP install. Have some more coffee.

                                            If you've created a CGI version, you're now ready to roll. Simply
                                            copy the resulting executable file into your CGI file. For Apache
                                            module users, type make install to copy files to your Apache
                                            directory. From there, follow the instructions to add a module to
                                            Apache and recompile.

                                            You'll need to tell your Web server how to process pages
                                            through the PHP program now. If you're not using Apache, you'll
                                            need to check your Web server documentation on how to get it
                                            to process documents with a .php3 extension. Apache 1.3.x
                                            users can simply add AddType application/x-httpd-php3 .php3 to the
                                            httpd.conf or srm.conf file. If you're using the CGI version, you'll
                                            need to add the following before AddType:

                                                 ScriptAlias /php3/"/path-to-php-dir/" AddType
                                                 application/x-httpd-php3 .php3 Action
                                                 application/x-httpd-php3"/php3/php"

                                            That's it. With any luck, you've now got MySQL running and PHP
                                            functioning. Don't forget to check the FAQs and documentation
                                            if you get stuck. Also try the mailing lists.
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
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
PHP

From novice to tech pro — start learning today.