A preserved archive of the Logical Gamers community forums, 2009-2025. The original threads and posts, served read-only. Registration, posting and private messages are gone for good.

Why must the PHP Manual be so boring?

880 views · started by Riddle ·
#1
Why must the PHP Manual be so boring?
Well, I'm dragging myself through it to check out the language's specifications and some tips/hints on how to do things the right way.

I know Alex has done A LOT of PHP scripting before. So any tips for better script performance? :)
#2
One thing i know he would tell you (arti was my teacher ;D)

Really organize your code. Classes in different files. I normally put all my functions for users in a file called functions.users.php and put it in the include file. Add a class inside the file called users. Then put all your functions with users in that file. And so on.
#3
Alex was my some what teacher. Told me to organize my code, make it as clean as possible, and rename controls so you know what it is. Example: StringName would be strName.
#4
Chad wrote:
Alex was my some what teacher. Told me to organize my code, make it as clean as possible, and rename controls so you know what it is. Example: StringName would be strName.


Nobody really declares variables like that in PHP. It's more common in some of the visual languages.

While the PHP.net site is great as a reference point, I've tended to stay away from it. The only reason I've used it is for documentation on specific functions. php.net/function_name. There are some great books out there that are somewhat enjoyable to read. I suggest you go to Amazon, search for PHP and organize by the rating in descending order. You can either purchase them or download digital copies online. I have about 10 or so great resources on my Kindle that I tend to read through when bored.

edit: while we're on the topic of PHP, anyone want to help me develop the main LG site? Going to give it a crack over the weekend.
#5
Make a Bot selling site so we can make some money for LG. D<
#6
Artificial wrote:
Nobody really declares variables like that in PHP. It's more common in some of the visual languages.

While the PHP.net site is great as a reference point, I've tended to stay away from it. The only reason I've used it is for documentation on specific functions. php.net/function_name. There are some great books out there that are somewhat enjoyable to read. I suggest you go to Amazon, search for PHP and organize by the rating in descending order. You can either purchase them or download digital copies online. I have about 10 or so great resources on my Kindle that I tend to read through when bored.

edit: while we're on the topic of PHP, anyone want to help me develop the main LG site? Going to give it a crack over the weekend.
I will :D not doing anything important until monday.
#7
Alright, thanks. :)

So organization is important. I'm happy that I tend to be organized. What sucks is documenting the code. However, it's essential for Team Development... Hmm, some kind of tool to parse out each function and propertie of a class would be very handy. I'll work on something like that. :)
#8
And by the way, what do you mean the main LG site? What are you planning? :P
#9
-removed-

Design is bleh, I know.

edit: scratch that, redoing