help - viewing avi files over the web

  • djbuzzby365
  • Newbie
  • Newbie
  • djbuzzby365
  • Posts: 6

Post 3+ Months Ago

Hi there

I have a client that's handed me this project which requires the need to view avi files over the web.

The client will fill in a form consisting of 5 fields. one of those fields is for uploading his .avi files. (place, post code, latitude, longitude, video)

The end user's page will have a different form consisting of 2 fields to narrow down their search: place, post code (its not set in stone that its going to be 2 fields. could be more). once they have filled that form out and hit submit a list should display the videos for that region. the end user then will click the video they want to view.
my question is how can i get the .avi video to play in the browser?

can i use something like this to show any video?

in the header i have this:
PHP Code: [ Select ]
<?php
if(!isset($_GET["vid"])) {
  die();
}
 
if(empty($_GET["vid"])) {
  die();
}
 
$video = $_GET["vid"];
$length = filesize($video);
header("Content-Type: $content");
header("Content-Length: $length");
readfile($video);
?>
 
  1. <?php
  2. if(!isset($_GET["vid"])) {
  3.   die();
  4. }
  5.  
  6. if(empty($_GET["vid"])) {
  7.   die();
  8. }
  9.  
  10. $video = $_GET["vid"];
  11. $length = filesize($video);
  12. header("Content-Type: $content");
  13. header("Content-Length: $length");
  14. readfile($video);
  15. ?>
  16.  


in the body i have this:
PHP Code: [ Select ]
<html>
<head></head>
 
<body>
<object classid="clsid:6BF52A52-394A-11D3-B153-00C04F79FAA6.">
<param name="src" value= <?php echo "\"video.php?vid={$_GET["vid"]}\""; ?>>
<param name="autoplay" value="true">
<param name="controller" value="true">
 
<embed src=<?php echo "\"video.php?vid={$_GET["vid"]}\""; ?>
autoplay="true" controller="true"
pluginspage="">
</embed>
 
</object>
</body>
</html>
 
  1. <html>
  2. <head></head>
  3.  
  4. <body>
  5. <object classid="clsid:6BF52A52-394A-11D3-B153-00C04F79FAA6.">
  6. <param name="src" value= <?php echo "\"video.php?vid={$_GET["vid"]}\""; ?>>
  7. <param name="autoplay" value="true">
  8. <param name="controller" value="true">
  9.  
  10. <embed src=<?php echo "\"video.php?vid={$_GET["vid"]}\""; ?>
  11. autoplay="true" controller="true"
  12. pluginspage="">
  13. </embed>
  14.  
  15. </object>
  16. </body>
  17. </html>
  18.  


will this work for whatever video is chosen?

will i need to specify that it is for .avi?

many thanks on your reply

DB.
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • Zealous
  • Guru
  • Guru
  • User avatar
  • Posts: 1244
  • Loc: Sydney

Post 3+ Months Ago

How did ya go with this? noticed it was posted 2 weeks ago?
  • Zealous
  • Guru
  • Guru
  • User avatar
  • Posts: 1244
  • Loc: Sydney

Post 3+ Months Ago

btw ever shown your client clip bucket?
  • djbuzzby365
  • Newbie
  • Newbie
  • djbuzzby365
  • Posts: 6

Post 3+ Months Ago

sorry, i have not had a chance to really get into this as busy with other clients. i will however be looking into this in the coming week. i was just wondering if i was on the right track with this. the code i posted earlier was researched. from what i understand of the project i need a form that the client will fill out which will submit the data to the database. then basically a search form with certain criteria that will result in displaying the relative video(s).

i am new to this so i just want to know if i have understood this properly

many thanks

Post Information

  • Total Posts in this topic: 4 posts
  • Users browsing this forum: No registered users and 64 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.