Core Function HasExtension
From Sputnik Wiki
HasExtension ( <path> )
Contents |
Description
Determines whether a path includes a file name extension.
Parameters
path
The path to search for an extension.
Return Value
Success: Returns 1.
Failure: Returns 0.
Remarks
None
Example
$FileA = 'C:\Test.exe'; $FileB = 'C:\Test'; println( $FileA . (HasExtension($FileA) ? " has extention" : " does not have extention") ); println( $FileB . (HasExtension($FileB) ? " has extention" : " does not have extention") );