LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Apache and PHP for total beginner (https://www.linuxquestions.org/questions/linux-newbie-8/apache-and-php-for-total-beginner-418238/)

legendaryhwk 02-21-2006 11:27 PM

Apache and PHP for total beginner
 
hi ppl! new guy to linux here. so here's the deal.. i have this really old laptop at home, and am wondering if maybe it can be a linux server for a website??? the specs are:

RAM: 64MB
HD: 6 GB
Toshiba Satellite
and thats about all i can remember. i plan on installing Mandriva 2006 Free soon, and totally annihilating the windows 98 thats on there now. but it may be wizer to use a lighter version of linux (if so, do tell!).

so, my first question is:
1) can my old laptop become a server, and which distro should i use on it?

now.. once that question is answered..
i am a TOTAL noob at apache and php, like i know NOTHING about them, only that apache is a webserver and php is an advanced programming language (btw, i can program in C++...)
so, any good basic sites?
and work my way up from there?
i know php[dot]net is a good site, but theres not really beginner SETUP stuff there.. at least i didnt see.

thanks for your help!
really wanna get this going...
oh, and if the server doesnt work on my other laptop, the second question still aplies.. :Pengy:
thx!
cya!

timmeke 02-22-2006 02:27 AM

A better site to start off with PhP would perhaps be
http://php4all.net/

It contains a link to php.net and a few other interesting PhP related sites too.
php.net is not so newbie-friendly at first sight, but it does contain a wealth of info on PhP and it's commands. So you'll probably go back to it someday.

As for apache, you should go to http://apache.org. That's the main site from the Apache foundation and it contains plenty of docs and tutorials on how to set up the Apache webserver (httpd) and probably mentions how you can add modules like mod_php (used to support PhP webpages on the webserver).

As to which Linux distro you need. A light-weigth distro would be a good choice if you were going for performance. But those distros may be a little harder to configure. So it depends more or less on your Linux experience.
Almost any distro nowadays comes with the apache webserver, I think. So, you can pretty much choose whatever distro you like.

So, yes, your laptop could become a webserver for instance for a small local network.
Using it to host websites for the entire internet may be a little too demanding, if your sites will get plenty of visitors. But you can start off with your laptop and possibly move on later if the load becomes too high.

The only downside I see to using a laptop as a server is that the laptop will need to stay connected to your network all the time in order for the websites to be accessible all the time. So you can't take it with you wherever you go anymore, which beats the primary purpose of having a laptop.

RedShirt 02-22-2006 07:50 AM

That laptop is running big time low on ram. I would upgrade if I were you. Most current linux distrobutions, especially for a server, will want more than 64. That sounds like my old toshiba down to a tea. I have a Satelitte 2669DVD, and I upped it to 256. This was a long time ago but didn't cost much to do it. If you don't intend to upgrade, go with a small distro, or do a very minimal install of a larger one. You only have a 6gig drive to work with, and you only have 64Mb of ram to work with. That isn't a lot in modern standards.

For all my php needs I use phpbuilder.net. I have yet to find a better site with more people willing to help you out.

legendaryhwk 02-22-2006 04:28 PM

wow thx for the help, ill go check those sites out as soon as i have time.
about the laptop:
u see, its so old that i DONT carry it around .. hehehe. i only use it for simple stuff like websites and msn, at home, on a wireless network. ive considered updating the ram, but it will only take 128 max.. i guess it might make the diff now that im considering making it a webserver. and i dont think ill be expecting a very large number of ppl accessing it, but if it ends up surpassing my expectations, i can just move on to a better server :D
ill at least already have the site ready.. haha

nice..
thx again!
any more help appreciated!

legendaryhwk 02-23-2006 12:10 AM

oh and one more thing! im guessing PHP 5 is better than PHP 4????????

silmaril8n 02-23-2006 12:21 AM

I personally still use PHP4. Go with 5 if you want better object-oriented support.

Also - if you run the laptop as a server I'd suggest using a wired connection over wireless.

RedShirt 02-23-2006 07:13 AM

5 better than 4? Hmmm... How about 5 different than 4. It does have more support for things, but I guess it all depends. I learned 3. And then 4, And haven't done a lot in 5, but some of what you can do in 5 can't be done in earlier versions, which is not all too shocking. I suppose it is probably best to start new, like learning HTML wouldn't be half as useful as going straight to XHTML and CSS now.

I would recommed learning the latest just because it will probably have better training support being more current.


All times are GMT -5. The time now is 11:03 PM.