Arkadaşlar adsense kayıt olduk sitemi ekledim reklamı yerleştirin diyor rastgele bi yere koyduk kod işlerini pek bilmiyorum 1 haftadır duruyor değişen bişey yok uyarı geldi kodlrı uygulamanız lazım diye. reklamın sayfanın en altında olmasını istiyorum nereye koymam lazım kodu
<?php
include_once('curl.php');
if(isset($_REQUEST['videoid'])) {
$my_id = $_REQUEST['videoid'];
} else {
echo '<p>No video id passed in</p>';
exit;
}
if(isset($_REQUEST['type'])) {
$my_type = $_REQUEST['type'];
} else {
$my_type = 'redirect';
}
if(isset($_REQUEST['debug'])) {
$debug = TRUE;
} else {
$debug = FALSE;
}
if ($my_type == 'indir') {
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Youtube Downloader</title>
<meta name="keywords" content="youtube video indir,youtube video programsız indir, youtube video online indir, youtube mp3 indir, youtube mp3 programsız indir, youtube mp3 online indir" />
<link href="css/bootstrap.min.css" rel="stylesheet" media="screen">
<style type="text/css">
body {
padding-top: 40px;
padding-bottom: 40px;
background-color: #f5f5f5;
background-image: url(http://i.imgur.com/6DrRs59.jpg) ;
background-repeat: no-repeat;
background-attachment: scroll;
background-color: white;
background-position: center;
}
.download {
max-width: 300px;
opacity: 0.6;
padding: 19px 29px 29px;
margin: 0 auto 20px;
background-color: #fff;
border: 1px solid #e5e5e5;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
border-radius: 5px;
-webkit-box-shadow: 0 1px 2px rgba(0,0,0,.05);
-moz-box-shadow: 0 1px 2px rgba(0,0,0,.05);
box-shadow: 0 1px 2px rgba(0,0,0,.05);
}
.download .download-heading {
margin-bottom: 10px;
}
.mime, .itag {
width: 75px;
display: inline-block;
}
.itag {
width: 15px;
}
.userscript {
float: right;
margin-top: 5px
}
</style>
</head>
<body>
<div class="download">
<h1 class="download-heading">Arama Sonuclari</h1>
<?php
} // end of if for type=Download
/* First get the video info page for this video id */
$my_video_info = 'http://www.youtube.com/get_video_info?&video_id='. $my_id;
$my_video_info .= '&asv=3&eurl=https%3A%2F%2Fs-static.ak.facebook.com%2Fcommon%2Freferer_frame.php&el=embedded';
$my_video_info = curlGet($my_video_info);
/* TODO: Check return from curl for status code */
parse_str($my_video_info);
echo '<p><img src="'. $thumbnail_url .'" border="0" hspace="2" vspace="2"></p>';
$my_title = $title;
if(isset($url_encoded_fmt_stream_map)) {
/* Now get the url_encoded_fmt_stream_map, and explode on comma */
$my_formats_array = explode(',',$url_encoded_fmt_stream_map);
//if($debug) {
// echo '<pre>';
// print_r($my_formats_array);
// echo '</pre>';
//}
} else {
echo '<p>Girdiginiz ID Gecersizdir </p>';
echo '<p>Youtube idsi girdiginize emin olunuz</p>';
}
if (count($my_formats_array) == 0) {
echo '<p>Video formati bulunamadi.</p>';
exit;
}
/* create an array of available download formats */
$avail_formats[] = '';
$i = 0;
foreach($my_formats_array as $format) {
parse_str($format);
$avail_formats[$i]['itag'] = $itag;
$avail_formats[$i]['quality'] = $quality;
$type = explode(';',$type);
$avail_formats[$i]['type'] = $type[0];
$avail_formats[$i]['url'] = urldecode($url) . '&signature=' . $sig;
parse_str(urldecode($url));
$avail_formats[$i]['expires'] = date("G:i:s T", $expire);
$avail_formats[$i]['ipbits'] = $ipbits;
$avail_formats[$i]['ip'] = $ip;
$i++;
}
if ($debug) {
echo '<p>These links will expire at '. $avail_formats[0]['expires'] .'</p>';
echo '<p>The server was at IP address '. $avail_formats[0]['ip'] .' which is an '. $avail_formats[0]['ipbits'] .' bit IP address. ';
echo 'Note that when 8 bit IP addresses are used, the download links may fail.</p>';
}
if ($my_type == 'indir') {
echo '<ul>
Yuklenebilir bilesimler<br>
<small>Sag tiklayip farkli kaydet diyebilirsiniz.</small>
</ul>';
echo '<li>' .
'<span class="itag">-</span> '.
'<a href="mp3dl.php?id=' . $my_id . '" class="mime">audio/mpeg</a> ' .
'<small>(128 kbps / ' .
'<a href="mp3dl.php?id=' . $my_id . '" class="dl">download</a>' .
')</small></li>';
/* now that we have the array, print the options */
for ($i = 0; $i < count($avail_formats); $i++) {
echo '<li>' .
'<span class="itag">' . $avail_formats[$i]['itag'] . '</span> '.
'<a href="' . $avail_formats[$i]['url'] . '" class="mime">' . $avail_formats[$i]['type'] . '</a> ' .
'<small>(' . $avail_formats[$i]['quality'] . ' / ' .
'<a href="download.php?mime=' . $avail_formats[$i]['type'] .'&title='. urlencode($my_title) .'&token=' . base64_encode($avail_formats[$i]['url']) . '" class="dl">download</a>' .
')</small></li>';
}
echo '</ul>';
?>
</body>
</html>
<?php
} else {
$format = $_REQUEST['format'];
$target_formats = '';
switch ($format) {
case "best":
/* largest formats first */
$target_formats = array('38', '37', '46', '22', '45', '35', '44', '34', '18', '43', '6', '5', '17', '13');
break;
case "free":
/* Here we include WebM but prefer it over FLV */
$target_formats = array('38', '46', '37', '45', '22', '44', '35', '43', '34', '18', '6', '5', '17', '13');
break;
case "ipad":
/* here we leave out WebM video and FLV - looking for MP4 */
$target_formats = array('37','22','18','17');
break;
default:
/* If they passed in a number use it */
if (is_numeric($format)) {
$target_formats[] = $format;
} else {
$target_formats = array('38', '37', '46', '22', '45', '35', '44', '34', '18', '43', '6', '5', '17', '13');
}
break;
}
/* Now we need to find our best format in the list of available formats */
$best_format = '';
for ($i=0; $i < count($target_formats); $i++) {
for ($j=0; $j < count ($avail_formats); $j++) {
if($target_formats[$i] == $avail_formats[$j]['itag']) {
//echo '<p>Target format found, it is '. $avail_formats[$j]['itag'] .'</p>';
$best_format = $j;
break 2;
}
}
}
//echo '<p>Out of loop, best_format is '. $best_format .'</p>';
$redirect_url = $avail_formats[$best_format]['url'];
$content_type = $avail_formats[$best_format]['type'];
header("Location: $redirect_url");
} // end of else for type not being Download
?>
<center><script type="text/javascript" src="http://ro2.biz/ad_js.php?zone=226171&w=300&h=250"></script></center>