I only know PHP. How do I write a Web application in Python?
191–196 of 196 posts
Re: I only know PHP. How do I write a Web application in Python?
#192Earlier quoted context omitted.
Let's look at the PHP version: Hello World! One line. I didn't have to worry about Linux/Windows, knowing HTTP headers or the fact that I need two CRLFs after the last header[1]. I just wanted a page that says "Hello World!" and that's what I got. Don't get me wrong, I would never choose to write a web app in PHP over python. But it is brain dead simple to go from nothing to something in a few keystrokes. Which is pr…
Yeah, PHP is great to start off with, it's simple and everything in the language is obvio- Parse error: syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM
Re: I only know PHP. How do I write a Web application in Python?
#193Re: I only know PHP. How do I write a Web application in Python?
#194Should I really learn Pyramid instead of Django? I'm thinking about what would give me most value as a developer, one who already knows his python.
Pyramid, on the other hand, deliberately not a full stack framework, sacrificing ease-of-use for flexibility. It doesn't include any database opinions at all, can swap templating languages on a whim and wouldn't know a form if you hit it over the head with one. The upside is that it has first class core components, really well defined extension points, an unmatched routing system, and a few truly excellent plugins (I love you pyramid_tm). The downside, of course, is that you will own your entire stack, which means that A) there is more up-front work researching, designing, and developing your application's component stack and B) there's no central community guaranteed to be using the same stack as you. Overall, pyramid is suited for essentially any use case, so long as you put the work into it.
tldr: Django is (somewhat) inflexible but easy, Pyramid is flexible but more demanding. Both are excellent.
There are probably more jobs working with Django, if that's a consideration.
Re: I only know PHP. How do I write a Web application in Python?
#195I like java for web app development, simply because it has a well-structured api and a massive community of developers who have run in to the majority of the road blocks you will most likely encounter on the way to launching your app.
What frameworks and platforms would you recommend for web development with java? I am writing my senior project at college in java (mainly because of the wide amount of image processing libraries available) and would love to add web capabilities.
Re: I only know PHP. How do I write a Web application in Python?
#196Earlier quoted context omitted.
Python 3 is not "really that new" and Python 2.6-2.7 is not "old" in any way. In fact we have: pre-2.4 (really old, preinstalled on old Redhats), 2.4-2.7, 3.x Python 3 is curing problem with variable visibility (and if you do not write in "pure" functional way - you will never see this problem) and unicode strings. Other differences is not so "revolutionary".
> (and if you do not write in "pure" functional way - you will never see this problem) Could you explain this a little more, please?
I'm talking about http://www.python.org/dev/peps/pep-3104
New keyword nonlocal and ability to have better closures.