originalFilename() public method

Lives in the _file_name attribute of the model.
public originalFilename ( ) : string
return string
示例#1
0
 /**
  * Returns the extension of the attached file, e.g 'jpg' for file.jpg.
  *
  * @param Attachment $attachment
  * @param string $styleName
  * @return string
  */
 protected function extension(Attachment $attachment, $styleName = '')
 {
     return pathinfo($attachment->originalFilename(), PATHINFO_EXTENSION);
 }