<?php $info = pathinfo('/usr/local/php/php.ini'); echo $info['dirname']; echo $info['basename']; echo $info['extension']; ?>