473,385 Members | 1,912 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Why PHP is so much more popular for web-development

"Once you start down the Dark path, forever will it dominate your
desiny. Consume you, it will."
- Yoda

I'm fairly new to web-development, and I'm trying out different
technologies. Some people wonder why PHP is so popular, when the
language is flawed in so many ways. To me, it's obvious: it's because
it's much easier to get started with PHP, and once somebody gets
started with a particular language, that person is likely to stay with
that language.

Before you can even get started with Python web-development, you have
to understand this entire alphabit soup of: CGI, FASTCGI, MOD_PYTHON,
FLUP, WSGI, PASTE, etc. For me, configuring fastcgi has been the most
difficult part of getting django to work. PHP developers don't have to
bother with anything like that. With PHP, you just throw some code in
the middle of your html file.

Also, PHP, and PHP frameworks, are supported everywhere. If you going
to use a PHP MVC framework, like codeignitor, you would have a hard
time finding a hoster that didn't support it - all you need is php4
and mysql. Dollar-hosting, for $10 a year, should work just fine with
codeignitor. With codeignitor, just copy your files to whatever host,
and that's it, you're done.

By contrast, the most popular Python frameworks have sky-high system
requirements. Take a look at the requirements and/or recomendations
for popular Python frameworks like Django, TurboGears, or CherryPy:
Apache 2.0, mod_python (latest version), fastcgi (at least), command
line access, PostgreSQL. And a lot of low-cost hosters don't support
Python at all.

Don't get me wrong: I am not saying that PHP is better than Python for
web-development. But, I sometimes think that Python could learn a few
things from PHP.

All JMHO, of course.

Jul 25 '07 #1
31 4317
walterbyrd wrote:
"Once you start down the Dark path, forever will it dominate your
desiny. Consume you, it will."
- Yoda

I'm fairly new to web-development, and I'm trying out different
technologies. Some people wonder why PHP is so popular, when the
language is flawed in so many ways. To me, it's obvious: it's because
it's much easier to get started with PHP, and once somebody gets
started with a particular language, that person is likely to stay with
that language.

Before you can even get started with Python web-development, you have
to understand this entire alphabit soup of: CGI, FASTCGI, MOD_PYTHON,
FLUP, WSGI, PASTE, etc. For me, configuring fastcgi has been the most
difficult part of getting django to work. PHP developers don't have to
bother with anything like that. With PHP, you just throw some code in
the middle of your html file.

Also, PHP, and PHP frameworks, are supported everywhere. If you going
to use a PHP MVC framework, like codeignitor, you would have a hard
time finding a hoster that didn't support it - all you need is php4
and mysql. Dollar-hosting, for $10 a year, should work just fine with
codeignitor. With codeignitor, just copy your files to whatever host,
and that's it, you're done.

By contrast, the most popular Python frameworks have sky-high system
requirements. Take a look at the requirements and/or recomendations
for popular Python frameworks like Django, TurboGears, or CherryPy:
Apache 2.0, mod_python (latest version), fastcgi (at least), command
line access, PostgreSQL. And a lot of low-cost hosters don't support
Python at all.

Don't get me wrong: I am not saying that PHP is better than Python for
web-development. But, I sometimes think that Python could learn a few
things from PHP.

All JMHO, of course.
Indeed. The reason that PHP is so popular with so many people is that
the core language meets most of the simpler requirements for web sites.

Most people putting together a site are perfectly happy with something
along the lines of PHPNuke.

When someone starts to push the limits of PHP they either continue to
push until they get where they want to be (producing an ugly or
ill-maintained bunch of code along the way) or they choose a more
appropriate tool.

The latter behavior is typical of programmers. The former is typical of
typical users. There are many people producing web sites who I wouldn't
let within yards of any of my code. but it's some kind of tribute to PHP
that it manages to satisfy so many of them. This doesn't mean that
grafting PHP features into Python mindlessly will improve the language.

The Python approach is a scalpel, which can easily cut your fingers off.
The PHP approach is a shovel, which will do for many everyday tasks.

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC/Ltd http://www.holdenweb.com
Skype: holdenweb http://del.icio.us/steve.holden
--------------- Asciimercial ------------------
Get on the web: Blog, lens and tag the Internet
Many services currently offer free registration
----------- Thank You for Reading -------------

Jul 25 '07 #2
Before you can even get started with Python web-development, you have
to understand this entire alphabit soup of: CGI, FASTCGI, MOD_PYTHON,
FLUP, WSGI, PASTE, etc. For me, configuring fastcgi has been the most
difficult part of getting django to work. PHP developers don't have to
bother with anything like that. With PHP, you just throw some code in
the middle of your html file.
Which is simply because they are preconfigured. If you have ever tried
to recompile a PHP installation because it misses e.g. oracle support.
Also, PHP, and PHP frameworks, are supported everywhere. If you going
to use a PHP MVC framework, like codeignitor, you would have a hard
time finding a hoster that didn't support it - all you need is php4
and mysql. Dollar-hosting, for $10 a year, should work just fine with
codeignitor. With codeignitor, just copy your files to whatever host,
and that's it, you're done.

