PHP and Python
* Both have good framework web.py | codeigniter
* Both have good helpful community and support
* Both large set of plugins
How will it impact my webapp if it is written in Python and not PHP
1–10 of 89 posts
PHP and Python
* Both have good framework web.py | codeigniter
* Both have good helpful community and support
* Both large set of plugins
How will it impact my webapp if it is written in Python and not PHP
It's possible to write good code with PHP, but a great deal of the example code you'll find online is not good. On top of that, the language itself tends to encourage bad design (see "broken window theory").
Python has a strong culture of having one obvious and good way to do things. In some situations, that can feel restrictive, but it tends to make dealing with code other people wrote easier.
Python will probably be easier to write and almost certainly be easier to maintain. It's possible to write good code with PHP, but a great deal of the example code you'll find online is not good. On top of that, the language itself tends to encourage bad design (see "broken window theory"). Python has a strong culture of having one obvious and good way to do things. In some situations, that can feel restrictive, but…
I say this as someone who is working on a Pylons site. You can do anything with Pylons that is possible with Python, you just have to figure it out yourself or twist someone else's library to make it work. Sometimes you don't need that much freedom and the guided approach will do 90% of what you need. Do a bit of research and see which approach best suits your needs.
Work through a Python tutorial (I suggest "Dive Into Python") first and then set up Django and work through the Django tutorial. Build a small app of your own with Django.
If you are a decent programmer all the above should take you a weekend at most.
And then you'll have some first hand experience about difficulty of transition etc.
Fwiw, I prefer Django to PHP. But then I am biased so use appropriate amounts of salt. I'd kill myself if I had to work for very long in PHP.
I'm biased towards Python.
Python will probably be easier to write and almost certainly be easier to maintain. It's possible to write good code with PHP, but a great deal of the example code you'll find online is not good. On top of that, the language itself tends to encourage bad design (see "broken window theory"). Python has a strong culture of having one obvious and good way to do things. In some situations, that can feel restrictive, but…
How do you relate "broken window theory" with the grammar of PHP?
Most of the complaints I can think of about PHP that are objectively demonstrable are outdated. The language now has namespaces, closures and the like. Most of the complaints I have left have to do with the feel of the language, and some remaining cultural elements; it feels like a ghetto, even though it seems to have modern infrastructure now.
Python will probably be easier to write and almost certainly be easier to maintain. It's possible to write good code with PHP, but a great deal of the example code you'll find online is not good. On top of that, the language itself tends to encourage bad design (see "broken window theory"). Python has a strong culture of having one obvious and good way to do things. In some situations, that can feel restrictive, but…
How do you relate "broken window theory" with the grammar of PHP?