Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
php vs python
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  Messages 1 - 25 of 79 - Collapse all  -  Translate all to Translated (View all originals)   Newer >
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
notbob  
View profile  
 More options May 21 2008, 4:10 pm
Newsgroups: comp.lang.php, comp.lang.python
Followup-To: comp.lang.php, comp.lang.python
From: notbob <not...@nothome.com>
Date: Wed, 21 May 2008 20:10:41 GMT
Local: Wed, May 21 2008 4:10 pm
Subject: php vs python
I'm not posting this just to initiate some religious flame war, though it's
the perfect subject to do so.  No, I actaully want some serious advice about
these two languages and since I think usenet is the best arena to find it,
here ya' go.

So, here's my delimna: I want to start a blog.  Yeah, who doesn't.  Yet, I
want learn the guts of it instead of just booting up some wordwank or
whatever.  I started to learn python, but heard php was easier or faster or
more like shell scripting or... fill in the blank.  Anyway, so I change over
to learning php.  Then I run across that blog, Coding Horror, and start
reading articles like this:

http://www.codinghorror.com/blog/archives/001119.html

Now what?  Go back to python.  Soldier on with php?  What do I know?  Not
much.  I can setup mysql and apache,, but don't know how to use 'em, really.
I use emacs and run slackware and can fumble my way through bash scripts,
but I can't really write them or do lisp.  I've taken basic basic and basic
C, but am barely literate in html.  Sometimes it seems overwhelming, but I
persevere because it's more fun/challenging than video games, which bore me
to tears.  

Well, that's my actual question, then.  Is php really so bad I'm just
wasting my time?  Or is it really the quickest way to blog functionality?
Would I be better served in the long run learning python, which claims to be
easy as pie to learn/program (still looks hard to me).  I admit I'm no code
geek.  But, I'm not completely brain dead, either, and I need something to
keep my geezer brain sparking.  What say ye?

nb


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jeffrey Froman  
View profile  
 More options May 21 2008, 4:55 pm
Newsgroups: comp.lang.php, comp.lang.python
Followup-To: comp.lang.php
From: Jeffrey Froman <jeff...@fro.man>
Date: Wed, 21 May 2008 13:55:40 -0700
Local: Wed, May 21 2008 4:55 pm
Subject: Re: php vs python

notbob wrote:
> I
> persevere because it's more fun/challenging than video games

This is the crux of the matter from where I'm sitting. If the purpose of
learning a programming language is fun, then the primary relevant question
is:

        Is it more fun to code in Python or PHP?

The answer is a no-brainer for me. It seems to me that Python is designed
from the ground up with my enjoyment in mind. Your Fun May Vary :-)

Jeffrey


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Carl Banks  
View profile  
 More options May 21 2008, 5:13 pm
Newsgroups: comp.lang.php, comp.lang.python
From: Carl Banks <pavlovevide...@gmail.com>
Date: Wed, 21 May 2008 14:13:15 -0700 (PDT)
Local: Wed, May 21 2008 5:13 pm
Subject: Re: php vs python
On May 21, 4:10 pm, notbob <not...@nothome.com> wrote:

> Sometimes it seems overwhelming, but I
> persevere because it's more fun/challenging than video games, which bore me
> to tears.

Ha, exactly the opposite here.

> Well, that's my actual question, then.  Is php really so bad I'm just
> wasting my time?  Or is it really the quickest way to blog functionality?
> Would I be better served in the long run learning python, which claims to be
> easy as pie to learn/program (still looks hard to me).  I admit I'm no code
> geek.  But, I'm not completely brain dead, either, and I need something to
> keep my geezer brain sparking.  What say ye?

If you just want to write a simple blog, PHP is probably good enough.
It's undeniably easier to jump into web programming with PHP--
partially because of it's widespread support and straightforward
usage, partially because Python web solutions tend to aim for
separability of content and presenation which raises the bar for
entry--and that could easily outweigh your concerns over quality of
the language.

(Incidentally: if you didn't want to start a religious war, it would
have been better if you had posted it separately to the two groups.
Lots of flamewars start by one person posting a cutdown not intended
for the ears of the other group.)

Carl Banks


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Damon Getsman  
View profile  
 More options May 21 2008, 5:19 pm
