title: Extract filename with extension from filepath string
body: <p>I am looking to get the filename from the end of a filepath string, say</p>
  <pre><code>$text = &quot;bob/hello/myfile.zip&quot;;
  </code></pre>
  <p>I want to be able to obtain the file name, which I guess would involve getting everything after the last slash as a substring. Can anyone help me with  how to do this is PHP? A simple function like:</p>
  <pre><code>$fileName = getFileName($text);
  </code></pre>