You are here: Re: 10 Reasons Why PHP is Better than ASP « PHP Programming Language « IT news, forums, messages
Re: 10 Reasons Why PHP is Better than ASP

Posted by Gary L. Burnore on 01/18/08 16:34

On Fri, 18 Jan 2008 16:03:43 +0000, The Natural Philosopher <a@b.c>
wrote:

>Gary L. Burnore wrote:
>> On Fri, 18 Jan 2008 13:16:06 +0000, The Natural Philosopher <a@b.c>
>> wrote:
>>
>>> Toby A Inkster wrote:
>>>> Steve wrote:
>>>>
>>>>> can you switch, in code, mid-stream to from one language to another?
>>>> In PHP? Yes, kinda, if you install the right modules. But only if by "one
>>>> language" you mean "PHP" and "another" you mean "Perl or Python".
>>>>
>>>> An example of using Perl within PHP:
>>>>
>>>> <?php
>>>> // Use embedded Perl
>>>> $perl = new Perl();
>>>> // Import function "md5_hex" from package "Digest::MD5"
>>>> $perl->eval('use Digest::MD5 qw(md5_hex);');
>>>> // Now we can call the function as a normal PHP object method.
>>>> echo $perl->md5_hex('Hello');
>>>> // prints "8b1a9953c4611296a827abf8c47804d7".
>>>> ?>
>>>>
>>>> It's slightly clunky in terms of syntax, but it's pretty cool and
>>>> occasionally useful if you want to be able to reuse a large piece of
>>>> already written Perl script in PHP. Perl functions can be made accessible
>>>> to PHP, and variables, arrays, hashes and objects passed back and forth
>>>> between the languages.
>>> <shudder>teh thought of having PERL anywhere on my machine</shudder>
>>
>> why?
>I had an employee, who was the only one I had to actually fire..set him
>a project, did it in perl, ran slower than almost anything else, and
>after 6 months still didn't work. Found out he had being writing a
>collaborative science fiction book online most of the time.
>
>Another guy picked it up, had it done in bash in 10 days, at about 1/4
>the length, and ten times the comprehensibility, tho still a wee bit slow.
>
>So we looked at the worst bits and did them in C.
>
>I suppose that it was that instance that cemented in my mind the firm
>conviction that anyone who thinks PERL is great, is probably a total
>wanker, and that includes the guy who wrote it. ;-)
>
>Sadly it does exist on my system because some bloody class library
>installation script was written in it.

It's not slow on a decent system and, if used correctly, it's quite
good. If you changed your statement to "Anyone who thinks EVERYTHING
should be done in Perl is a total wanker", you'd be right on the
money.

--
gburnore at DataBasix dot Com
---------------------------------------------------------------------------
How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore | ÝÛ³ºÝ³Þ³ºÝ³³Ýۺݳ޳ºÝ³Ý³Þ³ºÝ³ÝÝÛ³
| ÝÛ³ºÝ³Þ³ºÝ³³Ýۺݳ޳ºÝ³Ý³Þ³ºÝ³ÝÝÛ³
Official .sig, Accept no substitutes. | ÝÛ³ºÝ³Þ³ºÝ³³Ýۺݳ޳ºÝ³Ý³Þ³ºÝ³ÝÝÛ³
| ÝÛ 0 1 7 2 3 / Ý³Þ 3 7 4 9 3 0 Û³
Black Helicopter Repair Services, Ltd.| Official Proof of Purchase
===========================================================================

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация