can u phix mah code:
i mean it removes duplicates automatically but god damn, imagine the rest of the 1800 lines of code in this file...
@zanderwar time for refactoring or at least some calesthenics?
the person who wrote this, didn't use any framework or anything just all raw mysqli_* queries, and he's created this massive PDF by referencing row fields by their integer key (0,1,2,3,4 etc) except the table has been modified massively, so some keys that the script references don't even exist anymore.
like, some comments at least please fam, respect your future developers
right now, i, nor them have nfi what
29 used to once represent
or write code that's self explanatory... good variable names, short functions...
Not just unclear, also a massive anti-pattern. This could easily be solved with a static array and a single selector, instead of 3 if statements