Re: Added-value over PHP?

2010-02-06 Thread Brian Neal
On Feb 3, 1:39 am, Delifisek Tux  wrote:
>
> A decent framework eats up your %50 of
> cpu resource. For example that Uber Zend FW gives you 1/6 in a hello world
> app comparing plain php.

Why would you want to write a Hello World program in a framework?

Try writing a very large app in a framework and then try using bare
PHP. Compare how much longer and how many more bugs do you get using
bare PHP. Compare how many SLOC it took in each. Which is easier to
maintain? Caching can be used to recover speed.

BN

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-06 Thread Vincent
On 3 fév, 16:08, Javier Guerra  wrote:
> that means, a well-coded framework can be extensive, sophisticated,
> even heavy; but still perform very quickly.

Thanks much Javier for the feedback.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-03 Thread Javier Guerra
Hi

I really liked your post, it captures the feeling where you were
walking down a path, feeling fine and suddenly you open a door... and
find that all the time you've been in an underground tunnel!


On Wed, Feb 3, 2010 at 2:39 AM, Delifisek Tux  wrote:
> WTF !??
>
> How can they wrote web apps when there where no $_REQUEST or equal...
>
> After some them you realize PHP was something very very very WEB programming
> oriented.


here.   a _lot_ of things that you thought 'sure, of course..' were in
fact PHP-specific things.  there are other ways to do them.


> Then big question is poping up.
>
> In PHP world, Framework means SLOW. A decent framework eats up your %50 of
> cpu resource. For example that Uber Zend FW gives you 1/6 in a hello world
> app comparing plain php.
>
> When you seeing this kind of question.
>
> It means How FAST is ?
>
> Basically we know python lot faster than PHP. But we don't know how how
> Django eats resources (or is it eating lot resources like php frameworks).


and the answer is that it's the wrong question

yes, python is faster than PHP; but not astoundingly so.  (i'd love to
do web development in Lua/LuaJIT, now _that_ is fast!)  it's that it
works different from PHP.

the biggest difference is that PHP is mostly run only in the
request/response cycle.  in most cases, it's compiled from source code
_on_each_and_every_request_.  Even with PHP accelerators/caches that
keep the already-parsed code in memory, it still starts with a fresh,
empty environment for every web hit.   therefore, a PHP framework has
to do _all_ the initialization work every time.

and that costs.  a lot

with general purpose programming languages (like python, or ruby;
heck, even Java), you don't have a pre-defined god-sent
request/response cycle.  you program that too.  and that means, you
can do things _before_ being asked!

for example, Django's ORM reads all its structures from your 'model'
files, and creates nice classes at runtime.  It's runtime, but more
precisely start-time.  that is, before the first request.  when you
get a request, you have the data objects ready to do any needed DB
querying.

another issue is cacheing, there are _lots_ of opportunities for
cache, at many different levels.  most of them are easy to do simply
because the framework's code stays up and running from one request to
the other.

that means, a well-coded framework can be extensive, sophisticated,
even heavy; but still perform very quickly.


-- 
Javier

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-03 Thread Philippe Raoult

I'll only reply to (2): Django is very suitable for web apps. I'm
building one and I've never felt limited in any way. Django lets you
write your own templates, so adding heavy ajax interfaces is painless.
I can't give you pointers because it's a custom in-house thing, but
it's close to 30k lines of python + html/js. The main focus is CRM and
document management.

Hope it helps.
Philippe

On 2 fév, 13:34, Fred  wrote:
> Hello
>
> I'm no expert on web applications, and have a couple of questions
> about Djanjo:
>
> 1. What are the advantages of using a framework like Django over
> writing the same type of database-driven in PHP?
>
> 2. Is Django domain-agnostic, or are there applications for which it's
> a better idea to use something else? The reason I ask is that the
> Wikipedia article says: "It was originally developed to manage several
> news-oriented sites for The World Company[3] of Lawrence, Kansas".
> I'm concerned that Django might be mostly thought for presenting
> articles, and might not be very suitable for web apps that are more
> interactive.
>
> Thank you for any feedback.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-03 Thread Delifisek Tux
On Wednesday 03 February 2010 05:51:59 Ovnicraft wrote:

> 2010/2/2 Shawn Milochik 

>

> > There is much to say on this topic. I suggest doing some Google
searching

> > on "Django versus PHP" and read until you know the answer to your

> > question.

> >

> > My brief summary is that Django lets you do everything you can do in
PHP,

> > and much better and faster because it has all the mundane and repetitive

> > stuff abstracted so you don't have to build any of it from scratch.
Also,

> > and the main reason I love it, is that you get to write Python instead
of

> > PHP.

> >

> > I don't know of any type of Web site that Django is bad for. Django is

> > flexible, and you can use only parts of it, all of it, and customize it

> > -- even edit the source code.

>

> Yes !, we are building an Enterprise GIS app, GeoDjango rocks !

>

> > Shawn

> >

Well,


First of all, I want to say to hello to everyone.


Then,


I'm trying to convert my self from PHP to Python too.


And I understood those kind of questions.


 Most PHP users (like me) does not have any programming background,


 When we try to improve our html jacking skills, some one suggest that php
thing. Next week we are become php programmers.

After some 10 years and projects and earning food and lots of happy
customers,


I'm getting bored.


I feel something not right.


