﻿function google_ad_request_done(google_ads) {
    if (google_ads.length == 0) {
        return;
    }

    if (google_ads[0].type == "flash") {
        document.write('<a target="_blank" href="' + google_info.feedback_url + '">google reklamları</a><br />' +
            '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"' +
            ' codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"' +
            ' width="' + google_ad.image_width +
            '" height="' + google_ad.image_height + '">' +
            '<param name="movie" value="' + google_ad.image_url + '">' +
            '<param name="quality" value="high">' +
            '<param name="AllowScriptAccess" value="never">' +
            '<embed src="' + google_ad.image_url +
            '" width="' + google_ad.image_width +
            '" height="' + google_ad.image_height +
            '" type="application/x-shockwave-flash"' +
            ' AllowScriptAccess="never" ' +
            ' pluginspage="http://www.macromedia.com/go/getflashplayer"></embed></object>');
        return;
    }

    if (google_ads[0].type == "image") {
        document.write('<a target="_blank" href="' + google_info.feedback_url + '">google reklamları</a><br />' +
            '<a href="' + google_ads[0].url +
            '" target="_blank" title="go to ' + google_ads[0].visible_url +
            '"><img border="0" src="' + google_ads[0].image_url +
            '"width="' + google_ads[0].image_width +
            '"height="' + google_ads[0].image_height + '" /></a>');
        return;
    }

    // text
    var i, st;
    if (google_ads[0].line1 == undefined) {
        return; // undefined
    }
    document.write('<a target="_blank" href="' + google_info.feedback_url + '">google reklamları</a><br />');
    if (google_ads.length == 1) {
        st = "font-size:large;text-align:center;line-height:20pt;overflow:hidden;width:120px;height:600px;";
        document.write('<div style="' + st + '"><br/><br/>');
    }
    for (i = 0; i < google_ads.length; ++i) {
        document.write('<a target="_blank" href="' + google_ads[i].url + '" ' +
            'onmouseout="window.status=\'\'" ' +
            'onmouseover="window.status=\'go to ' +
            google_ads[i].visible_url + '\'" ' +
            'style="text-decoration:none;' + st + '">' +
            '<b style="text-decoration:underline">' + google_ads[i].line1 + '</b></a><br/>' +
            '<div style="width:118px;overflow:hidden;font-size:8pt;' + st + '">' +
            google_ads[i].line2 + '<br />' +
            google_ads[i].line3 + '<br /></div>' +
            '<div class="copyright" style="width:118px;overflow:hidden">' +
            google_ads[i].visible_url + '</div><br/>');
    }
    if (st != "") {
        document.write("</div>");
    }
}

google_ad_client = 'pub-4524365845451007';
google_ad_channel = '12345678';
google_ad_output = 'js';
google_max_num_ads = '4';
google_ad_type = 'text'; // text_html
google_image_size = '120x600';
google_feedback = 'on';
google_language = 'tr';
