$isfile

From Scriptwiki
Jump to: navigation, search

Returns informations on whether or not a file exists.

$isfile($mircdir $+ mirc.ini) // returns $true (is a file)
$isfile($mircdir)             // returns $false (is a directory)

Examples

alias file_exists {
  if ($isfile($1)) { return file exists! } 
  else { return file doesn't exist }
}

See Also

  • $isdir Check if a directory exists.
  • $exists Check if a file OR directory exists.