Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

PHP vs. Python for the web
I am a Python programmer and I'm thinking about learning PHP, which is
similar to C++ (quite different from Python). I want to start writing web
applications. Do you think if I learn PHP I'll develop faster? Does PHP
have more features? How about the speed of execution? What are the pros
and cons? Our server can run both Python, Perl and PHP, so I have the
choice.
Thanks for your opinion,

--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/

Report this thread to moderator Post Follow-up to this message
Old Post
Unknown User
04-15-05 08:56 AM


Re: PHP vs. Python for the web
In article <op.so848scor3xrds@sony>, "Unknown User" <me@privacy.net>
wrote:

> I am a Python programmer and I'm thinking about learning PHP, which is
> similar to C++ (quite different from Python). I want to start writing web
> applications. Do you think if I learn PHP I'll develop faster? Does PHP
> have more features? How about the speed of execution? What are the pros
> and cons? Our server can run both Python, Perl and PHP, so I have the
> choice.
> Thanks for your opinion,

You're more likely to find a shared ISP that offers PHP than Python.
Which means that web sites will be cheaper to run if they're developed
with PHP in a shared environment than in Python on a dedicated or
co-located server.

--
DeeDee, don't press that button!  DeeDee!  NO!  Dee...




Report this thread to moderator Post Follow-up to this message
Old Post
Michael Vilain
04-15-05 01:55 PM


Re: PHP vs. Python for the web
Unknown User wrote:

> I am a Python programmer and I'm thinking about learning PHP, which is
> similar to C++ (quite different from Python).

...no not really - both use curly braces to delimit blocks but that's about
it.

> I want to start writing web
> applications. Do you think if I learn PHP I'll develop faster? Does PHP
> have more features? How about the speed of execution? What are the pros
> and cons? Our server can run both Python, Perl and PHP, so I have the
> choice.

I'm well known as a Perl detractor. Python is more than capable, and ZOPE
provides a wonderful framewotk for developing web applications....but
there's an awful lot more PHP web programming going on out there than
anything else.

HTH

C.

Report this thread to moderator Post Follow-up to this message
Old Post
Colin McKinnon
04-15-05 08:56 PM


Re: PHP vs. Python for the web
Colin McKinnon wrote:

> Unknown User wrote:
>
> 
>
>
> ...no not really - both use curly braces to delimit blocks but that's abou
t
> it.

Yeah - PHP is more similar to C than C++.  It clones a lot of the string
functions (strstr, strchr, etc.) that C has.

Jamie

Report this thread to moderator Post Follow-up to this message
Old Post
James Pittman
04-15-05 08:56 PM


Re: PHP vs. Python for the web
James Pittman wrote:
> Colin McKinnon wrote:
> 
>
> Yeah - PHP is more similar to C than C++.  It clones a lot of the string
> functions (strstr, strchr, etc.) that C has.
>

It's not that similar to either C or C++. PHP doesn't have pointers,
explicitly typed variables, explicit return types, a compiler to pick up
syntax errors, or memory allocation issues, to name but a few major
differences.

PHP is a managed language, C++ isn't (i.e. if you create an object *you*
are responsible for deleting it, this concept doesn't exist in PHP). And
using arrays in C++ is nothing like using arrays in PHP.

So yes, a page of PHP code may look superficially similar to a page of
C/C++ code (especially since a lot of the function names are the same,
as you say), but using it to do something in the real world is a
*completely* different experience to using C/C++.

--
Oli

Report this thread to moderator Post Follow-up to this message
Old Post
Oli Filth
04-15-05 08:56 PM


Re: PHP vs. Python for the web
On Fri, 15 Apr 2005 08:09:06 -0400, James Pittman <jpittman1@yahoo.com> wrot
e:

>Colin McKinnon wrote: 
>
>Yeah - PHP is more similar to C than C++.

Yes, but...

>It clones a lot of the string
>functions (strstr, strchr, etc.) that C has.

C++ has strstr as well - C++ has all the standard library functions that C
has. strstr is declared in <string.h> for C, so in C++ it's officially in
<cstring> - equivalents exist for all the basic C functions; C++ is very clo
se
to an exact superset of C. (Which doesn't mean that writing C in C++ is righ
t,
it's just possible)

PHP 5's improved the OO support considerably, but it leans more towards Java
than C++.

--
Andy Hassall / <andy@andyh.co.uk> / <http://www.andyh.co.uk>
<http://www.andyhsoftware.co.uk/space> Space: disk usage analysis tool

Report this thread to moderator Post Follow-up to this message
Old Post
Andy Hassall
04-16-05 01:56 AM


Re: PHP vs. Python for the web
Thank you guys. It would be actually to develop for a dedicated server
that we have. I think I'll give both a try. It's going to be interesting
to have 2 languages at hand.


On Fri, 15 Apr 2005 09:02:44 -0300, Colin McKinnon
<colin.deletethis@andthis.mms3.com> wrote:

> Unknown User wrote:
> 
>
> ...no not really - both use curly braces to delimit blocks but that's
> about
> it.
> 
>
> I'm well known as a Perl detractor. Python is more than capable, and ZOPE
> provides a wonderful framewotk for developing web applications....but
> there's an awful lot more PHP web programming going on out there than
> anything else.
>
> HTH
>
> C.



--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/

Report this thread to moderator Post Follow-up to this message
Old Post
Unknown User
04-16-05 08:56 PM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

PHP Language archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 07:19 PM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.