I know i'm coming at this message late in the game, but let me just say this. I can pretty much do anything in PHP. Obviously within it's limits.. That sounds like an oxy moron, but let me put it to you this way. With the right modules installed, i can write multi-threaded and event driven packages with php.
I read once that Facebook was written in PHP, and over time it was too much work to change it, so they came up with a way to compile PHP so it executed faster. I'm not sure if they are still using it today -- I would suppose not.
But PHP has always seemed very powerful to me, and can do most anything. However since it's now 2021, I don't think it's much in favor anymore. It seems these days all the kids want to code in Rust or Go, or Python for DevOps.
Very recently, I've discovered the Python Flask framework for server-side web development, and it seems fairly good. It supports a type of messenging that lets you send messages with data back & forth between the server side & client side (i.e., JavaScript in the web browser), which is fairly cool. But I've heard that's not specific to Python though, and it seems other server-side web languages support that now too.
Re: is PHP a neccessary evil?
By: LaRRy LaGoMoRpH to All on Sun Oct 12 2014 20:37:35
LL> I don't like php - but it seems to be all over the place. It seems like
LL> if you want to do web development work, they want you to know php.
LL> But in a perfect world, is PHP neccessary or even ideal to do the things
LL> it's used for moving forward? Maybe it is, I don't know.
LL> It seems very database oriented - like you better know SQL if you know
LL> PHP or else you're kinda missing something.
LL> Then there's all the darn ?'s and $'s all over the place that don't make
LL> things any easier to read. Sure those things are nifty when it's jquery
LL> tacking on javascript, but as a core element of the language seem to
LL> make it more difficult to read.
LL> There's tons of crap that runs on PHP, but is any of it really cool in
LL> any way? I want to see something cool that came from php so I can be
LL> like, oh wow, you can do that with PHP - i want to do that.
I guess I have a diffrent feeling about PHP. To me, PHP feels like any other server-side language. I don't think it's really any better or worse than ASP.NET, JSP, server-side JavaScript, etc.. I actually somewhat like PHP in that it's fairly flexible in what you can do with it. The syntax with the $ symbols etc. doesn't really bother. I don't know of PHP using the ? symbol for
anything though - the only place I can remember it using ? is in the start & end tags (<?php and ?>), which I suppose isn't actually part of the language, but rather server as tags for the parser to know whether or not to process the
text as PHP. In fact, I think the $ symbols can make it easier to read once you get used to it, since you know that a name starting with a $ is a variable.
In other languages, such as C++, C#, etc., variables don't start with any special symbol, so it can sometimes be ambiguous at first to know what you're dealing with, although it's usually easy to determine from its context.
Also, you only need to know SQL if the PHP page(s) you're working has to deal with a database to save & load data. That is a fairly common task though, since many web sites use databases to store information, and SQL is the most common language for a database.
I think there are a couple reasons why PHP is as popular as it is. PHP is a flexible language that allows you to write functional code as well as object-oriented code; it doesn't force a paradigm on you. You can just get right into it and start coding. Also, PHP is a free language that doesn't require any license fees - The PHP engine is freely available for Apache and other web servers.
What I do find somewhat annoying about PHP is that there are multiple ways of doing some things. There are several functions in the PHP standard library that do very similar things, but with slightly different parameters. I think it would have been better if the library was more consistent and concise.
Nightfox
---
¨ Synchronet ¨ Digital Distortion BBS: digitaldistortionbbs.com
Sysop: | Saxainden |
---|---|
Location: | Littleton, CO |
Users: | 30 |
Nodes: | 10 (0 / 10) |
Uptime: | 16:18:32 |
Calls: | 357 |
Calls today: | 2 |
Messages: | 37,322 |