/ Published in: ActionScript 3
Efficiently returns the filename by a given URL
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
public static function getFilenameByURL( $url:String ) : String { return $url.slice( Math.max( $url.lastIndexOf('/'), $url.lastIndexOf('\\') ) + 1 ); }