[General] Ruby vs. PHP
Ossama Khayat
okhayat at yahoo.com
Wed Sep 26 14:47:56 +03 2007
I can't deny that one gets impressed by the power of RoR and how
quickly it can help you build up applications. But looking at Ruby's
syntax, I think I would rather learn Python instead for one main
reason: Clean Structured Syntax.
Like the author mentioned, what you can do in RoR or plain Ruby can be done by PHP or Python with/out any framework.
Since RoR is a Ruby based framework, you can have a look at Prado PHP framework (www.pradosoft.com) and Django Python framework (http://www.djangoproject.com/).
I'm
familiar with PHP and been using Prado for almost a month now. I admit
that because of my ASP.Net background, it helped quickly grasp the use
of the built-in components. But the main advantage in this framework is
the separation of Code from Design. Simply speaking, a designer only
works on the Front End (html xml css) and a programmer only works with
code, PHP. This image http://www.xisc.com/images/event-driven.gif might give you a quick example.
The
other nice thing about Prado is that it also borrows its concepts from
other frameworks like RoR (ActiveRecord) and Django so you have the
advantages of other frameworks in your hands.
One very imprtant aspect of using Prado, especially for CRUD (http://en.wikipedia.org/wiki/Create%2C_read%2C_update_and_delete) applications is the set of DataGrids and Scaffolds it provides.
These saved me ALOT of time when creating an application that has more than 35 tables and 10+ views.
You can have a look at the great demos available online and get started with it here:
Demos: http://www.pradosoft.com/demos/
Documentation: http://www.pradosoft.com/documentation/
Now,
about Python and Django. These two are really different. Like I
mentioned, the LOVE the Syntax. The most important things are:
1. There is no begin end $ @ # ; {} or what so ever.
2. It forces the programmer to write clean code, as tabs has to be used.
3. It uses dot notation which makes code easier to read.
You can find a nice tutorial on Python's site here: http://docs.python.org/tut/
-
Ossama
----- Original Message ----
From: bashar abdullah <bashar.abdullah at gmail.com>
To: General OpenSource Discussion <general at oskw.org>
Sent: Wednesday, September 26, 2007 10:41:45 AM
Subject: Re: [General] Ruby vs. PHP
nice one, though not gonna stop me from the RoR road, thanks. Nice to have other opinions.
On 9/26/07, Majed B. <
majedb at gmail.com> wrote:Hey people!
Here's a small blog entry:
http://www.oreillynet.com/ruby/blog/2007/09/7_reasons_i_switched_back_to_p_1.html
If you have the time, read the comments as well.
--
Majed B.
____________________________________________________________________________________
Don't let your dream ride pass you by. Make it a reality with Yahoo! Autos.
http://autos.yahoo.com/index.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://oskw.org/pipermail/general_oskw.org/attachments/20070926/dd0e6695/attachment.html>
More information about the General
mailing list