Logo KRISTOFFER BOHMANN  [BETA]
  • Forside
  • Om KB
  • Kompetencer
  • Referencer
Strings
addcslashes
addslashes
bin2hex
chop
chr
chunk_split
convert_cyr_string
convert_uudecode
convert_uuencode
count_chars
crc32
crypt
echo
explode
fprintf
get_html_translation_table
hebrev
hebrevc
htmlentities
htmlspecialchars
htmlspecialchars_decode
html_entity_decode
implode
join
lcfirst
levenshtein
localeconv
ltrim
md5
md5_file
metaphone
money_format
nl2br
nl_langinfo
number_format
ord
parse_str
print
printf
quoted_printable_decode
quoted_printable_encode
quotemeta
Replacement order gotcha
rtrim
setlocale
sha1
sha1_file
similar_text
soundex
sprintf
sscanf
strcasecmp
strchr
strcmp
strcoll
strcspn
stripcslashes
stripos
stripslashes
strip_tags
stristr
strlen
strnatcasecmp
strnatcmp
strncasecmp
strncmp
strpbrk
strpos
strrchr
strrev
strripos
strrpos
strspn
strstr
strtok
strtolower
strtoupper
strtr
str_getcsv
str_ireplace
str_pad
str_repeat
str_rot13
str_shuffle
str_split
str_word_count
substr
substr_compare
substr_count
substr_replace
trim
ucfirst
ucwords
vfprintf
vprintf
vsprintf
wordwrap
Home > PHP > Function > Strings > sha1_file()

sha1_file()

sha1_file - Calculate the sha1 hash of a file

Syntax

string sha1_file (string $filename, bool $raw_output)

Arguments

  • filename - The filename of the file to hash.
  • raw_output - When TRUE, returns the digest in raw binary format with a length of 20.

Description

Calculates the sha1 hash of the file specified by filename using the » US Secure Hash Algorithm 1, and returns that hash. The hash is a 40-character hexadecimal number.

Version

PHP 4.3.0, 5

Return value

Returns a string on success, FALSE otherwise.
Kristoffer Bohmann, Ved Bjerget 12, DK- 9530 Støvring, Telefon +45 29 79 39 19, E-mail: