View Full Version : Starting My Journey with PHP
BlueDragon1981 11-17-2005, 12:01 PM I have been looking over the type of coding etc. I'm going to compare coding and experiment with my own forum soon....won't be public for say another year or more. I have had the expected layout drawn out for a year, even before I joined this one....before I joined martial talk actually. (Liked them so much the reason for my own forum became non-existant). Now that I have people that deal with php and sql I though why not ask them questions.
What are the good points about PHP?
What are the bad points or any "pet peeves" you have with PHP?
Is SQL the best choice for a database when working with PHP?
What tips do you have for a beginner?
Silent Bob 11-17-2005, 12:08 PM If you are writing your own forum, check out the existing ones first. You can download several different ones to get an idea on how things are done.
PHP is fast, and efficient, however can bite the beginner hard.
Get a couple references. Visual Guide and the Dummies book are 2 I recommend. Also, have a grasp on MYSQL as well. While there are other 'flavors', MYSQL seems to be the most common in the web environment.
You can install Apache, PHP & MYSQL on Win2000 or later relatively painlessly. Makes for a good developmental station, and this way you don't piss off your web host when your program crashes. :)
Andrew Green 11-17-2005, 12:12 PM What are the good points about PHP?
It is quick, easy to work with, and great for creating pages on the go.
What are the bad points or any "pet peeves" you have with PHP?
It lets you be sloppy in some ways and sloppy code can eat memory
Is SQL the best choice for a database when working with PHP?
Yup, you'll see 2-sides though. Some will tell you mysql, other portsql
What tips do you have for a beginner?
Turn globals off, it's a security thing. Remember that posts and gets are not secure and check the imput before doing anything important with it.
Set up a LAMP server locally, uploading after everychange would suck :D
Use multiple files and only pull them in if they are going to be needed, no sense in processing stuff that won't be used for the page being drawn.
Post questions and problems on boards, a few extra sets of eyes on your code is always helpful.
BlueDragon1981 11-17-2005, 12:13 PM I should do that....what sites allow for me to download php & mysql...my host has where you can set them up but to work with them and see the results without uploading them would be very beneficial.
Andrew Green 11-17-2005, 12:30 PM php.net
mysql.com
I have never set it up on a Windows machine before though, so won't be much help with that :D
Silent Bob 11-17-2005, 04:58 PM also, apache.org
BlueDragon1981 11-17-2005, 05:15 PM Tips on setting apache and php up....before I download them some tips and tricks usually come in handy.
Andrew Green 11-17-2005, 05:20 PM If you have the hard drive space (10gb should be more then enough, 3 or 4 should even be enough) or even a old extra drive lieing around, consider setting up a dual boot system. I can point you to step by step instructions and provide a lot more help ;)
Linux will run things much nicer :D
BlueDragon1981 11-17-2005, 05:50 PM I have a hard drive that only has files on it. ...i have dial - up so I'm waiting for a freind to burn me a copy of linux....rather than download it.
I have installed linux before but would like to have it on the seperate hard drive...do you have instructions on dual boot systems with dual hard drives...an OS on each.
I want windows on one drive and linux on the other. I have a lot of hard drive space on my desktop. 200 GB drive (that only reads 140; i suspect this is because of a motherboard issue) and a 30 GB for the second drive. Laptop only has a 30 gb hard drive.
Apache....is setup hard? Should I do apache, php, and sql on the same physical drive?
Andrew Green 11-17-2005, 06:02 PM It should be fairly simple
Linux will likely recognize Windows and add it to the boot menu automatically.
There is two ways you can do it... well 4 I guess....
Drive 1 -> Windows. Linux will install to the 2nd drive and add a bootloader to the windows drive.
Drive 1 -> Linux. The windows drive will be completely untouched. Windows likes being in the HDA1 position though, so you may have to edit the boot loader file to trick it into thinking it is.
Swap the cable depending on what you want to boot, sloppy but keeps things isolated completely
Boot disk, install linux on #2, don't let it install a boot loader and use a boot disk to tell it to boot off of the second.
Once Linux is installed, you'll be able to install apache, mysql and php from repositories without much trouble at all.
Which Linux distrobution are you looking at?
BlueDragon1981 11-17-2005, 09:04 PM My cousin has Fredora....I have an old version of red hat.....I want to get a couple more but never have the time to download...not that i could because stupid isp has a 3 hour disconnect.....
Silent Bob 11-17-2005, 09:10 PM Try http://cheapbytes.com/ to get it on disk. I've bought a few releases from them.
Mandriva Contrib Set - $17.99
Knoppix - Version 3.9 - $4.99
Fedora Core 4 CD Set - $8.99
Fedora Core 4 DVD - $8.99
Andrew Green 11-17-2005, 09:13 PM Hmm.. fedora is alright, can sometimes be a little unstable due to its nature as a testing ground for RHEL.
You can buy them pretty cheap online, usually a couple bucks plus shipping, or head to a bookstore and look for Linux magazines, which often include a distrobution or 2 on dvd.
Andrew Green 11-17-2005, 09:14 PM or you could read Bob's post about ordering...
BlueDragon1981 11-18-2005, 12:08 AM I found a site the other day with some of the major versions for like 12. Debian, Red Hat, SuSe, Mandriva...and a couple more....if i find it again i'll let you know.
BlueDragon1981 11-18-2005, 12:50 AM Is the 12 pack on this site worth it....29.99
http://www.spidertools.com
Andrew Green 11-18-2005, 01:08 AM I reccomend getting one and sticking with it for at least a few months, getting 12 will make it too tempting to just install a new one everytime something gives you trouble ;)
BlueDragon1981 11-18-2005, 01:22 AM Naw...i will play with one for awhile...I like to see the differences in each...to write reviews...from a "beginners perspective"....although i don't know if that is working anymore....to much experience with computers in general.
BlueDragon1981 11-29-2005, 02:46 PM I have been looking at the code and playing with templates to see where things fit in...experimenting is usually how i learn. I am going to get the server portion and sql stuff soon so I can just start playing around more....I am going to need to look at some resources though...I will let you know if i need more than what has already been posted....or you can just post your resources if you want....doesn't matter to me.
Andrew Green 11-30-2005, 03:26 PM Just came across this link on another forum: http://wiki.cc/php/Main_Page
Might come in handy
BlueDragon1981 12-01-2005, 01:19 AM Thanks....anything helps...just have to not burn myself out with it.
|