haxxing my website

It was recently brought to my attention by Erin that my website photo gallery went BAAAARRRRRRRRRRR.

So, I donned my 1337 haxxing cap and debugged the situation. I had just upgraded xampp (my server package) for security purposes, and it turns out that the latest version of PHP has reference variable issues. So, how to overcome this until the devs sort their stuff out?

All I needed to do, was on line 649 of mg2_functions.php change

$name = substr($name, 0, -strlen($ext)) . "_medium." . end(explode('.',$name));

to

$name = substr($name, 0, -strlen($ext)) . "_medium" . $ext;

This in total took me about 17 minutes to work out. Sometimes I even impress myself ;)

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>