By contrast, the most popular Python frameworks have sky-high system
requirements. Take a look at the requirements and/or recomendations
for popular Python frameworks like Django, TurboGears, or CherryPy:
Apache 2.0, mod_python (latest version), fastcgi (at least), command
line access, PostgreSQL. And a lot of low-cost hosters don't support
Python at all.

Don't get me wrong: I am not saying that PHP is better than Python for
web-development. But, I sometimes think that Python could learn a few
things from PHP.
I don't see that amongst the above is anything that python could learn.
Using turbogears, a simple

tg-admin quickstart

followed by a

../start-<projectname>.py

is all you need. The templating system is simple, allows for embedded
python (to some extend, and a healthy one), database-support &
model-stuff is easy.

The cheap hosting and preconfigured apache setups are things that only
the market can solve.

Diez
Jul 25 '07 #3
Unfortunately, I also find that PHP programmers are usually more
plentiful than their Python counterparts. When thinking of staffing
an organization, it's common to target a skill set that's cheaper to
employ and easier to replace down the road if need be.

Also, larger hosting shops are hesitant to run things such as TG and
Rails that require an additional server process. The name of the game
is density. Sure, it may be easy to manage and run a TG project, but
it's a pain to set one up on a shared hosting server.

Lastly, I personally think it has something to do with the fact that
so many of the popular, free, web applications are PHP based. It's
easy for the average Web Administrator to get started with your
standard PHP package. From there, picking up the language is the next
logical step.

-Jeff

On 7/25/07, walterbyrd <wa********@iname.comwrote:
"Once you start down the Dark path, forever will it dominate your
desiny. Consume you, it will."
- Yoda

I'm fairly new to web-development, and I'm trying out different
technologies. Some people wonder why PHP is so popular, when the
language is flawed in so many ways. To me, it's obvious: it's because
it's much easier to get started with PHP, and once somebody gets
started with a particular language, that person is likely to stay with
that language.

Before you can even get started with Python web-development, you have
to understand this entire alphabit soup of: CGI, FASTCGI, MOD_PYTHON,
FLUP, WSGI, PASTE, etc. For me, configuring fastcgi has been the most
difficult part of getting django to work. PHP developers don't have to
bother with anything like that. With PHP, you just throw some code in
the middle of your html file.

Also, PHP, and PHP frameworks, are supported everywhere. If you going
to use a PHP MVC framework, like codeignitor, you would have a hard
time finding a hoster that didn't support it - all you need is php4
and mysql. Dollar-hosting, for $10 a year, should work just fine with
codeignitor. With codeignitor, just copy your files to whatever host,
and that's it, you're done.

By contrast, the most popular Python frameworks have sky-high system
requirements. Take a look at the requirements and/or recomendations
for popular Python frameworks like Django, TurboGears, or CherryPy:
Apache 2.0, mod_python (latest version), fastcgi (at least), command
line access, PostgreSQL. And a lot of low-cost hosters don't support
Python at all.

Don't get me wrong: I am not saying that PHP is better than Python for
web-development. But, I sometimes think that Python could learn a few
things from PHP.

All JMHO, of course.

--
http://mail.python.org/mailman/listinfo/python-list
Jul 25 '07 #4
walterbyrd schrieb:
Don't get me wrong: I am not saying that PHP is better than Python for
web-development. But, I sometimes think that Python could learn a few
things from PHP.
Yes, indeed we can learn that popularity is not superiority. ;-)

Gregor
Jul 25 '07 #5


Steve Holden wrote:
walterbyrd wrote:
>"Once you start down the Dark path, forever will it dominate your
desiny. Consume you, it will."
- Yoda

I'm fairly new to web-development, and I'm trying out different
technologies. Some people wonder why PHP is so popular, when the
language is flawed in so many ways. To me, it's obvious: it's because
it's much easier to get started with PHP, and once somebody gets
started with a particular language, that person is likely to stay with
that language.

Before you can even get started with Python web-development, you have
to understand this entire alphabit soup of: CGI, FASTCGI, MOD_PYTHON,
FLUP, WSGI, PASTE, etc. For me, configuring fastcgi has been the most
difficult part of getting django to work. PHP developers don't have to
bother with anything like that. With PHP, you just throw some code in
the middle of your html file.
I'm primarily a sysadmin, and I provide web hosting-like services to a
community of developers who all want to do their own thing. An obvious,
clean way to do this has, so far, eluded me. Of course I could shove a
framework down the throats of my users, but if given the choice between
picking up a language, or picking up a language, and an accompanying
framework, which may or may not meet their needs, I think they'd pick
the former. In fact, in 6 years, we've never had anyone say "boy I wish
our web servers supported python". They've all been happily using PHP.

