Results 1 to 3 of 3

Thread: Calling the root directory

  1. #1

    Calling the root directory

    Hello, I am storing files in a root directory on my web host to protect the files. I call them when users that login request the files.

    On a user page, people can upload videos and I use PHP and mySQL to store the file names and it uploads the file to the root directory. Then, when I select the results from the mySQL table, I use this code to play the video-

    PHP Code:
    $videorealname stripcslashes($videorealname);
    $videorealname urlencode($videorealname);
    $totalfilepath $filepath.$videorealname;

    <
    object classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95' width='320' height='290'>
              <
    param name='FileName' value='$videoname'>
              <
    param name='AutoStart' value='True'>
              <
    param name='ShowControls' value='True'>
              <
    param name='ShowStatusBar' value='False'>
              <
    param name='ShowDisplay' value='False'>
              <
    param name='AutoRewind' value='True'>
              <
    embed type='application/x-mplayer2'
    pluginspage='http://www.microsoft.com/Windows/Downloads/Contents/MediaPlayer/' src='$totalfilepath' width='320' height='290' autostart='True' filename='$videoname' showcontrols='True' showstatusbar='False' showdisplay='False' autorewind='True'></embed>
            </
    object
    I tested the player without using PHP and upload a movie file in the same directory as the file and then changed the source to the file name and it worked, so I know that the media object itself is working fine. Any ideas?

    Also, I have used this root address before when I stored images and then I read the files using PHP and it worked. Not sure if there is a difference if you don't use
    PHP Code:
    readfile 
    or not..

    Anything will help!

    THanks

  2. #2
    Anyone have any ideas?

  3. #3
    18
    posts
    chown -R us ./base
    Quote Originally Posted by dreamerp View Post
    Anyone have any ideas?
    can you tell us the starting values of

    $filepath and $videorealname ?

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012