20

My company con not find any other developer than me.
I could not understand.
We use only up to date libraries in our projects.
Please note the comment private properties...

Comments
  • 8
    I don't know much about php but private variables that are public smells like rotten fish to me.
  • 8
    @NeatNerdPrime you are right and my head is full of rotten fish.

    In 2004 in php all properties and method where public: the were no alternatives than a comment.

    Now how in the hell would change this.
  • 4
    FPDF is long dead.

    Does TCPDF still exist? fond memories of insanity.
  • 8
    That date. Poor Oliver. He should have been drunk
  • 6
    php. 2004. comment for every line.
  • 2
    @horus definitely. My comment regarding insanity was meant regarding the insanity of PDF...

    E.g. calculating offsets by multiplying font sizes with strange values to position sth perfectly. XD

    TCPDF was nice. PDF itself ... Nope.
  • 3
    @retoor probably he was
  • 3
    @NeatNerdPrime These are probably library-private properties. PHP doesn't support visibility by module or library. So you have to declare them public and just don't use them outside the library.

    Obviously, making em protected or private and only allowing access by getters and setters would have been the cleaner solution. But all these properties where probably once declared using the var keyword. Maybe, someone just preemtively replaced all uses of "var" with "public" when 5.0 (temporarily) deprecated "var".

    Might very well be the case that there where refactorings planned for the library. But as it always happens with private FOSS projects: Life gets in the way and maintenance suffers...

    Today, DomPdf is the FOSS lib to use for PDF generation in PHP.
  • 1
    @Oktokolo aha, thanks for the enlightenment on this issue. I had no idea.
  • 0
    @mansur85 run, run away. My company is moving every application to Java™
  • 1
    @caiofior Java 8?

    Or Java 17?

    XD
  • 0
    @IntrusionCM originally Java 11 and now migrating to Java 17
Add Comment