I'm in a relatively small shop. But think about an ISP. If you need to
support thousands of users who all have their own agendas, how exactly
do you support that with Python? This is not a rhetorical question - I'd
really like to know :)

In short, I don't think it's the language, but deploying it in a web
context that makes it less popular. If it were simpler, more ISPs might
do it, more users would find what they need with Python instead of PHP,
and it would become a more popular web language, IMHO.
The latter behavior is typical of programmers. The former is typical of
typical users. There are many people producing web sites who I wouldn't
let within yards of any of my code. but it's some kind of tribute to PHP
that it manages to satisfy so many of them. This doesn't mean that
grafting PHP features into Python mindlessly will improve the language.
I don't think anyone is saying the *language* itself needs improving. I
think there needs to be a cleaner, simpler, more practical way to deploy
Python as a generic web language instead of being forced to deploy it in
the context of some other framework. No ISP wants to impose the implied
limitations on their users, and the users would prefer not to have to
learn a framework.

Also, I just want to point out that in my discussions with other people
who consider themselves primarily Python coders, there are plenty of
them who still turn to PHP for web development. I got into Python for
systems programming (sysadmin tasks and network programming). If I need
to do web-based work, I'm likely to still use PHP because I have no idea
how to deploy/maintain/support Python on the systems end of the
equation. I'd love to be cured of that notion.

brian.
The Python approach is a scalpel, which can easily cut your fingers off.
The PHP approach is a shovel, which will do for many everyday tasks.

regards
Steve
--
Brian K. Jones
Python Magazine http://www.pythonmagazine.com
My Blog http://m0j0.wordpress.com
jonesy at pythonmagazine dot com

Jul 25 '07 #6
On Jul 25, 12:40 pm, Carsten Haese <cars...@uniqsys.comwrote:
What exactly could Python learn from PHP?
Remember, I'm a noob, I'm not trolling.

When I posted "Python" I meant the Python web-developement world. In
particular, python frameworks, like CherryPy, have requirements that
are not realistic for most shared hosting plans.

Maybe I'm wrong, but I often get the idea that those who develop
python frameworks don't give a thought to the realities of shared
hosting. They seem to think that everybody has complete control over
the server. Things are very different in the PHP universe.

To use codeignitor as an example, again. On the "why codeignitor"
part of the welcome page you will find:

---
CodeIgniter is right for you if...
* You need broad compatibility with standard hosting accounts that run
a variety of PHP versions and configurations.
* You want a framework that requires nearly zero configuration.
* You want a framework that does not require you to use the command
line.
---

I don't seem to see Python frameworks using those sorts of selling
points. Posting as a noob, who is struggling to get django configured
on dreamhost, I gotta tell 'ya: those selling points look awfully
attractive.

The point is: PHP framework makers are very considerate of the
realities of shared hosting. Python framework makers don't seem to
give it a thought. Just maybe, that's something that Python could
learn from PHP.
Jul 25 '07 #7
On Wed, Jul 25, 2007 at 12:34:08PM -0700, walterbyrd wrote:
When I posted "Python" I meant the Python web-developement world. In
particular, python frameworks, like CherryPy, have requirements that
are not realistic for most shared hosting plans.
It's true that the requirements are higher than what the old-school
CGI/PHP web hosters offer. But with todays virtual root servers it's
really inexpensive to run such a server. And using frameworks allows you
to control all aspects of the web serving like URL dispatching, error
handling and is probably even faster than PHP because necessary
resources (like database connections) are initalized upon startup of the
web application. PHP and CGIs do this everytime they get called.
Maybe I'm wrong, but I often get the idea that those who develop
python frameworks don't give a thought to the realities of shared
hosting. They seem to think that everybody has complete control over
the server. Things are very different in the PHP universe.
Without wanting to sound arrogant: it's my belief that web hosters just
offering htdocs/PHP will probably just be useful for the noob-customers
who have no idea of operating systems but just want their blinking
personal homepage online.

There are good PHP applications and I wouldn't want to give up
phpmyadmin or squirrelmail. But with today's demand for fully
controllable interactive (you will never hear me propagate that bullshit
buzzword "Web x.0") web sites a framework seems to be a viable way.
For me PHP has a bitter taste of "easy enough for every noob to use it"
which makes it the language the most insecure applications are written
in.
The point is: PHP framework makers are very considerate of the
realities of shared hosting. Python framework makers don't seem to
give it a thought. Just maybe, that's something that Python could
learn from PHP.
Perhaps. But the hosting market changes. And I believe that PHP suits
the simpler applications better. I would point a beginner in web
programming more likely to PHP than torture them with frameworks. It's
just too heavy. OTOH full-featured frameworks are way more complicated
and have eviler requirements but there are hardly any limitation on the
kinds of sites you can power with them.

