• Restaldt@lemm.ee
      link
      fedilink
      English
      arrow-up
      21
      arrow-down
      2
      ·
      8 months ago

      PHP5 was basically the Adolf Hitler of programming languages

      You know how something can be so terrible it ruins something forever? Like the hitler stache

      • msage
        link
        fedilink
        arrow-up
        11
        ·
        8 months ago

        5.3 was a big leap for PHP. It became actually very good at that point.

        I learned it when it was on 4 and boy oh boy was that something.

        But nowadays, with 8, it works great, tooling is fantastic. I just kinda wish the documentation, which is absolutely top notch for 90% of the language, was this good for the rest 10%.

        I want to play around with Fibers, but I just don’t get the info I want to.

        pthreads were so out of date in docs it was shameful.

        But the language is good, typing is coming along nicely, and basically the only thing I want PHP to do is to call Postgres and encode the output to json. Works like a charm.

        • Restaldt@lemm.ee
          link
          fedilink
          English
          arrow-up
          4
          ·
          edit-2
          8 months ago

          Yeah i’ve heard good things about it recently. I’ve always liked how easy curl can be in php.

          Adding typing seems like it would fix most of the problems i did run into but

          Has PHP raised its standards on function naming? Or do you still have batshit situations like realEscapeString2() because the first 30 other functions for escaping strings are deprecated?

      • dezvous@lemmy.world
        link
        fedilink
        arrow-up
        6
        ·
        8 months ago

        Lol okay maybe that’s true :) but PHP is great nowadays and with frameworks like Symfony and Larvel it’s easier than ever to build applications

    • MyNamesNotRobert@lemmynsfw.com
      link
      fedilink
      arrow-up
      4
      arrow-down
      1
      ·
      edit-2
      8 months ago

      If you get even 1 thing wrong, the entire program stops working and you don’t get any information about it. Turns out those cryptic errors like “error: object reference not set to instance of an object at address 0x007e00” are kind of important information to have. Unless you specifically know where it’s crashing, finding the source of the problem is like finding a needle in a haystack. If it’s your own code it’s borderline manageable but you’ll regret every decision that led you up to that point. If it’s someone else’s code such as an old project from 9 years ago that doesn’t work anymore, absolutely forget about it.

      The only advantage of php is that it’s incredibly lightweight. I was running an Athlon XP home server on Gentoo as late as 2022 and still had php running despite only having the SSE1 instruction set and a cpu less powerful than whats probably on a modern led lightbulb.

      But ACKTCHUALLY I think django and python bottles can be run on even shittier computers than php can since they’re both python programs and python has been demonstrated to be runnable on a pentium 1. So there is no reason to use php.