yne / gotube

YouTube player for the PlayStation Portable
0 stars 1 forks source link

help me please to make one script))) #83

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Hey, I am sorry for too frequent new issues.
Can you look at my script and say, what is wrong, please =D
============================================================
there is the url of video, i get it with mozila firefox

http://bombaster9.mail.ru/mail/baljunov/_myvideo/v-214.flv?k=379f4c47319cf24a&vi
deo15
============================================================
var Mail = new Object();
Mail.rev        = 6;
Mail.SearchDesc = "hello world"
Mail.Name       = "Mail";
Mail.Search     = function (keyword, page){
 var result = new Object();
 result.bypage    = 18;//static
 result.start     = (page-1)*result.bypage+1;
 c=GetContents('http://video.mail.ru/cgi-bin/photo/lvsearch?page='+page+'&q='+escape(keyword));
 result.total     = -1;
 result.VideoInfo = new Array();
 while(p=c.indexOf('<h1 class="v-head">Видео от пользователей</h1>',p)+1){
  video = new Object();
  video.id            = ext('_myvideo/p-','.')//number... 214
  video.attr          = 3;
  video.Title         = ext('alt="','"');
  video.ThumbnailURL  = ext('<img src="');
  video.URL       = 'Mail.play("'+ video.id +'")';
  result.VideoInfo.push(video);
 }
 result.end       = result.start-1+result.VideoInfo.length;
 return result;
}
Mail.play = function(id){
        PSPTube.log(url);
        var auth = ext('    <a href="','"');//http://video.mail.ru/mail/baljunov/_myvideo/214.html
        c=GetContents(auth);p=0;
        var id = ext("var EventID = '","'");//214
        var user =ext("[url=http://video.mail.ru/mail/","/");//baljunov

        var url = "http://bombaster9.mail.ru/mail/"+user+"_myvideo/v-"+id+".flv?k="+  (i don’t know how to write the number 379f4c47319cf24a) +
        var video = GetContents(url);
        return video;
}
SiteList.push(Mail);

Original issue reported on code.google.com by ilkul...@gmail.com on 17 Dec 2011 at 6:43

GoogleCodeExporter commented 9 years ago
next time, be more accurate with your error
-> you should just use '<h1 class="v-head">'
-> the play function is definitely wrong :
    the ext() function must be called AFTER the GetContent
    (use the whole href url as id if you need)
    even if it work 1 time , it will fail on the 2nd video selecting (because c will be overwrited)

i stuck (like you) on the k= attribute >_< i'm pretty sure it's generated on 
user side using time or someting like that ...

you should try to play the video from a embedded player (like 
http://www.youtube.com/embed/lqBhgEQ4LT0) so you'll be able to understand what 
file are really needed for the video (and not the page interface)

btw good job ;)

Original comment by biscotte...@gmail.com on 17 Dec 2011 at 7:28

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
don’t know what to say) i will try!!!
thanks)))

Original comment by ilkul...@gmail.com on 18 Dec 2011 at 3:14