PHP is simple to learn and use, and given that you've chosen a PHP editor, I'd personally go with option 1 here. See the following, with emphasis on Language Reference and mySQL functions:
http://www.php.net/manual/en/
(yes, I like Perl, but that doesn't mean I use it 100% of the time)