how it is possible in Php grab youtube link

Discussion in 'PHP' started by ironmankho, Sep 16, 2010.

  1. #1
    first of look this code

    now i want simple one thing i say user just replace "youtube" with "downloadyoutube"(actually i will buy this type of domain)

    now domain look like

    now this above youtube URL pass it to my domain page ...it will proceed for downloading


    now my question is

    How it is possible to get this target ? because i have no idea user just replace domain name ... http://www.youtubedownload.com/watch?v=Ge41tbymZC8 but php page will understand target URL is and proceed further action .
     
    ironmankho, Sep 16, 2010 IP
  2. ironmankho

    ironmankho Active Member

    Messages:
    393
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    55
    #2
    No body have idea ?
     
    ironmankho, Sep 17, 2010 IP
  3. krsix

    krsix Peon

    Messages:
    435
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #3
    rewriterule for ^watch$ -> index.php?v=$1

    sanitize $_GET['v'].
     
    krsix, Sep 17, 2010 IP
  4. imperialDirectory

    imperialDirectory Peon

    Messages:
    395
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Link to get the SWF video: 'http://www.youtube.com/v/' . $_GET['v']
    (add whatever validation you need...)

    Not sure if that's what you look for
     
    imperialDirectory, Sep 17, 2010 IP
  5. danx10

    danx10 Peon

    Messages:
    1,179
    Likes Received:
    44
    Best Answers:
    2
    Trophy Points:
    0
    #5
    don't you mean? -> ^/watch\?=([a-zA-Z0-9]+)$ -> index.php?v=$1
     
    danx10, Sep 17, 2010 IP
  6. gapz101

    gapz101 Well-Known Member

    Messages:
    524
    Likes Received:
    8
    Best Answers:
    2
    Trophy Points:
    150
    #6
    you will have to grab flv/vid link from youtube using php
     
    gapz101, Sep 18, 2010 IP