EO2¢

Cheers
Christoph

Jul 25 '07 #8
Steve Holden wrote:
When someone starts to push the limits of PHP they either continue to
push until they get where they want to be (producing an ugly or
ill-maintained bunch of code along the way) or they choose a more
appropriate tool.

The latter behavior is typical of programmers. The former is typical of
typical users. There are many people producing web sites who I wouldn't
let within yards of any of my code. but it's some kind of tribute to PHP
that it manages to satisfy so many of them. This doesn't mean that
grafting PHP features into Python mindlessly will improve the language.

The Python approach is a scalpel, which can easily cut your fingers off.
The PHP approach is a shovel, which will do for many everyday tasks.
Exactly right on. I actually use PHP quite a bit. For websites that
would otherwise be static html pages other than the fact that I want to
reuse elements (header, footer, etc.), I choose PHP in a heartbeat,
because it's easy, and I'm lazy. Ditto if it is a simple db-driven site.

Start adding business rules and complex program flow and I run away from
PHP as fast as I can. I wouldn't want to actually code anything in it,
after all. ;)

I've seen comments that mod_python is hard to use, but I just haven't
found that to be the case. For me, mod_python is the next step up when
PHP no longer suits my needs. Granted, I'm spoiled because I run my own
server and don't rely on some hosting provider to tell me what I can and
cannot do. :)

--
pkm ~ http://paulmcnett.com
Jul 25 '07 #9
I'm an ex-PHP programmer (well, I still have to use some PHP at work,
but I don't tell anyone that at parties) who now uses Python or Lisp
wherever possible for web development. I can tell you exactly why PHP
is so popular: it acts as an extension of HTML and is syntactically
similar to Perl.

PHP mixes with HTML and removes the separation of model and view. It
has its roots in strictly procedural code (and its OO colors were
obviously painted on later), which is simple for non-programmers or
beginning programmers to understand. When considered from the
standpoint of a template language, it's a wonderful language. When
considered as a real programming environment, its limitations show.