Newsgroups: comp.lang.php, comp.lang.python
From: Damon Getsman <dgets...@amirehab.net>
Date: Wed, 21 May 2008 14:19:56 -0700 (PDT)
Local: Wed, May 21 2008 5:19 pm
Subject: Re: php vs python
In my opinion, with the previous experience that you have in coding
that you've mentioned, you're probably better off if you minimize the
amount of new syntaxes you'll have to pick up.  Standard technique for
what you're trying to accomplish is more often than not Apache with
the PHP and MySQL support built in.  PHP has great support for
accessing a MySQL database, which is where the script would store and
load your entries (and/or other applicable data) from.  Then again,
you are really learning HTML, PHP, and MySQL at the same time, which
can be a pain in the ass.  There are some excellent books by O'Reilly
and Associates on just that subject, though.  They combine the PHP &
MySQL into one book that'll get you started and able to handle that
kind of task really quick.  The HTML syntax is going to be separate,
wherever you go.  It'll be simple if you want it dumping text to the
screen, and a pain in the ass if you want pretty formatting with
designs and text that lays out just in a certain area.

My suggestion, if you want to keep that gray meat sparking, is to go
with only html & php.  You could have the php dumping your entries
into date/time named textfiles on there when you're writing, and when
someone is reading, it just orders them sequentially by the date &
time in their filenames.

Then again, you learn the HTML+PHP+MySQL thing and you've got a skill
that you can market on Craigslist to a bunch of people for $20/hr
+.  :)

<a href="http://unix.derkeiler.com/Newsgroups/comp.sys.sun.apps/
2008-04/msg00000.html">
-Damon A. Getsman
Linux/Solaris Systems Administrator
</a>


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
notbob  
View profile  
 More options May 21 2008, 5:26 pm
Newsgroups: comp.lang.php, comp.lang.python
From: notbob <not...@nothome.com>
Date: Wed, 21 May 2008 21:26:43 GMT
Local: Wed, May 21 2008 5:26 pm
Subject: Re: php vs python
On 2008-05-21, Michael Vilain <vil...@NOspamcop.net> wrote:

> your site.  They may even have a blogging package you can administer
> entries without any programming.

> What's your end-goal here?  If you can't program, you may be better off
> with a package or tool that does all the heavy lifting for you.  

I said I didn't want to do that, but that's not entirely true.  I figured
I'd use one of the CMSs while learning how it works, much like linux.  I
hate doing something without knowing why.  Windows and Dreamweaver are good
examples.  Nope.  I want to get under the hood.

nb


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
notbob  
View profile  
 More options May 21 2008, 5:30 pm
Newsgroups: comp.lang.php, comp.lang.python
From: notbob <not...@nothome.com>
Date: Wed, 21 May 2008 21:30:39 GMT
Local: Wed, May 21 2008 5:30 pm
Subject: Re: php vs python
On 2008-05-21, Carl Banks <pavlovevide...@gmail.com> wrote:

> If you just want to write a simple blog, PHP is probably good enough.
> It's undeniably easier to jump into web programming with PHP--
> partially because of it's widespread support and straightforward
> usage, partially because Python web solutions tend to aim for
> separability of content and presenation which raises the bar for
> entry--and that could easily outweigh your concerns over quality of
> the language.

> (Incidentally: if you didn't want to start a religious war, it would
> have been better if you had posted it separately to the two groups.
> Lots of flamewars start by one person posting a cutdown not intended
> for the ears of the other group.)

Yeah, but years of usenet have taught me how to navigate the battlefield.
Your top paragraph above is the kind of advice I'm looking for.  Thank you.

nb


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
notbob  
View profile  
 More options May 21 2008, 5:57 pm
Newsgroups: comp.lang.php, comp.lang.python
From: notbob <not...@nothome.com>
Date: Wed, 21 May 2008 21:57:00 GMT
Subject: Re: php vs python
On 2008-05-21, Damon Getsman <dgets...@amirehab.net> wrote:

> My suggestion, if you want to keep that gray meat sparking, is to go
> with only html & php.  You could have the php dumping your entries
> into date/time named textfiles on there when you're writing, and when
> someone is reading, it just orders them sequentially by the date &
> time in their filenames.

> Then again, you learn the HTML+PHP+MySQL thing and you've got a skill
> that you can market on Craigslist to a bunch of people for $20/hr
> +.  :)

That certainly couldn't hurt.  Thank you for your advice.

