|
|
|
|
||||||
![]() |
|
|
LinkBack | Outils de la discussion |
|
|
#1 |
|
Messages: n/a
Hébergeur: |
Hi,
I decided to make this _rather_ short, because I think noone wants to read a lot of long stuff. It is still too long though. But please believe me, I thought some time about the content. On http://www.langpop.com/ the author has some nice graphs. The trend seems to show that PHP is (still) a very popular language. PHP at the same time however, is a horrible language compared to ruby. I also do NOT at all believe that any speed difference was an important factor for PHP's popularity rise, nor is today. I think PHP benefitted from a growing web world, and in return ed (foster) the web world grow as well, together with apache and MySQL. (I remember the perl-cgi days ... ) Ruby has Rails, but Rails needs more libraries, and Rails has a very specific world-view (MVC) whereas PHP basically just cares about getting the c**p outta *SQL and the "thing done", as ugly as it may be. We could use Ruby instead for web-stuff, but Ruby as such lacks in this regard here and there, i.e. at times mod_ruby was just a pain to install, online-docu for ruby is still not that good (even though a lot has changed the last 2 years... Pickaxe was wonderful but things change so quickly...) ruby-cgi stinks a bit since it does not report where it found an error and is rather slow compared to a .php site, and "killer apps" like a phpBB variant for _ruby_ do not seem to shape up _without_rails (and even with rails, it seems a LOT of work..) Does anyone notice .rhtml files at all on the www? I see .php pages all the time. (Almost) all the webshops use them (yuck). Loads of blogs use php. The basic underlying task of what these scripts do is so simple, but ruby doesnt grow in this area as php did. Rails alone can not be the solution to compete with php on that area (assuming we want that) due to the lesser flexibility (I have experienced that MANY people who learn rails are just outright confused by ruby...): - Simplicity sometimes beats conventions. - Ugliness sometimes beats beauty. This is NOT an anti-rails post. This is a PRO post to get ruby fit for the www. Or at least, fitter/better! Back to www.langpop.com for querying top 3 "jobs wanted" notes, PHP and SQL is among them (rank 3 / rank 1). Yuck yuck yuck. But you see it still seems popular and I dare claim they would be better off using what is *needed* to complete a job in an elegant fashion - with ruby instead. At least that is my firm opinion - well written ruby code is shorter and more elegant than well written php code of comparable "feature set". The del.icio.us site was also "analyzed" on http://www.langpop.com/ - ruby and python both seem more popular than in the other grows. That must mean, that people search for both quite a lot. For example, Ogre3d, Blender project and the small game engine FiFE all have usable python bindings. No perl, no lua, no ruby on that. But ... PHP also wins on del.icio.us and in fact is only beaten by _JAVASCRIPT_ ! Does this hint at the importance of the www? ![]() My conclusio, even if people heard that too ofte... and I promise to be silent about it for some months to ![]() I think the www should be one of the most important aspects for ruby! -- Posted via http://www.ruby-forum.com/. |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
PHP isn't as consistent or beautiful as ruby, but it hardly matters
when you have online documentation like this: http://www.php.net/manual/en/ We (the ruby community) really should have excellent, up-to-date, comprehensive online documentation. Considering its online documentation, it is amazing that ruby is as popular as it is. Pickaxe I is great but stale now, and I am too cheap to buy the 2nd edition (like millions of other college/grad students out there). Are there any projects out there attempting to create good, online documentation for ruby? Are we waiting for 2.0 before doing this? >> I think the www should be one of the most important aspects for ruby! Agreed, who wants to write up a library porting or ruby-izing everything useful to www in PHP to ruby? Anyone? ![]() --john |
|
|
|
#3 |
|
Messages: n/a
Hébergeur: |
Marc Heiler wrote:
> Hi, > > Does anyone notice .rhtml files at all on the www? > mod_rewrite Pickaxe 2, dealing with 1.8, is as relevant today as the day it was printed. Rails has everything it needs and the amount of add-ons through gems, plugins, generators, etc... is amazing.. please give specific examples of a task you couldn't complete through rails and ask on the rails list for a suggestion. Please site an example where you found PHP easier than rails. @bwv549 The people updating ruby documentation do so on a voluntary basis. The amount of work that has already went into it is staggering and I am sure they would welcome more volunteers if you are interested. ilan -- Posted via http://www.ruby-forum.com/. |
|
|
|
#4 |
|
Messages: n/a
Hébergeur: |
Ilan Berci wrote:
> Please site an example where you found PHP easier than rails. mv index.php ~/public_html Sorry, but it's true. Deployment of PHP is trivial, deployment of Ruby isn't. That's one big reason why it's as popular as it is. -- Alex |
|
|
|
#5 |
|
Messages: n/a
Hébergeur: |
On Nov 7, 12:19 pm, Alex Young <a...@blackkettle.org> wrote:
> Ilan Berci wrote: > > Please site an example where you found PHP easier than rails. > > mv index.php ~/public_html > > Sorry, but it's true. Deployment of PHP is trivial, deployment of Ruby > isn't. That's one big reason why it's as popular as it is. Same as mv index.rb ~/public_html leaving only the necessity to do some mod_ruby configuration. (I'm not talking about Rails, just eruby) |
|
|
|
#6 |
|
Messages: n/a
Hébergeur: |
Hi --
On Wed, 7 Nov 2007, Vasyl Smirnov wrote: > On Nov 7, 12:19 pm, Alex Young <a...@blackkettle.org> wrote: >> Ilan Berci wrote: >>> Please site an example where you found PHP easier than rails. >> >> mv index.php ~/public_html >> >> Sorry, but it's true. Deployment of PHP is trivial, deployment of Ruby >> isn't. That's one big reason why it's as popular as it is. > > Same as mv index.rb ~/public_html > > leaving only the necessity to do some mod_ruby configuration. > > (I'm not talking about Rails, just eruby) I'm glad you pointed that out. This thread seems to be slipping into Ruby/Rails confusion, or perhaps to have been based on that confusion from the beginning. David -- Upcoming training by David A. Black/Ruby Power and Light, LLC: * Advancing With Rails, Edison, NJ, November 6-9 * Advancing With Rails, Berlin, Germany, November 19-22 * Intro to Rails, London, UK, December 3-6 (by Skills Matter) See http://www.rubypal.com for details! |
|
|
|
#7 |
|
Messages: n/a
Hébergeur: |
Vasyl Smirnov wrote:
> On Nov 7, 12:19 pm, Alex Young <a...@blackkettle.org> wrote: >> Ilan Berci wrote: >>> Please site an example where you found PHP easier than rails. >> mv index.php ~/public_html >> >> Sorry, but it's true. Deployment of PHP is trivial, deployment of Ruby >> isn't. That's one big reason why it's as popular as it is. > > Same as mv index.rb ~/public_html > > leaving only the necessity to do some mod_ruby configuration. Am I wrong in thinking that mod_ruby runs all scripts in the same interpreter, so they all share a namespace? -- Alex |
|
|
|
#8 |
|
Messages: n/a
Hébergeur: |
On Nov 7, 2007, at 4:19 AM, Alex Young wrote: > Ilan Berci wrote: >> Please site an example where you found PHP easier than rails. > mv index.php ~/public_html > > Sorry, but it's true. Deployment of PHP is trivial, deployment of > Ruby isn't. That's one big reason why it's as popular as it is. > > If by deployment of php, you mean using php in web development is trivial, yes it's true. If by deployment of php, you mean installing and configuring a php interpreter is trivial, it is not true at all. It's quite a task. All Apache modules can be a pain. |
|
|
|
#9 |
|
Messages: n/a
Hébergeur: |
On Nov 7, 1:11 pm, Alex Young <a...@blackkettle.org> wrote:
> Am I wrong in thinking that mod_ruby runs all scripts in the same > interpreter, so they all share a namespace? The following: page-a.rb #!/usr/local/bin/eruby <% class Foo def bar puts "Page A: Foo#bar<br>" end end def baz puts "Page A: baz<br>" end Foo.new.bar baz %> page-b.rb: #!/usr/local/bin/eruby <% class Foo def bar puts "Page B: Foo#bar<br>" end end def baz puts "Page B: baz<br>" end Foo.new.bar baz %> works just fine. I'm pretty new to both ruby and eruby, and only about to dive deeply into the latter. And yes, I've heard about some issues concerning the shared interpreter, though I've yet to run into them. The only problem so far was the need to turn on "RubyRequire auto- reload". |
|
|
|
#10 |
|
Messages: n/a
Hébergeur: |
On Nov 7, 8:14 am, Vasyl Smirnov <vasyl.smir...@gmail.com> wrote:
> On Nov 7, 1:11 pm, Alex Young <a...@blackkettle.org> wrote: > > > Am I wrong in thinking that mod_ruby runs all scripts in the same > > interpreter, so they all share a namespace? > > The following: > > page-a.rb > > #!/usr/local/bin/eruby > <% > class Foo > def bar > puts "Page A: Foo#bar<br>" > end > end > def baz > puts "Page A: baz<br>" > end > Foo.new.bar > baz > %> > > page-b.rb: > > #!/usr/local/bin/eruby > <% > class Foo > def bar > puts "Page B: Foo#bar<br>" > end > end > def baz > puts "Page B: baz<br>" > end > Foo.new.bar > baz > %> > > works just fine. Yes, it would, but that could be because each file runs over the other one. For example: C:\>type t1.rb class Foo def bar puts "Page A: Foo#bar<br>" end end def baz puts "Page A: baz<br>" end Foo.new.bar baz C:\>type t2.rb class Foo def bar puts "Page B: Foo#bar<br>" end end def baz puts "Page B: baz<br>" end Foo.new.bar baz C:\>irb irb(main):001:0> load 't1.rb' Page A: Foo#bar<br> Page A: baz<br> => true irb(main):002:0> load 't2.rb' Page B: Foo#bar<br> Page B: baz<br> => true irb(main):003:0> load 't1.rb' Page A: Foo#bar<br> Page A: baz<br> => true Obviously that's all in the same namespace/interpreter, but you don't see a problem. Instead, try something like this: C:\>type t1.rb p @foo ||= 'page 1' C:\>type t2.rb p @foo ||= 'page 2' C:\>irb irb(main):001:0> load 't1.rb' "page 1" => true irb(main):002:0> load 't2.rb' "page 1" => true |
|
|
|
#11 |
|
Messages: n/a
Hébergeur: |
On Nov 7, 6:10 pm, Phrogz <phr...@mac.com> wrote:
> [cut] > > Obviously that's all in the same namespace/interpreter, but you don't > see a problem. Instead, try something like this: > > [cut] OK, here we go: t1.rb: #!/usr/local/bin/eruby <% p @foo ||= 'page 1' %> t2.rb: #!/usr/local/bin/eruby <% p @foo ||= 'page 2' %> Result - works like a charm: t1 gives "page 1", t2 gives "page 2" (in the browser window, of course). No matter how many times and in what sequence I reload the pages. |
|
|
|
#12 |
|
Messages: n/a
Hébergeur: |
> Result - works like a charm: t1 gives "page 1", t2 gives "page 2"
> (in the browser window, of course). > No matter how many times and in what sequence I reload the pages. Repeating this test with a global variable $foo might be more revealing though, as it is unclear in which context @foo is evaluated. or p defined?(Foo) class Foo end |
|
|
|
#13 |
|
Messages: n/a
Hébergeur: |
On Nov 7, 8:35 pm, tho_mica_l <micat...@gmail.com> wrote:
> Repeating this test with a global variable $foo might be more > revealing though, as it is unclear in which context @foo is evaluated. Yep, you're right... |
|
|
|
#14 |
|
Messages: n/a
Hébergeur: |
On 07/11/2007, John Joyce <dangerwillrobinsondanger@gmail.com> wrote:
> > On Nov 7, 2007, at 4:19 AM, Alex Young wrote: > > > Ilan Berci wrote: > >> Please site an example where you found PHP easier than rails. > > mv index.php ~/public_html > > > > Sorry, but it's true. Deployment of PHP is trivial, deployment of > > Ruby isn't. That's one big reason why it's as popular as it is. > > > > > If by deployment of php, you mean using php in web development is > trivial, yes it's true. > If by deployment of php, you mean installing and configuring a php > interpreter is trivial, it is not true at all. It's quite a task. > All Apache modules can be a pain. However, PHP is already installed on many web hosting servers, The number of admins capable of installing PHP (or having a test install somewhere already) you see by just looking around in your IT department is usually non-zero, not the same for Ruby. There are also technical reasons for this. The mod_php has (after some years of development) "sound security" (no more security holes than the underlying POSIX). PHP has also a sound interpreter that you can reset to the initial state which allows isolation of different programs running in the apache workers, especially programs of different users. I guess once we get something like mod_ruby with similar level of functionality as mod_php we could see it installed on some freewebs (or cheapwebs at least) and people picking Ruby more often. Currently you need dedicated hardware or equivelent to run a Ruby site which is quite forbidding. Fixing this should be possible after 1.9. Thanks Michal |
|
|
|
#15 |
|
Messages: n/a
Hébergeur: |
On Nov 7, 8:35 pm, tho_mica_l <micat...@gmail.com> wrote:
> Repeating this test with a global variable $foo might be more > revealing though, as it is unclear in which context @foo is evaluated. > > or > > p defined?(Foo) > class Foo > end again, the latter form somehow does work ![]() defined.rb: #!/usr/local/bin/eruby <% p defined?(Foo) class Foo end p defined?(Foo) %> outputs << nil "constant" >> to the browser. So maybe just the global vars are shared? |
|
|
|
#16 |
|
Messages: n/a
Hébergeur: |
> ...PHP at the same time however, is a horrible
> language compared to ruby...PHP basically just cares > about getting the c**p outta *SQL and the "thing done", as ugly > as it may be... The Ruby community really needs to calm down about this language superiority thing. I'm new to Ruby, and I've been hanging out on this list for the past month or two. I'm not sure if you guys realize how many of your emails are anti-some-language or comparing Ruby's popularity to the others. It's really a turn-off. It's like an insecure woman looking in the mirror asking you if she looks OK. "Of course!," you say. "You're beautiful!" And then she asks you again and again... > I see .php pages all the time. (Almost) all the webshops use > them (yuck). Loads of blogs use php...Back to www.langpop.com for > querying top 3 "jobs wanted" > notes, PHP and SQL is among them (rank 3 / rank 1). > Yuck yuck yuck...PHP also wins on del.icio.us and in fact is only > beaten > by _JAVASCRIPT_ ! PHP code can also be beautiful if written correctly. Given the present circumstances, it sounds to me like you'd better go learn PHP. ; ) Michael |
|
|
|
#17 |
|
Messages: n/a
Hébergeur: |
Hello,
> The Ruby community really needs to calm down about this language > superiority thing. I'm new to Ruby, and I've been hanging out on this > list for the past month or two. I'm not sure if you guys realize how > many of your emails are anti-some-language or comparing Ruby's > popularity to the others. It's really a turn-off. It's like an insecure > woman looking in the mirror asking you if she looks OK. "Of course!," > you say. "You're beautiful!" And then she asks you again and again... Though I am trying to avoid (language) flame wars or anything related to them, I really have to disagree here. The above paragraph holds for the right-wing activists of the Rails party, but definitely not for Ruby in general. Most of the people here are coming from Java, C#, PHP and other languages, not necessarily leaving those behind. I have seen some serious Java (as well as other language, or language-agnostic) questions answered here without bashing or pointing out how X sucks. I tried to ignite a Java vs. Ruby flame war once (in the favor of Ruby of course), and I was kicked in the *ss very quickly by quite a few guys here (not necessarily Java fanatics, just normal coders pointing out that language flame wars are pointless and Ruby doesn't need to prove it's superiority over anything), then the thread died off. Of course that doesn't mean that emails like the one starting this thread do not come up from time to time, or that someone doesn't start some spontaneous bashing etc. However, in general, I find the Ruby mailing list the friendliest one if it comes to superiority proving (and a lot of other things, too). Individuals will always have different levels of 'insecure-womanhood' as you put it and a lot of other things as well, but in general, the Ruby community as a whole is definitely not like that. >> I see .php pages all the time. (Almost) all the webshops use >> them (yuck). Loads of blogs use php...Back to www.langpop.com for >> querying top 3 "jobs wanted" >> notes, PHP and SQL is among them (rank 3 / rank 1). >> Yuck yuck yuck...PHP also wins on del.icio.us and in fact is only beaten >> by _JAVASCRIPT_ ! > > PHP code can also be beautiful if written correctly. That's true for assembler code, too (though it definitely requires different glasses than those of an average Java/C++/PHP/Ruby programmer) and possibly for just any language out there. Proponents of Ruby are arguing that PHP is not OOP (a frequent reason for Perl guys to come over, too) which makes some advanced techniques quite hard to implement (like Ruby's metaprogramming capabilities etc.) and ... well I am starting to get into details so I am better switching off. </off> Of course as we all know, all these languages we are talking about here are Turing complete, which basically means you can accomplish the same stuff in any of them. However, I guess you won't argue that it's a different feeling to code in asm, C, Perl, PHP, Java or Ruby for that matter. Rubyists are the most productive and feel the best when programming in Ruby. This is a very subjective thing, therefore it doesn't make too much sense to attack each other or argue over it (it's like bashing Chivas Regal on the Jack Daniels mailing list). If in your case the sweet spot is PHP, all the power to you. After programming in ~10 languages, I am staying with Ruby for now, until something better comes along. > Given the present > circumstances, it sounds to me like you'd better go learn PHP. ; ) Be sure that most of the people here have tried PHP or something similar before (or even after) their encounter with Ruby, some are even mastering it and maybe even using it further. This is not an either/or situation: you can learn, use, heck, even like more languages at once. You can stay with PHP forever, and put yet another language in your toolbox. Peace, Peter ___ http://www.rubyrailways.com http://scrubyt.org |
|
|
|
#18 |
|
Messages: n/a
Hébergeur: |
Peter Szinek wrote:
> Hello, > >> The Ruby community really needs to calm down about this language >> superiority thing. I'm new to Ruby, and I've been hanging out on this >> list for the past month or two. I'm not sure if you guys realize how >> many of your emails are anti-some-language or comparing Ruby's >> popularity to the others. It's really a turn-off. It's like an >> insecure woman looking in the mirror asking you if she looks OK. "Of >> course!," you say. "You're beautiful!" And then she asks you again and >> again... > > Though I am trying to avoid (language) flame wars or anything related to > them, I really have to disagree here. The above paragraph holds for the > right-wing activists of the Rails party, but definitely not for Ruby in > general. Most of the people here are coming from Java, C#, PHP and other > languages, not necessarily leaving those behind. I have seen some > serious Java (as well as other language, or language-agnostic) questions > answered here without bashing or pointing out how X sucks. This list has a permathread of "python v. ruby", and for the most part people are simply told to try both and see what makes you most happy. That's not to say there aren't some people who prefer to attempt nasty smack-downs, but they are in the minority. You can't just count the number of ranting pro-ruby posts; you also have to see if they aren't all coming from the same 2 or 3 people. MINASWAN -- James Britt http://web2.0validator.com - We're the Dot in Web 2.0 http://www.rubyaz.org - Hacking in the Desert http://www.jamesbritt.com - Playing with Better Toys |
|
|
|
#19 |
|
Messages: n/a
Hébergeur: |
> Peter Szinek wrote:
>> Hello, >>> The Ruby community really needs to calm down about this language >>> superiority thing. I'm new to Ruby, and I've been hanging out on >>> this list for the past month or two. I'm not sure if you guys >>> realize how many of your emails are anti-some-language or >>> comparing Ruby's popularity to the others. It's really a turn- >>> off. It's like an insecure woman looking in the mirror asking you >>> if she looks OK. "Of course!," you say. "You're beautiful!" And >>> then she asks you again and again... >> Though I am trying to avoid (language) flame wars or anything >> related to them, I really have to disagree here. The above >> paragraph holds for the right-wing activists of the Rails party, >> but definitely not for Ruby in general. Most of the people here >> are coming from Java, C#, PHP and other languages, not necessarily >> leaving those behind. I have seen some serious Java (as well as >> other language, or language-agnostic) questions answered here >> without bashing or pointing out how X sucks. > > > This list has a permathread of "python v. ruby", and for the most > part people are simply told to try both and see what makes you > most happy. > > That's not to say there aren't some people who prefer to attempt > nasty smack-downs, but they are in the minority. > > You can't just count the number of ranting pro-ruby posts; you also > have to see if they aren't all coming from the same 2 or 3 people. You guys are absolutely right. My apologies for grouping everyone on the list into one group. That was stupid of me. Michael |
|
|
|
#20 |
|
Messages: n/a
Hébergeur: |
> The Ruby community really needs to calm down about this language
> superiority thing. Well, one often cited credo around here is that you should learn a new language every x month, and I think that ruby profits a lot from this attitude. Innovation often means wandering through unknown (as in "where no man has been before" or "foreign" territory and comingback with new ideas. |
|
|
|
#21 |
|
Messages: n/a
Hébergeur: |
On 08/11/2007, tho_mica_l <micathom@gmail.com> wrote:
> > The Ruby community really needs to calm down about this language > > superiority thing. > > Well, one often cited credo around here is that you should learn a new > language every x month, and I think that ruby profits a lot from this > attitude. Innovation often means wandering through unknown (as in > "where no man has been before" or "foreign" territory and coming> back with new ideas. Heh, but don't start with a natural language. x would be at least in the range of tens then ;-) |
|
|
|
#22 |
|
Messages: n/a
Hébergeur: |
Sorry to respond to such an old thread, but I didn't see this
addressed at all. On Nov 6, 2007, at 12:25 PM, bwv549 wrote: > PHP isn't as consistent or beautiful as ruby, but it hardly matters > when you have online documentation like this: > > http://www.php.net/manual/en/ Does this mean you don't know about http://ruby-doc.org/ or don't consider it to be "excellent, up-to-date, comprehensive online documentation"? As someone who started using Ruby when the only documentation was in Japanese, I find complaints about Ruby's current supposed lack of documentation (online or otherwise) to be surprising. The online docs aren't perfect, of course, but that's true of any documentation for any project which is still in active development. I personally find that the online docs cover 90% of what I need, and between referencing the source (which is where beauty very much DOES count) and the fulness of the community, the other 10% is more than covered. > We (the ruby community) really should have excellent, up-to-date, > comprehensive online documentation. Considering its online > documentation, it is amazing that ruby is as popular as it is. What about Ruby's online documentation do you find lacking? > Are there any projects out there attempting to create good, online > documentation for ruby? Yes, (since sometime in 2002): http://ruby-doc.org/stdlib/status.html is a good place to start if you're wanting to contribute your effort to the existing docs. And you wouldn't have voiced your criticism of the current docs if you weren't, right? ![]() -- Michael Granger <ged@FaerieMUD.org> Rubymage, Architect, Believer The FaerieMUD Consortium <http://www.FaerieMUD.org/> |
|
|
|
#23 |
|
Messages: n/a
Hébergeur: |
On 17-Dec-07, at 3:11 PM, Michael Granger wrote:
>> http://www.php.net/manual/en/ > > Does this mean you don't know about > > http://ruby-doc.org/ > or don't consider it to be "excellent, up-to-date, comprehensive > online documentation"? As someone who started using Ruby when the > only documentation was in Japanese, I find complaints about Ruby's > current supposed lack of documentation (online or otherwise) to be > surprising To be fair, much as I love Ruby the PHP world does stand head and shoulders above in terms of the quality and usability of the documentation (that AND clause is very important). The Ruby docs are likely just as _complete_ in a technical sense, but the PHP docs are so much easier to use and search than the Ruby docs are. THe PHP doc's ability to have user-contributed examples at the bottom of them is a fantastic resource, one I've taken advantage of more times than I can count. That you can search the docs from any page in the docs is also pretty nice (really, a basic requirement for online docs, in my opinion). On the Rails side of things Alex Gorbatchev has done a pretty nice job with Noobkit (http://www.noobkit.com/), again a resource I use quite frequently. That it also contains the Ruby docs is a huge boon but there's still much room for improvement. I guess if I could have one wish for ruby-doc.org it would be to allow user-contributed comments and examples ala PHP.net. There's so much useful information and examples in this mailing list and on the web that having them centralized and context-sensitive per the relevant doc page would be awesome. (My other wish would be to get rid of that three-pane top-frame approach and replace it with a comprehensive search field and decent index). |
|
|
|
#24 |
|
Messages: n/a
Hébergeur: |
On 18/12/2007, Chris Cummer <chris@postal-code.com> wrote:
> On 17-Dec-07, at 3:11 PM, Michael Granger wrote: > > >> http://www.php.net/manual/en/ > > > > Does this mean you don't know about > > > > http://ruby-doc.org/ > > > or don't consider it to be "excellent, up-to-date, comprehensive > > online documentation"? As someone who started using Ruby when the > > only documentation was in Japanese, I find complaints about Ruby's > > current supposed lack of documentation (online or otherwise) to be > > surprising > > > > To be fair, much as I love Ruby the PHP world does stand head and > shoulders above in terms of the quality and usability of the > documentation (that AND clause is very important). The Ruby docs are > likely just as _complete_ in a technical sense, but the PHP docs are > so much easier to use and search than the Ruby docs are. No, php docs cover like 99.9% of the core functionality + standard libraries. That cannot be said for Ruby. Some of the standard libraries do not have any documentation at all, some of the details of core functionality are only explained in the pickaxe which is not integrated with rdoc. However, the task of documenting PHP is much easier than that of documenting Ruby. PHP only covers web, db, and supporting system tasks. The situation for something like php-gtk might be quite different. I do not know of any TUI library for PHP,and it's certainly not in the core. Also there is nothing like yaml, marshal,singleton,delegator,... iirc they only reference the regexp library docs instead of explaining the two regex flavours they use in detail. That's the joy of relying of somebody else's stuff ;-) Note that if it weren't for user contributed examples some of the core function details would be far from clear. So the user contributed comments are very valuable part of PHP documentation. > > THe PHP doc's ability to have user-contributed examples at the bottom > of them is a fantastic resource, one I've taken advantage of more > times than I can count. That you can search the docs from any page in > the docs is also pretty nice (really, a basic requirement for online > docs, in my opinion). You can more or less do that for rdoc because of the frames. Very clunky, though. > > On the Rails side of things Alex Gorbatchev has done a pretty nice job > with Noobkit (http://www.noobkit.com/), again a resource I use quite > frequently. That it also contains the Ruby docs is a huge boon but > there's still much room for improvement. Yes, and it would be only fair to compare PHP documentation with Rails documentation, the scope is about the same. > I guess if I could have one wish for ruby-doc.org it would be to allow > user-contributed comments and examples ala PHP.net. There's so much > useful information and examples in this mailing list and on the web > that having them centralized and context-sensitive per the relevant > doc page would be awesome. > > (My other wish would be to get rid of that three-pane top-frame > approach and replace it with a comprehensive search field and decent > index). Creating what PHP has would require replacing the static rdoc frames with dynamically generated scripted index-menu. It can be cached but the scripts have to be in place to generate the menu for new queries or when the docs get updated. It's not too hard but somebody has to write the scripts ;-) Tho comments would require even more complex site with database and whatnot. Thanks Michal |
|
|
|
#25 |
|
Messages: n/a
Hébergeur: |
Chris Cummer wrote:
> THe PHP doc's ability to have user-contributed examples at the bottom > of them is a fantastic resource, one I've taken advantage of more > times than I can count. That you can search the docs from any page in > the docs is also pretty nice (really, a basic requirement for online > docs, in my opinion). Why can't we get something added to the core docs where there is a hyper link or some kind of wiki that lets users add samples and explanations? I bet that would grow into some full fledged documentation in short order. Perhaps, when it is somewhat mature, someone could even turn it into a freebie download PDF. -- Posted via http://www.ruby-forum.com/. |