PHP began as a series of Perl scripts. If you have ever looked at a
huge PHP project, it looks just as unreadable as a huge Perl project.
But there is a large number of programmers who began writing Perl-
based CGI for the web, and PHP was a very natural next step for them.
This is also a big reason why Ruby is popular among the same crowd
(...I say as I duck the inevitable flame war I've just started). Ruby
takes a lot of concepts from Perl and tries to make them work in an OO
framework (the ~ operator and the built in regex type, for instance).

I started with PHP for both of those reasons. Perl was becoming too
much of a chore and PHP offered a solution without learning a new
templating language: a way to embed perl code in the page itself.

Of course, now I am in recovery and am proceeding well with my 12
steps, thanks for asking.

Jul 25 '07 #10
On Wed, 2007-07-25 at 12:34 -0700, walterbyrd wrote:
On Jul 25, 12:40 pm, Carsten Haese <cars...@uniqsys.comwrote:
What exactly could Python learn from PHP?

Remember, I'm a noob, I'm not trolling.
I know.
When I posted "Python" I meant the Python web-developement world. In
particular, python frameworks, like CherryPy, have requirements that
are not realistic for most shared hosting plans.
CherryPy is not a framework. Also, CherryPy's requirements are very
minimal. You either need a "vanilla" Apache/mod_python setup (which is
no harder to set up than a vanilla Apache/PHP setup), or just Python
itself if you use the webserver that is in CherryPy.
Maybe I'm wrong, but I often get the idea that those who develop
python frameworks don't give a thought to the realities of shared
hosting. They seem to think that everybody has complete control over
the server. Things are very different in the PHP universe.
Again, CherryPy is not a web programming framework. It is a web server
that "publishes" object methods.

Also, things are only easy in the PHP world if you only use the modules
that the hosting provider pre-installed. I doubt you'll easily find a
PHP hosting provider that will allow connections to Informix or Oracle
databases.
To use codeignitor as an example, again. On the "why codeignitor"
part of the welcome page you will find:

---
CodeIgniter is right for you if...
* You need broad compatibility with standard hosting accounts that run
a variety of PHP versions and configurations.
* You want a framework that requires nearly zero configuration.
* You want a framework that does not require you to use the command
line.
---

I don't seem to see Python frameworks using those sorts of selling
points. Posting as a noob, who is struggling to get django configured
on dreamhost, I gotta tell 'ya: those selling points look awfully
attractive.

The point is: PHP framework makers are very considerate of the
realities of shared hosting.
It may look like that to you, but that's not a property of the PHP
language. I haven't seen CodeIgniter, but I imagine it's easy for you to
set up because it's already installed by the hosting provider, which is
due to PHP's popularity. If you could find a provider that can give you
an out-of-the-box Django or TG set up, you'd probably find that just as
easy. Finding a hosting provider that'll do this is the problem, of
course, but that's not because these frameworks are designed to be hard
to install. It's just that most providers don't pre-install these
frameworks because there isn't enough demand.
Python framework makers don't seem to
give it a thought.
Python framework makers have no influence over what web hosting
providers do.
Just maybe, that's something that Python could
learn from PHP.
What is "that", and what can Python developers do to learn "that"?

--
Carsten Haese
http://informixdb.sourceforge.net
Jul 25 '07 #11
On Jul 25, 2:10 pm, Jeff <jeffo...@gmail.comwrote:
I can tell you exactly why PHP
is so popular: it acts as an extension of HTML and is syntactically
similar to Perl.
Although, that can lead to problems, if you're not careful:

Perl:
my $x = 5 + 9000 || 1; # $x is 9005

PHP:
$x = 5 + 9000 || 1; # $x is 6...

Jul 25 '07 #12
On Jul 25, 2:12 pm, Carsten Haese <cars...@uniqsys.comwrote:
Also, CherryPy's requirements are very
minimal.
In terms of memory and CPU, maybe. But I think that *requires* apache
2.x and a very recent version of mod_python. By web-hosting
standards, those are very steep requirements.

Jul 25 '07 #13
On Wed, 2007-07-25 at 13:55 -0700, walterbyrd wrote:
On Jul 25, 2:12 pm, Carsten Haese <cars...@uniqsys.comwrote:
Also, CherryPy's requirements are very
minimal.

In terms of memory and CPU, maybe. But I think that *requires* apache
2.x and a very recent version of mod_python. By web-hosting
standards, those are very steep requirements.
Apache 2 came out 5 years ago. I wouldn't trust a web hosting provider
who can't be bothered to install software that's been out for 5 years to
stay up to date on security patches. You get what you pay for.

Also, CherryPy does not *require* Apache. It supplies its own web
server. Getting that server to run on a shared host may be a problem,
but it is incorrect to state that CherryPy *requires* Apache 2.

--
Carsten Haese
http://informixdb.sourceforge.net
Jul 25 '07 #14
walterbyrd wrote:
On Jul 25, 2:12 pm, Carsten Haese <cars...@uniqsys.comwrote:
>Also, CherryPy's requirements are very
minimal.

In terms of memory and CPU, maybe. But I think that *requires* apache
2.x and a very recent version of mod_python. By web-hosting
standards, those are very steep requirements.
You are wrong. CherryPy is a standalone web server environment.

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC/Ltd http://www.holdenweb.com
Skype: holdenweb http://del.icio.us/steve.holden
--------------- Asciimercial ------------------
Get on the web: Blog, lens and tag the Internet
Many services currently offer free registration
----------- Thank You for Reading -------------

Jul 25 '07 #15
Jeff McNeil wrote:
Unfortunately, I also find that PHP programmers are usually more
plentiful than their Python counterparts. When thinking of staffing
an organization, it's common to target a skill set that's cheaper to
employ and easier to replace down the road if need be.
Right, that's why hospitals are replacing their surgeons with butchers.
There are so many more of them available. It's only cutting meat, after all.
Also, larger hosting shops are hesitant to run things such as TG and
Rails that require an additional server process. The name of the game
is density. Sure, it may be easy to manage and run a TG project, but
it's a pain to set one up on a shared hosting server.
Virtualization will solve that problem.
Lastly, I personally think it has something to do with the fact that
so many of the popular, free, web applications are PHP based. It's
easy for the average Web Administrator to get started with your
standard PHP package. From there, picking up the language is the next
logical step.
There's some justice to that.

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC/Ltd http://www.holdenweb.com
Skype: holdenweb http://del.icio.us/steve.holden
--------------- Asciimercial ------------------
Get on the web: Blog, lens and tag the Internet
Many services currently offer free registration
----------- Thank You for Reading -------------

Jul 25 '07 #16
On Jul 25, 3:55 pm, Steve Holden <st...@holdenweb.comwrote:
Jeff McNeil wrote:
Unfortunately, I also find that PHP programmers are usually more
plentiful than their Python counterparts. When thinking of staffing
an organization, it's common to target a skill set that's cheaper to
employ and easier to replace down the road if need be.

Right, that's why hospitals are replacing their surgeons with butchers.
There are so many more of them available. It's only cutting meat, after all.
Hospitals probably would if they could. Healthcare is extremely
regulated. Software development, web or otherwise, is still the wild-
west. Besides, I don't think it's quite fair to characterize all PHP
developers as "butchers" and Python developers as "surgeons." Python
may be superior to PHP, but come on now. Besides, I see about 100X
more ads for PHP programmers, than Python programmers. My guess is
that there probably are a lot more PHP developers, especially web-
developers.
Also, larger hosting shops are hesitant to run things such as TG and
Rails that require an additional server process. The name of the game
is density. Sure, it may be easy to manage and run a TG project, but
it's a pain to set one up on a shared hosting server.

Virtualization will solve that problem.
I can get PHP hosting for $10/year. Will I be able to get a virtual
host for that?

Jul 25 '07 #17
No programming language can fix bad programmers. And if cost is an
issue, www.nearlyfreespeech.net has Python, clisp, and OCaml.

Jul 26 '07 #18
On 7/25/07, Steve Holden <st***@holdenweb.comwrote:
Jeff McNeil wrote:
Unfortunately, I also find that PHP programmers are usually more
plentiful than their Python counterparts. When thinking of staffing
an organization, it's common to target a skill set that's cheaper to
employ and easier to replace down the road if need be.
Right, that's why hospitals are replacing their surgeons with butchers.
There are so many more of them available. It's only cutting meat, after all.
I prefer Python by a long shot, but I'm confident there are a lot of
shops making the PHP vs. Python decision every day and this is up
there on the list of PHP's benefits. Of the 10 guys I've interviewed
in the past two months, I think one had Python experience. In digging
a bit deeper, it turns out he got that installing Anaconda packages.
Also, larger hosting shops are hesitant to run things such as TG and
Rails that require an additional server process. The name of the game
is density. Sure, it may be easy to manage and run a TG project, but
it's a pain to set one up on a shared hosting server.
Virtualization will solve that problem.
It will help, sure. I run a few things in a FreeBSD VPS right now,
actually. I really like the freedom it brings.

The problem again goes back to density, though. I work for one of the
large web hosting firms. When talking straight shared hosting, we can
put well over 50,000 web sites on a cluster of servers. On our VPS
products? That number drops down to about 1,000 on the same hardware
configuration. If we start talking about hardware virtualization,
divide by ten again.

The technology is getting there, but it's still just not feasible to
hit the same scale with virtualization that one can hit when building
a standard shared hosting platform.

All of that said, we *do* offer Python on our products. We just don't
provide additional support for things such as TurboGears, Zope, or
Django. All of our provisioning and management infrastructure is in
Python as well.
>
Lastly, I personally think it has something to do with the fact that
so many of the popular, free, web applications are PHP based. It's
easy for the average Web Administrator to get started with your
standard PHP package. From there, picking up the language is the next
logical step.
There's some justice to that.

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC/Ltd http://www.holdenweb.com
Skype: holdenweb http://del.icio.us/steve.holden
--------------- Asciimercial ------------------
Get on the web: Blog, lens and tag the Internet
Many services currently offer free registration
----------- Thank You for Reading -------------

--
http://mail.python.org/mailman/listinfo/python-list
Jul 26 '07 #19
Carsten Haese schrieb:
>Also, PHP, and PHP frameworks, are supported everywhere. If you going
to use a PHP MVC framework, like codeignitor, you would have a hard
time finding a hoster that didn't support it - all you need is php4
and mysql. Dollar-hosting, for $10 a year, should work just fine with
codeignitor. With codeignitor, just copy your files to whatever host,
and that's it, you're done.

By contrast, the most popular Python frameworks have sky-high system
requirements. Take a look at the requirements and/or recomendations
for popular Python frameworks like Django, TurboGears, or CherryPy:
Apache 2.0, mod_python (latest version), fastcgi (at least), command
line access, PostgreSQL. And a lot of low-cost hosters don't support
Python at all.

The comparison is not fair on many levels. PHP is not a framework like
Django or TG. You get a lot more stuff with Django or TG, so of course
the requirements are higher.
Wait a minute, did he write "Also, PHP and PHP frameworks are supported
everywhere..."? And he is right, you can drop symphony or cakePHP in
your webroot and it will work, period.
>
Seriously, take a closer look at CherryPy. With CherryPy, you don't even
need Apache since it provides its own web server.
So how do you run this in production? There's only one port 80, you'd
need e.g. mod_proxy + CherryPy on a high port as a long running process.
That's just not possible in most shared hosting envs, plus you'd have to
monitor cherrypy and whatnot.

Don't get me wrong, I'm not defending PHP but from a deployment POV
python is definitely more complex.

cheers
Paul

Jul 26 '07 #20
On Jul 22, 12:17 am, Bruno Desthuilliers
<bdesth.quelquech...@free.quelquepart.frwrote:
Either you are a casual user with 101 web
development skills trying to set up your personal home page
But this, sort of, brings me back to my original point. Nobody starts
out being advanced. There are substantial differences in cost, and
deployment, between PHP and Python. It is much easier to get started
with PHP. And once somebody has started with PHP, that person is
likely to stay with PHP. Most PHP developers do not see a compelling
reason to start all over again with Python.

BTW: I have a certain amount of respect for PHP, and PHP developers.
PHP5 is a big step forward over PHP4. And, there have been substantial
web projects completed with PHP - probably more so than with Python.

Jul 26 '07 #21
walterbyrd wrote:
On Jul 22, 12:17 am, Bruno Desthuilliers
<bdesth.quelquech...@free.quelquepart.frwrote:
>Either you are a casual user with 101 web
development skills trying to set up your personal home page

But this, sort of, brings me back to my original point. Nobody starts
out being advanced. There are substantial differences in cost, and
deployment, between PHP and Python. It is much easier to get started
with PHP. And once somebody has started with PHP, that person is
likely to stay with PHP. Most PHP developers do not see a compelling
reason to start all over again with Python.

BTW: I have a certain amount of respect for PHP, and PHP developers.
PHP5 is a big step forward over PHP4. And, there have been substantial
web projects completed with PHP - probably more so than with Python.
If PHP does everything they want, why should they change to Python? I am
as keen as anyone else to see Python widely adopted, but not at the
expense of forcing a tool down an unwilling population's throats.

Python is a programming language first, PHP has become one almost
incidentally. It's good at (some) things that Python isn't. It's
horrible at others (for example OO in PHP is almost as horrible as OO in
Perl). Learn to live with it! ;-)

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC/Ltd http://www.holdenweb.com
Skype: holdenweb http://del.icio.us/steve.holden
--------------- Asciimercial ------------------
Get on the web: Blog, lens and tag the Internet
Many services currently offer free registration
----------- Thank You for Reading -------------

