Merhaba.
Sunucumda bulunan video dosyalarını Youtube'a upload etmek istiyorum. Bunu yapan Rapidleech adında bir script var, fakat upload etmeye çalışırken aşağıdaki hatayı veriyor.
Dosyanın içeriği:
<table width=600 align=center>
</td></tr>
<tr><td align=center>
<div id=info width=100% align=center>Retrive upload ID</div>
<?php
//szal130309
##Youtube Login Details## Add your youtube logins here
$youtube_login = ''; // Your UTube email you use to login
$youtube_password = ''; //Your UTube password
///// DO NOT TOUCH /////
if (empty($youtube_login) || empty($youtube_password)) html_error('No UTube Login Details specified. You can add them in the youtube.com.php');
$post_url = 'http://www.youtube.com/login?next=/my_videos_upload';
$Url = parse_url($post_url);
//$page = geturl($Url["host"], $Url["port"] ? $Url["port"] : 80, $Url["path"].($Url["query"] ? "?".$Url["query"] : ""), 0, 0, 0, 0, $_GET["proxy"], $pauth);
//echo $page; exit;
//if (!preg_match("%ocation: (.+)\r\n%", $page, $new_geolocation)) html_error('Couldn\'t get new location url.');
//$Url = parse_url($new_geolocation[1]);
$post = array();
$post['current_form'] = 'loginForm';
$post['next'] = '/my_videos_upload';
$post['username'] = $youtube_login;
$post['password'] = $youtube_password;
$post['action_login'] = 'Log In';
$page = geturl($Url["host"], $Url["port"] ? $Url["port"] : 80, $Url["path"].($Url["query"] ? "?".$Url["query"] : ""), 0, 0, $post, 0, $_GET["proxy"],$pauth);
$cookie_use_hitbox = cut_str($page, 'Set-Cookie: use_hitbox=', ';');
$cookie_VISITOR_INFO1_LIVE = cut_str($page, 'Set-Cookie: VISITOR_INFO1_LIVE=', ';');
$cookie_PREF = cut_str($page, 'Set-Cookie: PREF=', ';');
$cookie_GEO = cut_str($page, 'Set-Cookie: GEO=', ';');
$cookie_LOGIN_INFO = cut_str($page, 'Set-Cookie: LOGIN_INFO=', ';');
$utube_login_cookie = 'VISITOR_INFO1_LIVE='.$cookie_VISITOR_INFO1_LIVE.'; PREF='.$cookie_PREF.'; GEO='.$cookie_GEO.'; use_hitbox='.$cookie_use_hitbox.'; LOGIN_INFO='.$cookie_LOGIN_INFO;
$url = 'http://'.$Url['host'].'/my_videos_upload';
$Url = parse_url($url);
$page = geturl($Url["host"], $Url["port"] ? $Url["port"] : 80, $Url["path"].($Url["query"] ? "?".$Url["query"] : ""), $url, $utube_login_cookie, 0, 0, $_GET["proxy"],$pauth);
is_page($page);
is_notpresent($page ,'Select a video to upload', 'Error retrieving upload form.');
$action_url = cut_str($page, '<form class="file-form" enctype="multipart/form-data" method="post" action="', '">');
if (empty($action_url)) html_error("Error retrive action url!");
$Url = parse_url($action_url);
$dkv_val = cut_str($page, 'Set-Cookie: dkv=', ';');
$dkv_cookie = 'dkv='.$dkv_val;
$upload_cookie = $utube_login_cookie.'; '.$dkv_cookie;
$addresser = cut_str($page, '<input type="hidden" name="addresser" value="', '">');
$upload_key = cut_str($page, '<input type="hidden" name="upload_key" value="', '">');
$session_token = cut_str($page, "\t\tgXSRF_token = '", "';");
$post = array();
$post['addresser'] = $addresser;
$post['upload_key'] = $upload_key;
$post['action_postvideo'] = '1';
$post['session_token'] = $session_token;
?>
<script>document.getElementById('info').style.display='none';</script>
<table width=600 align=center>
</td></tr>
<tr><td align=center>
<?php
$upfiles = upfile($Url["host"],$Url["port"] ? $Url["port"] : 80, $Url["path"].($Url["query"] ? "?".$Url["query"] : ""), $url, $upload_cookie, $post, $lfile, $lname, "field_uploadfile");
is_page($upfiles);
is_notpresent($upfiles, 'HTTP/1.0 303 See Other', 'Error - Upload Failed');
if (!preg_match("%ocation: .+&video_id=(.+)\r\n%", $upfiles, $video_id)) html_error('Couldn\'t find the video ID - perhaps the upload failed?');
$download_link = 'http://www.youtube.com/watch?v='.$video_id[1];
?>
<script>document.getElementById('progressblock').style.display='none';</script>Sorunun çözümü hakkında yardım edebilir misiniz?
Teşekkürler.