nb


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Rubin  
View profile  
 More options May 21 2008, 6:44 pm
Newsgroups: comp.lang.php, comp.lang.python
From: Paul Rubin <http://phr...@NOSPAM.invalid>
Date: 21 May 2008 15:44:39 -0700
Local: Wed, May 21 2008 6:44 pm
Subject: Re: php vs python

notbob <not...@nothome.com> writes:
> Well, that's my actual question, then.  Is php really so bad I'm just
> wasting my time?  Or is it really the quickest way to blog functionality?

php is very easy to get started with and some big sites have been
written in it.  There is lots of low cost php hosting available.  It
is not as good a language as Python.  However, Python's advantages are
strongest in more complex projects.  For simple stuff, php is frankly
less hassle just because of its wide deployment and that extensive
function library that the blog post your quoted described as a bad
thing.  Python's libraries are not bad, but php's are more intensely
focused on web apps and includes what you need as part of the standard
build.  With Python, if you want a database adapter or web template
framework, you have to choose between a bunch of different ones and
download and configure it which often involves head scratching when
the auto-install stuff hits some quirk of your system.  With php, it's
all right there when you flip the switch.

Knowing lots of languages is good for you.  php is probably your
quickest route to getting a rudimentary web app running.  Python
is a longer term project.  Do both.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Baris-C  
View profile  
 More options May 21 2008, 9:20 pm
Newsgroups: comp.lang.php, comp.lang.python
From: Baris-C <bar...@bckm.org>
Date: Wed, 21 May 2008 18:20:18 -0700 (PDT)
Local: Wed, May 21 2008 9:20 pm
Subject: Re: php vs python
On May 21, 11:10 pm, notbob <not...@nothome.com> wrote:

By the way anything goes to you..

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Larry Bates  
View profile  
 More options May 21 2008, 9:48 pm
Newsgroups: comp.lang.php, comp.lang.python
From: Larry Bates <larry.ba...@websafe.com`>
Date: Wed, 21 May 2008 20:48:44 -0500
Local: Wed, May 21 2008 9:48 pm
Subject: Re: php vs python

Check out the Pylons blog tutorial.  You will have a simple blog up and running
in less than 30 minutes and have a platform to extend it with as much
functionality as you want later on.

Larry Bates

Pylons blog tutorial:

http://wiki.pylonshq.com/display/pylonscookbook/Making+a+Pylons+Blog


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
NC  
View profile  
 More options May 22 2008, 1:28 am
Newsgroups: comp.lang.php, comp.lang.python
From: NC <n...@iname.com>
Date: Wed, 21 May 2008 22:28:32 -0700 (PDT)
Local: Thurs, May 22 2008 1:28 am
Subject: Re: php vs python
On May 21, 1:10 pm, notbob <not...@nothome.com> wrote:

> So, here's my delimna: I want to start a blog.  Yeah, who doesn't.
> Yet, I want learn the guts of it instead of just booting up some
> wordwank or whatever.

Here's a simple computation to consider...  WordPress' codebase is
approximately a megabyte of PHP code and megabyte of JavaScript code.
Assuming that the average line of that code is 50 characters long, you
are looking at 20,000 lines of code in PHP and as many in JavaScript.
Based on the notion that the average developer out there writes 100
lines a day, either you're in for a two-year project or your product
is going to have seriously reduced functionality compared to something
that's been freely available for years.  What's your choice?

> Then I run across that blog, Coding Horror, and start reading
> articles like this:

> http://www.codinghorror.com/blog/archives/001119.html

You should read what some computer scientists write about SQL... :)

> Now what?

Nothing.  Everyone is entitled to their opinion.  You are free to form
your own.

> I've taken basic basic and basic C, but am barely literate
> in html.

Maybe that (and some JavaScript) is something to work on first before
delving into server-side programming?

> Well, that's my actual question, then.  Is php really so bad
> I'm just wasting my time?  Or is it really the quickest way
> to blog functionality?

The quickest way to blog functionality is an account on a blogging
service...  :)

> Would I be better served in the long run learning python, which
> claims to be easy as pie to learn/program (still looks hard to
> me).  I admit I'm no code geek.  But, I'm not completely brain
> dead, either, and I need something to keep my geezer brain
> sparking.  What say ye?

If the purpose is to keep the brain sparking, it doesn't matter what
you learn as long as you're enjoying the process.  You might as well
take up Japanese while you're at it...

Cheers,
NC


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Nick Craig-Wood  
View profile  
 More options May 22 2008, 11:30 am
Newsgroups: comp.lang.php, comp.lang.python
From: Nick Craig-Wood <n...@craig-wood.com>
Date: Thu, 22 May 2008 10:30:07 -0500
Local: Thurs, May 22 2008 11:30 am
Subject: Re: php vs python

Damon Getsman <dgets...@amirehab.net> wrote:
> PHP has great support for accessing a MySQL database,

Actually I'd say PHP's mysql support is lacking a very important
feature.  mysql_query() doesn't support parameters (or placeholders,
usually '?')  which means that unless you use
mysql_real_escape_string() on all user input you are leaving yourself
wide open for SQL injection attacks.

With all the other non-PHP mysql programming I've done you use
parameters for all user input and you don't have to worry.

It is not a big deal, but I've had it drummed into me to always use
parameters for user input and I was really suprised PHP didn't have
them.

--
Nick Craig-Wood <n...@craig-wood.com> -- http://www.craig-wood.com/nick


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
notbob  
View profile  
 More options May 22 2008, 12:25 pm
Newsgroups: comp.lang.php, comp.lang.python
From: notbob <not...@nothome.com>
Date: Thu, 22 May 2008 16:25:41 GMT
Local: Thurs, May 22 2008 12:25 pm
Subject: Re: php vs python
On 2008-05-22, Larry Bates <larry.ba...@websafe.com`> wrote:

> Check out the Pylons blog tutorial.  You will have a simple blog up and running
> in less than 30 minutes and have a platform to extend it with as much
> functionality as you want later on.

> Larry Bates

> Pylons blog tutorial:

> http://wiki.pylonshq.com/display/pylonscookbook/Making+a+Pylons+Blog

Thnx, Larry.  FYI: the above page doesn't exist:

"The page you were trying to reach does not exist. You may want to try a
search, or browse the site to find the page you were looking for."

....but, there's a link to a pylons cookbook, which I will explore.

nb


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
notbob  
View profile  
 More options May 22 2008, 12:29 pm
Newsgroups: comp.lang.php, comp.lang.python
From: notbob <not...@nothome.com>
Date: Thu, 22 May 2008 16:29:37 GMT
Local: Thurs, May 22 2008 12:29 pm
Subject: Re: php vs python
On 2008-05-21, Paul Rubin <http> wrote:

> Knowing lots of languages is good for you.  php is probably your
> quickest route to getting a rudimentary web app running.  Python
> is a longer term project.  Do both.

Good advice.  Thank you.

nb


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Rafe Culpin  
View profile  
 More options May 22 2008, 12:37 pm
Newsgroups: comp.lang.php
From: nos...@see.sig.to.reply (Rafe Culpin)
Date: Thu, 22 May 2008 17:37 +0100 (ope)
Subject: Re: php vs python
In article <slrng3b383.iqd.n...@irishsea.home.craig-wood.com>, n...@craig-wood.com

(Nick Craig-Wood) wrote:
> Actually I'd say PHP's mysql support is lacking a very important
> feature.  mysql_query() doesn't support parameters (or placeholders,
> usually '?')  which means that unless you use
> mysql_real_escape_string() on all user input you are leaving yourself
> wide open for SQL injection attacks.

Use the MySQL Improved Extension - mysqli, not mysql

--
To reply email rafe, at the address cix co uk


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Peter H. Coffin  
View profile  
 More options May 22 2008, 1:38 pm
Newsgroups: comp.lang.php
From: "Peter H. Coffin" <hell...@ninehells.com>
Date: Thu, 22 May 2008 12:38:59 -0500
Local: Thurs, May 22 2008 1:38 pm
Subject: Re: php vs python

Buhwha? What's mysqli_prepare() for then?

http://us.php.net/mysqli_prepare

PHP didn't used to have that kind of functionality, but that knowlege is
about three years out of date.

--
For why should my freedom be judged by another's conscience?  
                            -- Paul (I Corinthians 10:29)


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Mike Driscoll  
View profile  
 More options May 22 2008, 2:34 pm
Newsgroups: comp.lang.php, comp.lang.python
From: Mike Driscoll <kyoso...@gmail.com>
Date: Thu, 22 May 2008 11:34:55 -0700 (PDT)
Local: Thurs, May 22 2008 2:34 pm
Subject: Re: php vs python
On May 21, 3:10 pm, notbob <not...@nothome.com> wrote:

TurboGears and Django are pretty cool Python web application
frameworks. I would recommend looking at them too.

Mike


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
inhahe  
View profile  
 More options May 22 2008, 6:14 pm
Newsgroups: comp.lang.php, comp.lang.python
From: "inhahe" <inh...@gmail.com>
Date: Thu, 22 May 2008 18:14:53 -0400
Local: Thurs, May 22 2008 6:14 pm
Subject: Re: php vs python
I don't like php.  I tried it once and I had it sort a list, but the list
was apparently too long for its sorting function because it just sorted the
first so-many elements of it and left the rest in order, and didn't generate
any error.  I like a language that's actually determined by what you tell it
to do.   I hear it has a lot of security issues too.  I'm not sure that php
*runs* faster than python, having seen benchmarks, but it certainly loads
faster.  Maybe not so much of a difference once python25.dll is already in
the cache though (speaking from a windows perspective).  because when i load
a program it can take a while but it's pretty quick if i'd just loaded one
recently.  but you don't necessarily have to load python for each page
rendering anyway.

I like the Python language a lot better than php.  but I just really like
Python.

php mixes html and code out-of-the-box (sort of.. i guess it's more like a
reversal of which one is explicit)... if you use Python you should look into
a 'templating engine' like mako.  i use cheetah, but mako is supposed to be
better.