Jul 26 '07 #22
Jeff schreef:
No programming language can fix bad programmers. And if cost is an
issue, www.nearlyfreespeech.net has Python, clisp, and OCaml.
But only via CGI, which means every request results in a new instance of
the interpreter.

--
If I have been able to see further, it was only because I stood
on the shoulders of giants. -- Isaac Newton

Roel Schroeven
Jul 26 '07 #23
PHP is just a more inclusive community. The PHP community is more
concerned with the casual user and the end user. This is PHP's core
strength, and one of Python's core weaknesses. The Python community
would be wise to adopt PHP's concern for the end user.

That being said, I don't think you will find PHP easier than Python.
I think the reverse is true, except in the simplest cases. Also,
Python is economical and easy to use if you go with a Python centric
web host, such as Web Faction.

Jul 26 '07 #24
Jeffrey Froman <je*****@fro.manwrites:
Consider a PHP-based CMS that allows users to upload files. Because the
application runs as the webserver user, uploaded files, and the directory
where they reside, must be accessible and writable by that user. It is the
same user that any other hosting customer on that machine has access to.
Thus, any user on the shared host could write a quick CGI script that
accesses, adds, removes, or defaces your uploaded content.
That sounds trivial to ameliorate (at least somewhat) by putting your
uploads in a directory whose name is known only to you (let's say it's
a random 20-letter string). The parent directory can be protected to
not allow reading the subdirectory names.
Jul 26 '07 #25
Paul Rubin wrote:
Jeffrey Froman <je*****@fro.manwrites:
>Consider a PHP-based CMS that allows users to upload files. Because the
application runs as the webserver user, uploaded files, and the directory
where they reside, must be accessible and writable by that user. It is the
same user that any other hosting customer on that machine has access to.
Thus, any user on the shared host could write a quick CGI script that
accesses, adds, removes, or defaces your uploaded content.

