Ok you hate PHP. But how many other Popular alternatives are out there. JSP Oracle is the bad guy right. ASP Microsoft is the bad guy right. Perl The 1990's called and they want their programming back. Ruby on Rails, good alternative however it will be hard to find replacement programmers. Python, Python is my favorite language, however it isn't that good for web.
That's nice. You are comparing lightweight interpreter (PHP) to a Scala which runs on beast called JVM and consumes a lot more memory just to start and print Hello world.
You can literally run tens or even hundreds of small PHP websites on a 512 MB VPS or even a few larger. You also shouldn't forget about shared hosting, where most of PHP websites are hosted (albeit those are small sites, but they represent majority of all sites written in PHP).
Nonetheless, PHP language is improving and with the number
Good thing no one uses Scala to write hello world apps.
Since you are a PHP fan I can safely assume you are uneducated and don't know that trading space for time is a common tradeoff in the CS world.
Almost every algorithmic optimization is giving up memory to speed up execution. I have had difficult problems that were O(n!)-yes I know you don't know what it means, here read this if you can understand it https://en.wikipedia.org/wiki/Big_O_notation [wikipedia.org] - and took days to run without using branch and bound,
it also makes you look like an idiot who can't form their own opinions.
So does using the "but everyone else is doing it" argument.
I've used all kinds of languages for different purposes and the only thing I can say nice about PHP is that it is nearly as ubiquitous as Perl. Otherwise it is neither as capable or well thought out as it's competitors. My personal pet peeve is the inconsistent error handling (some functions just return true/false, some use NULL and false interchangeably, some write their error messages to STDERR, some to STDOUT, most give you no way to programmatic
So does using the "but everyone else is doing it" argument.
That's not the argument I'm making:)
PHP is ubiquitous. That's certainly an advantage as far as maintaining it's share of the web. However, that didn't happen overnight. PHP is ubiquitous today because it did the job it was designed to do better than competing languages. This is still true today, as evidenced by several "superior" fad-languages failing to gain any ground. If PHP was garbage that no professional would touch, it couldn't have possibility achieved such an astonishing share!
Software development will get easier, cheaper, and unprofitable and that's OK because that the nature of technological. The goal should be making tech easier to use and develop for.
PHP was never the best option, it was just easily grokable(at least in a very shallow sense) by amateurs which is the reason the web is so unsecure. Hacking any PHP app is trivial, amazingly Windows 7 and 8 are now more difficult to hack than PHP.
Ask Zuckerberg if he regrets using PHP and listen to him whine and moan about the tens of millions of dollars wasted to get around PHP's flaws.
Ask Lerdorf technical questions and be amazed at his ignorance. He hates programming by the way.
Yeah, only idiots use PHP -- that's why it's only used by 80% of the web
While I agree with your point about language snobbery, popularity doesn't imply user intelligence. There was a time when 80% of the web was written in Comic Sans with green text on a yellow background;)
Disclaimer: I actually do like PHP, in spite of the inconsistencies that do admittedly plague it.
So you are decrying the bandwagon while jumping on one?
Cognitive dissonance much?
At least I can give you valid reasons why I don't use PHP ever, and why I use the languages I do. Using actual arguments founded in computer science.
You use PHP because "everyone else does". You don't understand why it is a steaming pile of shit and you don't care enough to try to understand. You just hack and slash your way to a shitty solution. You are a typical PHP "programmer".
Yes, Perl is a paragon of structure and consistency:
Exactly what the EXPR argument to when does is hard to describe precisely, but in general, it tries to guess what you want done. Sometimes it is interpreted as $_ ~~ EXPR, and sometimes it is not. It also behaves differently when lexically enclosed by a given block than it does when dynamically enclosed by a foreach loop. The rules are far too difficult to understand to be described here. See Experimental Details on given and when later on.
The smart-match operator was fairly experimental from its introduction in 5.10 and was already disabled in 5.20, IIRC. Also, the Perl (5) interpreter relies quite a bit on heuristics to parse certain ambiguous syntax elements; you generally don't type them accidentally and when you do, the interpreter often emits a warning. Perl has never tried to be a strict language such as Java that beats you with a stick if you don't put parentheses after a method call.
Python can be pretty good for the web. If mod_python development had been more active it probably could have approached the market penetration of mod_php, because the reason why PHP got popular in the first place is because shared hosting providers could just build it into apache and forget about it, without having to babysit people's application servers chewing up ram while idle, and falling over and crashing every 30 minutes when not.
Python and Ruby are strongly typed, unlike PHP which doesn't even rise to the lofty title of weakly typed, stupidly typed is more accurate.
I am more familar with Ruby, so I will comment based on that, but my recollection of Python isn't much different. An object in Ruby is a specific type and will never be a different type, you can not coerce it(although you can get the object to return its representation in a different object: to_s, to_a, etc) to anything else and has no casting. You can't get much safe
Python, Python is my favorite language, however it isn't that good for web.
The standard for making a python application interact with a web server is wsgi, you can run it inside apache with mod_wsgi or run it in a dedicated server such as uwsgi. Or if you want to go asynchronous you can try tornado.
I like Django... that's my preference for new projects, but I have a lot of older PHP projects, and some of the developers here are still creating and maintaining PHP sites, and I have no problems with them, either. PHP works well for what it was designed for; I love Python, but we've managed to do some pretty complicated and, more importantly, working sites in PHP. I have no problem with it.
One page book (Score:-1, Flamebait)
DON'T
Re:One page book (Score:2)
Ok you hate PHP. But how many other Popular alternatives are out there.
JSP Oracle is the bad guy right.
ASP Microsoft is the bad guy right.
Perl The 1990's called and they want their programming back.
Ruby on Rails, good alternative however it will be hard to find replacement programmers.
Python, Python is my favorite language, however it isn't that good for web.
Re: (Score:3)
There is a nice looking framework for Scala called Play. I think that could be a good alternative. http://www.playframework.com/ [playframework.com]
Re: (Score:2)
How many web hosts support it? That is why PHP still lives on.
Re: (Score:2)
I'm not sure but it should run as long as you have Java. Scala compiles down to Java byte code.
Re: (Score:1)
You can literally run tens or even hundreds of small PHP websites on a 512 MB VPS or even a few larger. You also shouldn't forget about shared hosting, where most of PHP websites are hosted (albeit those are small sites, but they represent majority of all sites written in PHP).
Nonetheless, PHP language is improving and with the number
Re: (Score:0)
Since you are a PHP fan I can safely assume you are uneducated and don't know that trading space for time is a common tradeoff in the CS world.
Almost every algorithmic optimization is giving up memory to speed up execution. I have had difficult problems that were O(n!)-yes I know you don't know what it means, here read this if you can understand it https://en.wikipedia.org/wiki/Big_O_notation [wikipedia.org] - and took days to run without using branch and bound,
Re: (Score:1)
Re: (Score:0, Troll)
If you're using PHP, you're a fucking idiot.
FTFY
Re: (Score:3)
Yeah, only idiots use PHP -- that's why it's only used by 80% of the web [w3techs.com].
Language snobbery benefits no one. Unless you're Chuck Moore, it also makes you look like an idiot who can't form their own opinions.
Re: (Score:3)
it also makes you look like an idiot who can't form their own opinions.
So does using the "but everyone else is doing it" argument.
I've used all kinds of languages for different purposes and the only thing I can say nice about PHP is that it is nearly as ubiquitous as Perl. Otherwise it is neither as capable or well thought out as it's competitors. My personal pet peeve is the inconsistent error handling (some functions just return true/false, some use NULL and false interchangeably, some write their error messages to STDERR, some to STDOUT, most give you no way to programmatic
Re: (Score:2)
So does using the "but everyone else is doing it" argument.
That's not the argument I'm making :)
PHP is ubiquitous. That's certainly an advantage as far as maintaining it's share of the web. However, that didn't happen overnight. PHP is ubiquitous today because it did the job it was designed to do better than competing languages. This is still true today, as evidenced by several "superior" fad-languages failing to gain any ground. If PHP was garbage that no professional would touch, it couldn't have possibility achieved such an astonishing share!
You can critici
Re: (Score:0)
Nail, meet head.
Re: (Score:0)
Software development will get easier, cheaper, and unprofitable and that's OK because that the nature of technological. The goal should be making tech easier to use and develop for.
Re: (Score:0)
Ask Zuckerberg if he regrets using PHP and listen to him whine and moan about the tens of millions of dollars wasted to get around PHP's flaws.
Ask Lerdorf technical questions and be amazed at his ignorance. He hates programming by the way.
PHP by amateurs f
Re: (Score:2)
Yeah, only idiots use PHP -- that's why it's only used by 80% of the web
While I agree with your point about language snobbery, popularity doesn't imply user intelligence. There was a time when 80% of the web was written in Comic Sans with green text on a yellow background ;)
Disclaimer: I actually do like PHP, in spite of the inconsistencies that do admittedly plague it.
Re: (Score:2)
Not quite what I meant -- see my other reply. Apparently I can't communicate ideas today.
Re: (Score:2)
Re: (Score:0)
So you are decrying the bandwagon while jumping on one?
Cognitive dissonance much?
At least I can give you valid reasons why I don't use PHP ever, and why I use the languages I do. Using actual arguments founded in computer science.
You use PHP because "everyone else does". You don't understand why it is a steaming pile of shit and you don't care enough to try to understand. You just hack and slash your way to a shitty solution. You are a typical PHP "programmer".
Re: (Score:2)
Yup, as stupid as the Facebook bank balance.
Re: (Score:2)
FTFY
Re: (Score:0)
+1 Informative
+1 Redundant
Re: (Score:1)
Yes, Perl is a paragon of structure and consistency:
Exactly what the EXPR argument to when does is hard to describe precisely, but in general, it tries to guess what you want done. Sometimes it is interpreted as $_ ~~ EXPR, and sometimes it is not. It also behaves differently when lexically enclosed by a given block than it does when dynamically enclosed by a foreach loop. The rules are far too difficult to understand to be described here. See Experimental Details on given and when later on.
- Perldoc [perl.org]
Re: (Score:0)
The smart-match operator was fairly experimental from its introduction in 5.10 and was already disabled in 5.20, IIRC. Also, the Perl (5) interpreter relies quite a bit on heuristics to parse certain ambiguous syntax elements; you generally don't type them accidentally and when you do, the interpreter often emits a warning. Perl has never tried to be a strict language such as Java that beats you with a stick if you don't put parentheses after a method call.
Re: (Score:1)
Lua + LuaJIT is can be interesting too.
Re: (Score:2)
Dart might be interesting, when they stop changing everything...all the time.
Re: (Score:0)
Python can be pretty good for the web. If mod_python development had been more active it probably could have approached the market penetration of mod_php, because the reason why PHP got popular in the first place is because shared hosting providers could just build it into apache and forget about it, without having to babysit people's application servers chewing up ram while idle, and falling over and crashing every 30 minutes when not.
Re: (Score:3)
Re: (Score:-1)
Because it's not type safe. And you need type safety on the web.
Re: (Score:2)
I am more familar with Ruby, so I will comment based on that, but my recollection of Python isn't much different. An object in Ruby is a specific type and will never be a different type, you can not coerce it(although you can get the object to return its representation in a different object: to_s, to_a, etc) to anything else and has no casting. You can't get much safe
Python is just fine for the web (Score:2)
Python, Python is my favorite language, however it isn't that good for web.
The standard for making a python application interact with a web server is wsgi, you can run it inside apache with mod_wsgi or run it in a dedicated server such as uwsgi. Or if you want to go asynchronous you can try tornado.
Re: (Score:1)
If you hire actual programmers that have not only domain knowlege but understand computation they will pick up both Ruby and Rails quickly.
Hire programmers, not programming language/framework end-users.
When you are writing a web app you can use whatever you like and there are a lot of good options:
Perl
Python(with or without the various framworks)
Ruby(with or without Rails or Sinatra) & JRuby
Smalltalk
Haskell
Lisp & Cloju
Re: (Score:2)
"JSP Oracle is the bad guy right.
Don't have to use JSPs and don't even really have to go near Oracle. There are fully open source Java stacks.
"ASP Microsoft is the bad guy right."
Truly skilled high quality professionals don't care about fanboyism, they just use the best tool for the job. If that's ASP.NET then so be it.
"Perl The 1990's called and they want their programming back."
I'll let you have that, though I'd argue that Perl is both of a higher quality design in that it's been built with sound academic
Re: (Score:2)
Python, Python is my favorite language, however it isn't that good for web.
Go home, comment. You're drunk.
Django [djangoproject.com], Pylons [pylonsproject.org], Bottle [bottlepy.org], Flask [pocoo.org], TurboGears [turbogears.org], Zope [zope.org], Web2Py [web2py.com]...
And that's just some of the popular frameworks..
Re: (Score:2)
Re: (Score:0)
When I was in college, we wrote CGI in assembly!
.
.
.
Seriously, most asinine thing ever (I think that was the point).