i think Python is the easiest language to learn, with the possible exception
of qbasic (just because making multidimensional arrays in python isnt that
obvious, although maybe it is using numpy, i've never tried it).  Python
isn't as easy as basic if you use/have to read the more advanced features,
but those aren't even available in basic. so I find it a comfortable
learning curve.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jerry Stuckle  
View profile  
 More options May 22 2008, 11:09 pm
Newsgroups: comp.lang.php, comp.lang.python
From: Jerry Stuckle <jstuck...@attglobal.net>
Date: Thu, 22 May 2008 23:09:34 -0400
Local: Thurs, May 22 2008 11:09 pm
Subject: Re: php vs python

inhahe wrote:
> I don't like php.  I tried it once and I had it sort a list, but the list
> was apparently too long for its sorting function because it just sorted the
> first so-many elements of it and left the rest in order, and didn't generate
> any error.  I like a language that's actually determined by what you tell it
> to do.  

Then I suspect you had an error in your code.  PHP's sort functions work
fine.

> I hear it has a lot of security issues too.  

The language has no security issues.  Programmers have security issues -
whether it be PHP, Python or any other language.

> I'm not sure that php
> *runs* faster than python, having seen benchmarks, but it certainly loads
> faster.  Maybe not so much of a difference once python25.dll is already in
> the cache though (speaking from a windows perspective).  because when i load
> a program it can take a while but it's pretty quick if i'd just loaded one
> recently.  but you don't necessarily have to load python for each page
> rendering anyway.

> I like the Python language a lot better than php.  but I just really like
> Python.

I like PHP much better than Python.  To each their own.

> php mixes html and code out-of-the-box (sort of.. i guess it's more like a
> reversal of which one is explicit)... if you use Python you should look into
> a 'templating engine' like mako.  i use cheetah, but mako is supposed to be
> better.

PHP can do that.  There are also a number of templating engines
available.  The nice thing about PHP is you have a choice.

> i think Python is the easiest language to learn, with the possible exception
> of qbasic (just because making multidimensional arrays in python isnt that
> obvious, although maybe it is using numpy, i've never tried it).  Python
> isn't as easy as basic if you use/have to read the more advanced features,
> but those aren't even available in basic. so I find it a comfortable
> learning curve.

I found PHP easier to learn than Python.  But that may be because I
already have a strong C/C++ background.

There isn't anything wrong with Python.  I just prefer PHP.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
inhahe  
View profile  
 More options May 23 2008, 12:40 am
Newsgroups: comp.lang.php, comp.lang.python
From: "inhahe" <inh...@gmail.com>
Date: Fri, 23 May 2008 00:40:50 -0400
Local: Fri, May 23 2008 12:40 am
Subject: Re: php vs python

> PHP can do that.  There are also a number of templating engines
> available.  The nice thing about PHP is you have a choice.

i just meant that php is sort of invented to combine html and code, so if
you use python instead you should use a templating engine.  but i suppose
it's useful for php too.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Michael Fesser  
View profile  
 More options May 23 2008, 3:29 am
Newsgroups: comp.lang.php, comp.lang.python
From: Michael Fesser <neti...@gmx.de>
Date: Fri, 23 May 2008 09:29:42 +0200
Local: Fri, May 23 2008 3:29 am
Subject: Re: php vs python
.oO(Nick Craig-Wood)

>Damon Getsman <dgets...@amirehab.net> wrote:
>> PHP has great support for accessing a MySQL database,

>Actually I'd say PHP's mysql support is lacking a very important
>feature.  mysql_query() doesn't support parameters (or placeholders,
>usually '?')

Where were you the last couple of years? It's lacking a lot more
features, but that's not the fault of the MySQL extension, which is
quite old. Meanwhile we have the improved MySQL extension and PDO.

>It is not a big deal, but I've had it drummed into me to always use
>parameters for user input and I was really suprised PHP didn't have
>them.

PHP supports them since _years_, you just have to choose the right
database interface.

Micha


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Andrew Lee  
View profile  
 More options May 23 2008, 5:53 am
Newsgroups: comp.lang.php, comp.lang.python
From: Andrew Lee <fiacre.patr...@gmail.com>
Date: Fri, 23 May 2008 05:53:22 -0400
Local: Fri, May 23 2008 5:53 am
Subject: Re: php vs python

Personally, I believe PHP would get you more productive more quickly for
a blog, but it is a potentially brain damaging language in terms of
really getting your juices flowing with programming.  It is not a
general purpose language and suffers from all the limitations of of a
tool designed for one job.  If you are interested in programming and the
blog is your path to that, stick with Python!  In particular, immerse
yourself in mod_python or look at a framework like Django or Pylons --
the learning curve is steep for any of these technologies but they are a
full meal compared to saltine cracker and water of PHP.

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Erwin Moller  
View profile  
 More options May 23 2008, 7:37 am
Newsgroups: comp.lang.php, comp.lang.python
From: Erwin Moller <Since_humans_read_this_I_am_spammed_too_m...@spamyourself.com>
Date: Fri, 23 May 2008 13:37:38 +0200
Local: Fri, May 23 2008 7:37 am
Subject: Re: php vs python
Andrew Lee schreef:

Some statement Andrew.
Care to clarify that a little?
I don't know much Python (aside from a little in ZOPE), but I did a lot
of Java, Perl, VB/ASP (juck), and a little C before I learned PHP.
I stopped using all in favor of PHP.

If your statement says PHP is abused a lot, yes. Because it is
relatively easy to learn for new programmers, a lot of bad PHP coders
exist.
But I saw them too in Java/Perl/etc.
And I am sure you can find them too coding Python.

It is perfectly possible to write clean good code in PHP.

Why do you say it 'tastes less' then Python?
I don't want to start a religious war, but am curious.
Who knows, maybe  I'll dump PHP and start using Python after your
answer. ;-)

Regards,
Erwin Moller


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jerry Stuckle  
View profile  
 More options May 23 2008, 7:41 am
Newsgroups: comp.lang.php, comp.lang.python
From: Jerry Stuckle <jstuck...@attglobal.net>
Date: Fri, 23 May 2008 07:41:59 -0400
Local: Fri, May 23 2008 7:41 am
Subject: Re: php vs python

inhahe wrote:
>> PHP can do that.  There are also a number of templating engines
>> available.  The nice thing about PHP is you have a choice.

> i just meant that php is sort of invented to combine html and code, so if
> you use python instead you should use a templating engine.  but i suppose
> it's useful for php too.

Not at all.  With PHP, it's possible to do so, but not required.  With
Python, OTOH, you pretty much have to use a templating engine.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jerry Stuckle  
View profile  
 More options May 23 2008, 7:42 am
Newsgroups: comp.lang.php, comp.lang.python
From: Jerry Stuckle <jstuck...@attglobal.net>
Date: Fri, 23 May 2008 07:42:39 -0400
Local: Fri, May 23 2008 7:42 am
Subject: Re: php vs python

And what job is that?  I have a lot of batch scripts written in PHP, for
instance.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Messages 1 - 25 of 79   Newer >
« Back to Discussions « Newer topic     Older topic »