That sounds trivial to ameliorate (at least somewhat) by putting your
uploads in a directory whose name is known only to you (let's say it's
a random 20-letter string). The parent directory can be protected to
not allow reading the subdirectory names.
But you have to admit that's "security by obscurity".

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC/Ltd http://www.holdenweb.com
Skype: holdenweb http://del.icio.us/steve.holden
--------------- Asciimercial ------------------
Get on the web: Blog, lens and tag the Internet
Many services currently offer free registration
----------- Thank You for Reading -------------

Jul 26 '07 #26
Steve Holden <st***@holdenweb.comwrites:
That sounds trivial to ameliorate (at least somewhat) by putting your
uploads in a directory whose name is known only to you (let's say it's
a random 20-letter string). The parent directory can be protected to
not allow reading the subdirectory names.

But you have to admit that's "security by obscurity".
I'm not completely sure it's security by obscurity if the system setup
is careful. The pathname is like a password and maybe it can be
proteced from exposure to the same degree that other file system
contents are protected. This would not pass review for protecting
launch codes, but neither most things done on even serious commercial
web sites.
Jul 26 '07 #27
On 26 Jul 2007 13:26:33 -0700, Paul Rubin
<"http://phr.cx"@nospam.invalidwrote:
Steve Holden <st***@holdenweb.comwrites:
That sounds trivial to ameliorate (at least somewhat) by putting your
uploads in a directory whose name is known only to you (let's say it's
a random 20-letter string). The parent directory can be protected to
not allow reading the subdirectory names.
But you have to admit that's "security by obscurity".

