kurt.santo Posted July 21, 2007 Share Posted July 21, 2007 I want to download the Apache web server to my computer to learn PHP at home. On the website "http://httpd.apache.org there are so many files that I am lost, which is the one I need to download... Any ideas?Kurt Link to comment Share on other sites More sharing options...
boen_robot Posted July 21, 2007 Share Posted July 21, 2007 The Win32 Binary. This is a compiled (ready to use) version of Apache for windows. The current version is Apache 2.2.4. Link to comment Share on other sites More sharing options...
kurt.santo Posted July 21, 2007 Author Share Posted July 21, 2007 The Win32 Binary. This is a compiled (ready to use) version of Apache for windows. The current version is Apache 2.2.4.I read in a book I should not use version 2 and stick to 1. Obviously, I do not know when Larry Ullmann wrote the book exactly. So, it is ok now to go for verion 2? Then it always says [PGP] [MD5] behind. I understand the first one is some sort of key to identify the download source?kurt Link to comment Share on other sites More sharing options...
boen_robot Posted July 21, 2007 Share Posted July 21, 2007 Earlier version of PHP didn't supported Apache 2.2 versions. That's why he said that. But at least since PHP 5.2.0, there is support for Apache 2.2 as well.The MD5 tests if the file you downloaded is downloaded without errors. There are programs that can do this comparrison by using the MD5, but I don't know of any. Link to comment Share on other sites More sharing options...
jhecht Posted July 21, 2007 Share Posted July 21, 2007 if you want to be a real lazy person, http://apache2triad.net/, or http://apachefriends.org/, or http://appservnetwork.com/ . Takes out all the guesswork for it. Link to comment Share on other sites More sharing options...
Synook Posted July 22, 2007 Share Posted July 22, 2007 If you don't want to use your computer as a actual server for other people to view your pages from, you could also get a pre-packaged solution that incorporates Apache, PHP and SQL servers into one distribution, such as Easy-PHP. That way, you can be really lazy Link to comment Share on other sites More sharing options...
kurt.santo Posted July 22, 2007 Author Share Posted July 22, 2007 If you don't want to use your computer as a actual server for other people to view your pages from, you could also get a pre-packaged solution that incorporates Apache, PHP and SQL servers into one distribution, such as Easy-PHP. That way, you can be really lazy Not lazy, just clueless;-)Do you use the mentioned software yourself? Then, after completion of my site and upload to a web hosting company: Could there be many issues if I use different versions (MySQL, PHP and Apache)?Kurt Link to comment Share on other sites More sharing options...
boen_robot Posted July 22, 2007 Share Posted July 22, 2007 Not lazy, just clueless;-)Do you use the mentioned software yourself? Then, after completion of my site and upload to a web hosting company: Could there be many issues if I use different versions (MySQL, PHP and Apache)?KurtPossibly. Especially if you rely on some of PHP5's new features such as file_put_contents() and the MySQLi extension, and eventually end up on a PHP4 host that couldn't possibly offer them. Link to comment Share on other sites More sharing options...
kurt.santo Posted July 22, 2007 Author Share Posted July 22, 2007 Possibly. Especially if you rely on some of PHP5's new features such as file_put_contents() and the MySQLi extension, and eventually end up on a PHP4 host that couldn't possibly offer them.Guess I stay on the safe side and do not use the MySQLi extension...:-)Kurt Link to comment Share on other sites More sharing options...
jhecht Posted July 22, 2007 Share Posted July 22, 2007 Guess I stay on the safe side and do not use the MySQLi extension...:-)I hate the mysqli extensions. They just seem kinda pointless to me. And all of the things i mentioned earlier do what synook said. I believe that appservnetwork.com has 2 versions, php4 and php5 but its been a while since i've gone there(i use mainly apache2triad and Xampp). And even then i'm sure you can look back into their archives to find a php version 4 distribution. Link to comment Share on other sites More sharing options...
justsomeguy Posted July 22, 2007 Share Posted July 22, 2007 I hate the mysqli extensions. They just seem kinda pointless to me.The mysqli extension supports features of more recent versions of MySQL that the older mysql extension does not support. If you want to use some of the newer features of MySQL, you need to use mysqli. Link to comment Share on other sites More sharing options...
jhecht Posted July 22, 2007 Share Posted July 22, 2007 The mysqli extension supports features of more recent versions of MySQL that the older mysql extension does not support. If you want to use some of the newer features of MySQL, you need to use mysqli.I know what they do, i just don't like them. I juse use SELECT's and subselects, which has been available since i've used MySQL(how many eons ago..). It's not that i'm ignorant to the fact of what they are, i just think they are a bit pointless considering there are very few people who will ever really use the mysqli extensions when the mysql extensions work just fine. Link to comment Share on other sites More sharing options...
shujjah Posted July 22, 2007 Share Posted July 22, 2007 i think u shud just install Xamp it has php , Apache, MySql, phpmyadmin, filezilla, and lots more its great i am using it . and free and easy to setup Link to comment Share on other sites More sharing options...
justsomeguy Posted July 22, 2007 Share Posted July 22, 2007 Well yeah, if all you are doing is select, insert, and update then you don't need mysqli. mysqli is really only for people who are using the more advanced features that only the latest MySQL version supports. Also, prepared mysqli statements are faster then using mysql_query. Link to comment Share on other sites More sharing options...
kurt.santo Posted July 23, 2007 Author Share Posted July 23, 2007 Well yeah, if all you are doing is select, insert, and update then you don't need mysqli. mysqli is really only for people who are using the more advanced features that only the latest MySQL version supports. Also, prepared mysqli statements are faster then using mysql_query.What advanced features would that be? I am clueless right now (hopefully not for long), but would like to start off with all necessary tools...Kurt Link to comment Share on other sites More sharing options...
boen_robot Posted July 23, 2007 Share Posted July 23, 2007 Now that's what I call "to open a can of worms" . I just mentioned MySQLi and we went off on a whole other subject. I was just giving a sample. PHP has a list of the new functions in PHP5. If you rely on any of them (I know I do), you will need a host with PHP5 or at least try to install PEAR PHP_compat on the server.I don't know about the new features MySQLi offers, but I like the fact it's OOP . Link to comment Share on other sites More sharing options...
justsomeguy Posted July 23, 2007 Share Posted July 23, 2007 What advanced features would that be? I am clueless right now (hopefully not for long), but would like to start off with all necessary tools...KurtThis Zend article will help:http://devzone.zend.com/node/view/id/686 Link to comment Share on other sites More sharing options...
kurt.santo Posted July 24, 2007 Author Share Posted July 24, 2007 This Zend article will help:http://devzone.zend.com/node/view/id/686 Cheers:-)Kurt Link to comment Share on other sites More sharing options...
kurt.santo Posted September 2, 2007 Author Share Posted September 2, 2007 Cheers:-)KurtHi guys,Finally coming to terms I installed MySQL, Apache and PHP separate (want to try it the hard way;-). Trying to start the web server (after I stoped it) I receive the following error message:httpd.exe: Syntax error on line 115 of C:/Apache/httpd.conf: Cannot load C:/php/php5apache2.dll into server. The specified module could not be found.In Apache's config file I inserted as adviced (also tried without the double quotation marks):LoadModule php5_module "C:/php/php5apache2.dll"PHPIniDir "C:/php"php5apache2.dll is in the specified location. Also, I copied php5ts.dll to Apache's bin location and copied php.ini-dist to C:\Windows, where I renamed it to php.ini.I am running Windows Vista Home edition. Any ideas where the error message comes from?Kurt Link to comment Share on other sites More sharing options...
boen_robot Posted September 2, 2007 Share Posted September 2, 2007 Instead of copying the php5ts.dll and php.ini files to C:/WINDOWS, add the following line in httpd.conf: SetEnv PHPRC "c:/php" Also, for Apache 2.2.* series, you need to use the php5apache2_2.dll instead, making your line: LoadModule php5_module "C:/php/php5apache2_2.dll" php5apache2.dll is for the Apache 2.0.* series of Apache.Note that with the option PHPIniDir "C:/php" The php.ini file PHP will respect will be the one in that folder (PHP's folder in that case).Here's a tip. If you want to make yourself more comfortable when updating to a new version of PHP or Apache or reinstalling Windows (it happens), store PHP on another HDD drive/partition if you have one. Say in "D:" for instance. Create a new *.conf file somewhere on that other drive (say in "D:" itself) with only PHP's setting in it, like so:D:/php.conf LoadModule php5_module "D:/php/php5apache2_2.dll"AddType application/x-httpd-php .php .php5SetEnv PHPRC "d:/php"PHPIniDir "D:/" and move the php.ini into "D:/" too.Now when you want to update to a newer PHP version, you only need to shut down Apache, extract the new PHP over the old one (or better yet - delete the old one and then add the new) and start Apache again. If you update Apache, or reinstall Windows (and thus Apache), you can reenable PHP by just adding Include "D:/php.conf" into httpd.conf. I even go a step further by including that file into "apache.conf" and store that into "D:/" too, so that when I reinstall Windows, I include apache.conf and enable PHP + my custom Apache settings. Link to comment Share on other sites More sharing options...
kurt.santo Posted September 2, 2007 Author Share Posted September 2, 2007 Instead of copying the php5ts.dll and php.ini files to C:/WINDOWS, add the following line in httpd.conf:SetEnv PHPRC "c:/php" Also, for Apache 2.2.* series, you need to use the php5apache2_2.dll instead, making your line: LoadModule php5_module "C:/php/php5apache2_2.dll" php5apache2.dll is for the Apache 2.0.* series of Apache.Note that with the option PHPIniDir "C:/php" The php.ini file PHP will respect will be the one in that folder (PHP's folder in that case).Here's a tip. If you want to make yourself more comfortable when updating to a new version of PHP or Apache or reinstalling Windows (it happens), store PHP on another HDD drive/partition if you have one. Say in "D:" for instance. Create a new *.conf file somewhere on that other drive (say in "D:" itself) with only PHP's setting in it, like so:D:/php.conf LoadModule php5_module "D:/php/php5apache2_2.dll"AddType application/x-httpd-php .php .php5SetEnv PHPRC "d:/php"PHPIniDir "D:/" and move the php.ini into "D:/" too.Now when you want to update to a newer PHP version, you only need to shut down Apache, extract the new PHP over the old one (or better yet - delete the old one and then add the new) and start Apache again. If you update Apache, or reinstall Windows (and thus Apache), you can reenable PHP by just adding Include "D:/php.conf" into httpd.conf. I even go a step further by including that file into "apache.conf" and store that into "D:/" too, so that when I reinstall Windows, I include apache.conf and enable PHP + my custom Apache settings. Now I am getting somewhere... But when I go to Start, Run and enter "NET START APACHE2" it says "System error 5 occured. Access denied." When I start/stop the Apache server over Programs a pop-up window comes and disappears very quickly, so I cannot see any message. I guess this is because I deleted the Apache error box from the Windows Start menu. Someone told me to do so, but I regret it now. It might give me a clue...Why is access denied? And could I turn the error box back on, so that it stays for a while? I would also like to follow your hint with the partition. How do you do partition your harddrive? I appreciate your time...Kurt Link to comment Share on other sites More sharing options...
boen_robot Posted September 2, 2007 Share Posted September 2, 2007 Now I am getting somewhere... But when I go to Start, Run and enter "NET START APACHE2" it says "System error 5 occured. Access denied." When I start/stop the Apache server over Programs a pop-up window comes and disappears very quickly, so I cannot see any message. I guess this is because I deleted the Apache error box from the Windows Start menu. Someone told me to do so, but I regret it now. It might give me a clue...Why is access denied? And could I turn the error box back on, so that it stays for a while? I would also like to follow your hint with the partition. How do you do partition your harddrive? I appreciate your time...KurtTry to do it as administrator. You might not have privilages.Go to "Start > Programs > Apache HTTP Server 2.2.4 > Control Apache Server". While there, right click on "Start" and select "Run as Administrator". Link to comment Share on other sites More sharing options...
kurt.santo Posted September 2, 2007 Author Share Posted September 2, 2007 Try to do it as administrator. You might not have privilages.Go to "Start > Programs > Apache HTTP Server 2.2.4 > Control Apache Server". While there, right click on "Start" and select "Run as Administrator".Now it says: "...make_socket could not bind to port 0.0.0.0:80, no listening socket available, shutting down":-( And how could you run as administrator from comand promt?Kurt Link to comment Share on other sites More sharing options...
justsomeguy Posted September 2, 2007 Share Posted September 2, 2007 You could run the entire command prompt as admin, create a shortcut to cmd.exe and you can right-click the shortcut and run as another user. Also, the error says that Apache can't listen on port 80, the reason is probably because another web server is running. If you have IIS set up, you will need to shut that down first. Link to comment Share on other sites More sharing options...
kurt.santo Posted September 2, 2007 Author Share Posted September 2, 2007 You could run the entire command prompt as admin, create a shortcut to cmd.exe and you can right-click the shortcut and run as another user. Also, the error says that Apache can't listen on port 80, the reason is probably because another web server is running. If you have IIS set up, you will need to shut that down first.I am not running any other web server (at least I did not install any one). Double-checked in my software list... What else could use port 80 or how would I find out?Kurt Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.