By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,676 Members | 2,262 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,676 IT Pros & Developers. It's quick & easy.

Python v PHP for web, and restarting Apache?

P: n/a
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.

Also, I seem to remember reading something about PHP being able to
recover from Apache restarting more easily than Python.

I am not trying to suggest anything here. I'm just asking.

Nov 17 '06 #1
Share this Question
Share on Google+
9 Replies


P: n/a
In <11********************@j44g2000cwa.googlegroups.c om>, walterbyrd
wrote:
I am not trying to suggest anything here. I'm just asking.
Asking what? Asking something usually involves a question. ;-)

Ciao,
Marc 'BlackJack' Rintsch
Nov 17 '06 #2

P: n/a
walterbyrd wrote:
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.
first thing... there are many many ways how to run a python-apache web
application..

- mod_python
- cgi
- fastcgi
- sci
- proxy

also the same way, for php:
- mod_php
- fastcgi
- cgi
- (maybe something more, i'm not much experienced with php)

so first you should tell us which python-solution would you like to
compare to which php-solution..
gabor
Nov 17 '06 #3

P: n/a
walterbyrd wrote:
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.
Using Python to develop web-applications is a very broad topic.

E.g. you don't have to restart Apache if you develop simple
short-running CGI-BIN programs. With a long-running web app (e.g. with
FastCGI) you might only kill the web app's process etc. Or you implement
a graceful restart in your web app or...
Also, I seem to remember reading something about PHP being able to
recover from Apache restarting more easily than Python.
As usual it depends.

Ciao, Michael.
Nov 17 '06 #4

P: n/a
On Nov 17, 12:07 pm, "walterbyrd" <walterb...@iname.comwrote:
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.
It depends what you do. CGI's operate much like PHP. mod_python has
auto-reloading (and by implication most frameworks that build on it.) A
poorly designed web application may require a restart. (Some people
also disable auto-reload for production servers for performance
advantages.)
Also, I seem to remember reading something about PHP being able to
recover from Apache restarting more easily than Python.
I can think of no reason why that would be true. Perhaps these are
poorly designed python applications?
I am not trying to suggest anything here. I'm just asking.
Ask away. The only bad question is an unasked question. Most of us can
act like adults here (although we all forget that from time to time.)

Python is much better suited to writing and mainting large web
applications though. Being both an experienced php and python
programmer, I can tell you I don't use php any more unless I have no
other choice.

-Sandra

Nov 18 '06 #5

P: n/a


On Nov 17, 4:46 pm, sandra.el...@gmail.com wrote:
On Nov 17, 12:07 pm, "walterbyrd" <walterb...@iname.comwrote:
I think I have read somewhere that using Python to develop
web-applications requires some restarting of the Apache server, whereas
PHP does not.It depends what you do. CGI's operate much like PHP. mod_python has
auto-reloading (and by implication most frameworks that build on it.) A
poorly designed web application may require a restart. (Some people
also disable auto-reload for production servers for performance
advantages.)
Also, I seem to remember reading something about PHP being able to
recover from Apache restarting more easily than Python.I can think of no reason why that would be true. Perhaps these are
poorly designed python applications?
I am not trying to suggest anything here. I'm just asking.Ask away. The only bad question is an unasked question. Most of us can
act like adults here (although we all forget that from time to time.)

Python is much better suited to writing and mainting large web
applications though. Being both an experienced php and python
programmer, I can tell you I don't use php any more unless I have no
other choice.

-Sandra
Sandra do you us ethe msot up to date php and python?
how fast is fastcgi v mod_python?
Have you ever used medusa? or some other python server directly?

Nov 18 '06 #6

P: n/a

sa**********@gmail.com wrote:
>
Python is much better suited to writing and mainting large web
applications though.
I have to ask: why is that? Because Python is more readable? Because
Python runs faster? Is Python more stable for large scale applications?
Does this apply when using Python with CGI, FastCGI, mod_python, or
what?

Nov 18 '06 #7

P: n/a
walterbyrd wrote:
>Python is much better suited to writing and mainting large web
applications though.

I have to ask: why is that?
modularity, modularity, and modularity.

</F>

Nov 18 '06 #8

P: n/a

Fredrik Lundh wrote:
>
modularity, modularity, and modularity.
Can't PHP be made to be just as modular?

As a matter of popular practise, I suppose that is not done. I would
think that it could be.

My big problem with PHP is the lack of backward compatibility. My big
problem with Python is that popular frameworks like django and
turbogears have sky-high system requirements. Few web-hosters have
Apache 2.X, mod_python 3.x, FastCGI, or Python 2.4.

Nov 18 '06 #9

P: n/a
walterbyrd a écrit :
Fredrik Lundh wrote:

>>modularity, modularity, and modularity.


Can't PHP be made to be just as modular?
PHP has no notion of modules.
As a matter of popular practise, I suppose that is not done. I would
think that it could be.
Certainly not the way Python is modular...

Nov 19 '06 #10

This discussion thread is closed

Replies have been disabled for this discussion.