On 2026-10-22 21:12, Anthony de Boer via Talk wrote:
On Oct 21, 2026, at 23:23, Lennart Sorensen via Talk <talk@lists.gtalug.org> wrote:
php was a lovely language to write code it, especially for web pages. The syntax was so obvious, it seemed you could just write what you thought it should be and you would almost always be right.
Of course it had so many helpful features that it was incredibly easy to shoot yourself in the foot and make your code have big security holes. It was definitely designed for ease of use first, not security first.
I would definitely not recommend using it and I certainly haven't used it in years.
PHP was advertised as being incredibly easy to program even for non-coders. Years ago Rasmus Lerdorf spoke at a TLUG meeting when he was introducing it, and someone pointed out you could do all the same things in Perl, to which Rasmus said that then you’d need to read a man page!
Unfortunately a language anyone can write in led to reams of really bad code, and the mere fact something is written in PHP has become a code smell.
I wouldn't recommend using perl either. I am fine with python.
There are certainly too many languages. At one point about 20 years ago I was juggling C, C++, shell, Perl, PHP, and JavaScript, often jumping back and forth within projects, and sometimes the lowercase-with-semicolons dialects started to blur. I still love C but ought to learn Rust and Python.
Anthony ------------------------------------
Alack and alas, I still like perl better than python though I code in each. I have some perl programs that I want to pass on to my son, who knows python but not perl. So I converted the perl to python. Here are the line counts and the character counts for each: wc -l taxcalc.* 1305 taxcalc.pl 2157 taxcalc.py ls -la taxcalc.* 64340 Sep 27 18:52 taxcalc.pl 77980 Sep 28 00:32 taxcalc.py time taxcalc.pl .... 1>/dev/null; real 0m0.070s time taxcalc.pl .... 1>/dev/null; real 0m0.073s The code implements the Federal/Ontario tax code, and I verify both programs output against the other, to the character, of output In truth, I don't find the python much easier to understand or code for, although I have to admit I am more proficient in perl than in python. In perl I do 'print "index $index \n"; in python I do `print(f"index {index}")` Which seems more straightforwards to you? -- Michael Galea