This short block of PHP code takes a SQL script and removes the “dash-dash” and “/**/” comments from it. Of course, many languages, including PHP itself, use the “/**/” comment style so this could apply to PHP scripts, as well. The line that removes the dash-dash style comments could easily...
December 2015
Having to sift through a large directory to get the latest file can be tedious. Surprisingly, I’ve needed this twice in the past month, so I figured I should post it. I hope this helps someone.