I'm not completely sure it's security by obscurity if the system setup
is careful. The pathname is like a password and maybe it can be
proteced from exposure to the same degree that other file system
contents are protected. This would not pass review for protecting
launch codes, but neither most things done on even serious commercial
web sites.
--
Would you make this directory name be the username+the password? If
not, why not? The answer is the same reason why this isn't a reliable
method of security.

That said, no hosting provider I'm aware of (even the really cheap
ones) runs in a purely shared environment anymore. They use suexec or
fakejail or something at the very least. This is for their own
protection as much (or more) than it is to protect their customers
data, though.
Jul 26 '07 #28
"Chris Mellon" <ar*****@gmail.comwrites:
Would you make this directory name be the username+the password? If
not, why not? The answer is the same reason why this isn't a reliable
method of security.
I would not store plaintext passwords in a database, but that doesn't
mean it's security by obscurity to do so.
Jul 26 '07 #29
SamFeltus a écrit :
PHP is just a more inclusive community. The PHP community is more
concerned with the casual user and the end user. This is PHP's core
strength, and one of Python's core weaknesses. The Python community
would be wise to adopt PHP's concern for the end user.
This assertion is at least debatable. It's true that Python is not as
easy to get started withn as it was some 7 years ago, and it's true that
some of use here are probably paying less and less attention to FAQs -
but what, they are FAQs, so it should be easy to find some answers.
Still, this NG and the overall Python community are amongst the most
tolerant and newbie-friendly around. Even some of the greatest masters
here are spending time answering to 101 questions on a regular basis.
That being said, I don't think you will find PHP easier than Python.
I think the reverse is true, except in the simplest cases.
Mmm... I certainly do find python easier, but I'm obviously biased since
I had time to learn it and know most of the gotchas. The problem might
be very different for newcomers, specially for the
'programming-illiterate' ones. I surely spend less time checking the doc
with Python than with PHP - thanks to good design, good naming,
consistency, REPL and in the worst interactive doc, all things missing
in PHP. OTHO, PHP is so basically braindead that it doesn't requires
anyone to be able to cope with the higher-level abstractions that make
Python so powerful.
Jul 27 '07 #30
On 2007-07-26, Steve Holden <st***@holdenweb.comwrote:
>That sounds trivial to ameliorate (at least somewhat) by putting your
uploads in a directory whose name is known only to you (let's say it's
a random 20-letter string). The parent directory can be protected to
not allow reading the subdirectory names.

But you have to admit that's "security by obscurity".
Um, no?
Jul 27 '07 #31
I don't suggest Python is unconcerned with the casual user and the end
user, only that this is where PHP's community excels.

Learnig both as a newbie, I actually found PHP more confusing and
difficult than Python. Programming in PHP reminds me of a game of
trivial pursuit. Once you know a little Python, you can often guess
how something new is going to be before you see it.

Jul 27 '07 #32

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: SC | last post by:
I'm trying to more accurately track visitors on one of my sites. Most of the visitors are from offices where they share an IP address. So, from one IP address, there might be 10 or more...
16
by: worzel | last post by:
is python more popular than coldfusion? I realsie that is a very general question as one thing does not directly relate to the other. My issue is that I am ditching coldfusion due to there being...
0
by: UrsusMaximus | last post by:
One measurement by which Python is more popular than Ruby, Java, Perl, PHP and .NET is in the world of Podcasts. At Podcastalley, podcasts are ranked by popularity in each of several genre's. In...
1
by: yasmine | last post by:
hi ; I would like to ask according to the features of .net framework ,we can write application in any language. Suppose I have 2 web applications one written by VB.net and other by Visual C#,last...
11
by: cooltech77 | last post by:
hi all, I was curious to know as to which language is used more for the codebehind files in aspnet is it VB.net or C#?I want to prepare for certification and wanted to decide wehther i want to...
4
by: ώε↮øй | last post by:
I have the whole group of .NET 2003 platforms sitting here from a dream I have of building some simple web based games (much like on msn zone) Any guidance as to where I start and what I need to...
122
by: seberino | last post by:
I'm interested in knowing which Python web framework is most like Ruby on Rails. I've heard of Subway and Django. Are there other Rails clones in Python land I don't know about? Which one...
1
by: Karlo Lozovina | last post by:
I've been browsing what Python has to offer in the world of web programming for past few weeks, while preparing to select something for small, quick and dirty projects where my favorable solution,...
3
by: Tony Girgenti | last post by:
Hello. I'm new to all of this. I developed a web consuming windows application/form program with VS.NET 2003, VB, .Net Framework 1.1.4322, ASP.NET 1.1.4322, IIS 5.1. I started converting it...
1
by: WebDesignersIreland | last post by:
Some days back I was reading one article on web designing. The article was basically about learning the techniques for designing a search engine friendly web site. The words are as such: “Podcasts...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.