Current Location: Home> Function Categories> filesize

filesize

Get file size
Name:filesize
Category:File system
Programming Language:php
One-line Description:Returns the file size.

Example

 <span class="token php language-php"><span class="token delimiter important"><?php</span>
<span class="token keyword">echo</span> <span class="token function">filesize</span> <span class="token punctuation">(</span> <span class="token string double-quoted-string">"test.txt"</span> <span class="token punctuation">)</span> <span class="token punctuation">;</span>
<span class="token delimiter important">?></span></span>

Output:

 20
Similar Functions
  • Returns the file path information pathinfo

    pathinfo

    Returnsthefilepathin
  • Modify all groups of symbolic links lchgrp

    lchgrp

    Modifyallgroupsofsym
  • Read a line from a file pointer fgets

    fgets

    Readalinefromafilepo
  • Obtain file permissions fileperms

    fileperms

    Obtainfilepermission
  • Change file owner chown

    chown

    Changefileowner
  • alias for fwrite fputs

    fputs

    aliasforfwrite
  • Set file access and modification time touch

    touch

    Setfileaccessandmodi
  • Get the inode modification time of the file filectime

    filectime

    Gettheinodemodificat
Popular Articles