If you configured the domain for PHP5, then it will work fine for PHP code run from your domain as CGI. It is just when running PHP5 from the shell that you will need to provide the full path.
If you wish to see what PHP version is active for a particular domain, create a file called (for example) test.php containing the following line;
<?php phpinfo(); ?>
Browsing to this file will show the PHP version in use for the domain, and lots of other 'stuff.
Save [color=#CC0000]$50[/color] on DreamHost plans using [color=#CC0000]PRICESLASH[/color] promo code (Click for DreamHost promo code details)