And decide to learn new thins, after some research python shows up for good
candidate.


Then after spending a weekend


WTF !??


How can they wrote web apps when there where no $_REQUEST or equal...


After some them you realize PHP was something very very very WEB programming
oriented.


And realize, moving from PHP to Python cost too much time. You have to learn
lots of thing. Not just different syntax, function names, you need to learn
thinking different.


Then brilliant idea shows up. Why we won't use those Frameworks. After some
googling you found that django thing.


Then big question is poping up.


In PHP world, Framework means SLOW. A decent framework eats up your %50 of
cpu resource. For example that Uber Zend FW gives you 1/6 in a hello world
app comparing plain php.


When you seeing this kind of question.


It means How FAST is ?


Basically we know python lot faster than PHP. But we don't know how how
Django eats resources (or is it eating lot resources like php frameworks).


Regards...

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-02 Thread Ovnicraft
2010/2/2 Shawn Milochik 

> There is much to say on this topic. I suggest doing some Google searching
> on "Django versus PHP" and read until you know the answer to your question.
>
> My brief summary is that Django lets you do everything you can do in PHP,
> and much better and faster because it has all the mundane and repetitive
> stuff abstracted so you don't have to build any of it from scratch. Also,
> and the main reason I love it, is that you get to write Python instead of
> PHP.
>
> I don't know of any type of Web site that Django is bad for. Django is
> flexible, and you can use only parts of it, all of it, and customize it --
> even edit the source code.
>

Yes !, we are building an Enterprise GIS app, GeoDjango rocks !

>
> Shawn
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>


-- 
Cristian Salamea
CEO GnuThink Software Labs
Software Libre / Open Source
(+593-8) 4-36-44-48

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-02 Thread Nick Lo
> I'm no expert on web applications, and have a couple of questions
> about Djanjo:
> 
> 1. What are the advantages of using a framework like Django over
> writing the same type of database-driven in PHP?

You are comparing a development framework (Django) to a programming language 
(PHP). A better comparison would be Django to a PHP based framework like Zend 
Framework, Symfony, CakePHP OR the languages Python to PHP and the answer then 
would depend on a variety of things, starting with your existing experience of 
either language, what you are trying to do, etc.

> 2. Is Django domain-agnostic, or are there applications for which it's
> a better idea to use something else? The reason I ask is that the
> Wikipedia article says: "It was originally developed to manage several
> news-oriented sites for The World Company[3] of Lawrence, Kansas".
> I'm concerned that Django might be mostly thought for presenting
> articles, and might not be very suitable for web apps that are more
> interactive.

It is a general web application framework, but wether it is suitable "web apps 
that are more interactive", depends on what you mean by "interactive". You 
should get a good idea of how much you can do with Django here:

http://www.djangosites.org/

Cheers,

Nick

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-02 Thread Vincent
Thanks Richard.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-02 Thread Richard Shebora
http://pinaxproject.com/

On Tue, Feb 2, 2010 at 9:21 AM, Vincent  wrote:

> On 2 fév, 15:15, Shawn Milochik  wrote:
> > There is much to say on this topic. I suggest doing some Google searching
> on "Django versus PHP" and read until you know the answer to your question.
> >
> > My brief summary is that Django lets you do everything you can do in PHP,
> and much better and faster because it has all the mundane and repetitive
> stuff abstracted so you don't have to build any of it from scratch. Also,
> and the main reason I love it, is that you get to write Python instead of
> PHP.
> >
> > I don't know of any type of Web site that Django is bad for. Django is
> flexible, and you can use only parts of it, all of it, and customize it --
> even edit the source code.
>
> Thanks Shawn. I assumed PHP vs. Django was a common question from
> newbies, and asked here because it wasn't in the FAQ.
>
> Good to know that Django isn't limited to brochure sites. I'll read
> more about how to write Facebook-like social sites with it vs. PHP.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-02 Thread Vincent
On 2 fév, 15:15, Shawn Milochik  wrote:
> There is much to say on this topic. I suggest doing some Google searching on 
> "Django versus PHP" and read until you know the answer to your question.
>
> My brief summary is that Django lets you do everything you can do in PHP, and 
> much better and faster because it has all the mundane and repetitive stuff 
> abstracted so you don't have to build any of it from scratch. Also, and the 
> main reason I love it, is that you get to write Python instead of PHP.
>
> I don't know of any type of Web site that Django is bad for. Django is 
> flexible, and you can use only parts of it, all of it, and customize it -- 
> even edit the source code.

Thanks Shawn. I assumed PHP vs. Django was a common question from
newbies, and asked here because it wasn't in the FAQ.

Good to know that Django isn't limited to brochure sites. I'll read
more about how to write Facebook-like social sites with it vs. PHP.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Added-value over PHP?

2010-02-02 Thread Shawn Milochik
There is much to say on this topic. I suggest doing some Google searching on 
"Django versus PHP" and read until you know the answer to your question.

My brief summary is that Django lets you do everything you can do in PHP, and 
much better and faster because it has all the mundane and repetitive stuff 
abstracted so you don't have to build any of it from scratch. Also, and the 
main reason I love it, is that you get to write Python instead of PHP. 

I don't know of any type of Web site that Django is bad for. Django is 
flexible, and you can use only parts of it, all of it, and customize it -- even 
edit the source code. 

Shawn


-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.