Then browse to /info.php
That'll have your PHP info. If you run php -v from the commandline, you'll get your CLI version of php, which isn't what's going to be serving your web requests.
It should print out the mysql server version in the welcome text. Mine, for example, is:
Server version: 5.0.45-log MySQL Community Server (GPL)