Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Aug 2002
    Location
    New York, NY
    Posts
    73
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Getting File Size

    I am attempting to use the filesize() function, to determine the file size of certain videos. BUT, unfortunately, it's not working for some reason. Should I be using the full path when trying to get the file size? (i.e. www.abc.com/media/video/filename.wmv) Or should I be using something else?

    See below for the code:
    ========================================

    // I've checked the path to the videos, and these work
    $thevideofilehi = $baseurl."media/video/".$videos["videofile"]."_high.".$videos["videofiletype"];
    $thevideofilelo = $baseurl."media/video/".$videos["videofile"]."_low.".$videos["videofiletype"];

    $thevideosizehi = filesize($thevideofilehi);
    $thevideosizelo = filesize($thevideofilelo);

    echo "hi ".$thevideosizehi."<br>";
    echo "hi ".$thevideosizelo."<br>";
    ========================================

    Any ideas?

    Jabbamonkey

  • #2
    New Coder
    Join Date
    Jul 2002
    Location
    Regina, Saskatchewan, Canada
    Posts
    35
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You may have to use a path - but I'm not one to say!

    ie. /home/me/media/etc.
    Jared Brandt
    IKinsler

  • #3
    New Coder
    Join Date
    Aug 2002
    Location
    New York, NY
    Posts
    73
    Thanks
    0
    Thanked 0 Times in 0 Posts

    I know.

    That's what the $baseurl variable was for.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •