使用php播放视频

i just written code for play videos like this $vid was the video file name where the videos are in www\videos folder. read the content in the folder using the

<video src='videos/$vid'> it is working 

same as i just try to play videos in some drive like g:\videos folder $path='G:\videos\'; $video is video file name in that folder

here i written code like this <video src='$path\$video'

please tell me any solution for this

thank u

Your problem is that G:\videos is not a valid html path. Instead do this.

PHP

$path = 'file:///G:\videos';
$vid = 'filename.mp4';

HTML

<video src='<?="$path\$vid"?>'>