Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Development Tools

hye can anybody explain how to use the codes here https://github.com/jeckman/YouTube-Downloader

"Second, you can directly target the getvideo.php script, passing in a videoID and preferred format, and you will get redirected to the file itself."

WHat does that mean "you can target" ?

1 Answer

By "target", I believe they are saying that you can go to the getvideo.php page in your browser with some php variables set in the URL to download the desired video.

They offer this URL as an example: http://example.com/yt/getvideo.mp4?videoid=GkvvH8pBoTg&format=ipad

The URL that you would use depends on your domain name and how your folder structure is organized. Also videoid would have a the value of the youtube video id you want.

It looks like there is also an option for formats that are included in the URL as a php variable called format. These are the options you can pass in as a value for format:

Potential formats:

  • best = just give me the largest file / best quality
  • free = give the largest version including WebM, lower priority to FLV
  • ipad = ignore WebM and FLV, look for best MP4 file