﻿var dir = '/timas'
function DocumentReady() {
    var MenuLI = 0;
    var MenuColors = new Array('#ff2511', '#84bd2c', '#fb721a', '#899aff', '#c766ff', '#fb3f67');
    $('#menuElem li').click(function() { window.location = $(this).find('a').attr('href'); });
	/*
    var t1 =  $('#menuElem li:eq(0)');
    {
        if ($(t1).hasClass('TopMenuCMSListMenuLI')) {
            var OldColor = $(t1).css('backgroundColor');
            $(t1).hover(function() {$(t1).css({ 'backgroundColor': MenuColors[0] }); }, function() { $(t1).css({ 'backgroundColor': '#767561' }); });
        }
        MenuLI++;
    }


    var t2 = $('#menuElem li:eq(1)');
    {
        if ($(t2).hasClass('TopMenuCMSListMenuLI')) {
            var OldColor = $(t2).css('backgroundColor');
            $(t2).hover(function() {$(t2).css({ 'backgroundColor': MenuColors[1] }); }, function() { $(t2).css({ 'backgroundColor': '#767561' }); });
        }
        MenuLI++;
    }

    var t3 = $('#menuElem li:eq(2)');
    {
        if ($(t3).hasClass('TopMenuCMSListMenuLI')) {
            var OldColor = $(t3).css('backgroundColor');
            $(t3).hover(function() { $(t3).css({ 'backgroundColor': MenuColors[2] }); }, function() { $(t3).css({ 'backgroundColor': '#767561' }); });
        }
        MenuLI++;
    }

    var t4 = $('#menuElem li:eq(3)');
    {
        if ($(t4).hasClass('TopMenuCMSListMenuLI')) {
            var OldColor = $(t4).css('backgroundColor');
            $(t4).hover(function() { $(t4).css({ 'backgroundColor': MenuColors[3] }); }, function() { $(t4).css({ 'backgroundColor': '#767561' }); });
        }
        MenuLI++;
    }

    var t5 = $('#menuElem li:eq(4)');
    {
        if ($(t5).hasClass('TopMenuCMSListMenuLI')) {
            var OldColor = $(t5).css('backgroundColor');
            $(t5).hover(function() { $(t5).css({ 'backgroundColor': MenuColors[4] }); }, function() { $(t5).css({ 'backgroundColor': '#767561' }); });
        }
        MenuLI++;
    }

    var t6 = $('#menuElem li:eq(5)');
    {
        if ($(t6).hasClass('TopMenuCMSListMenuLI')) {
            var OldColor = $(t6).css('backgroundColor');
            $(t6).hover(function() { $(t6).css({ 'backgroundColor': MenuColors[5] }); }, function() { $(t6).css({ 'backgroundColor': '#767561' }); });
        }
        MenuLI++;
    }
    $('.LeftMenuCMSListMenuLinkHighlighted').css('color', $('.TopMenuCMSListMenuHighlightedLI').css('backgroundColor'));
	*/
	
    $('.lightbox').lightBox({
        imageLoading: '/timas/App_Themes/Custom/lightbox/lightbox-ico-loading.gif',
        imageBtnClose: '/timas/App_Themes/Custom/lightbox/lightbox-btn-close.gif',
        imageBlank: '/timas/App_Themes/Custom/lightbox/lightbox-blank.gif'
    });

    $('.SelectedPrev').text("Önceki");
    $('.UnselectedPrev').text("Önceki");

    $('.SelectedNext').text("Sonraki");
    $('.UnselectedNext').text("Sonraki");

    $('.SelectedPage, .UnselectedPage').css("margin-left", "8px");

    /* Search Box String */
    if (!$('.searchTextBox').val()) $('.searchTextBox').val('carpe diem içerisinde');
    $('.searchTextBox').focus(function() { if ($(this).val() == 'carpe diem içerisinde') $(this).val(''); });
    $('.searchTextBox').blur(function() { if ($(this).val() == '') $(this).val('carpe diem içerisinde'); });

    $('#KitapListRepeater .KitapDetay:eq(1),#KitapListRepeater .KitapDetay:eq(3)').after('<img src="' + dir + '/App_Themes/CarpeDiem/hor.gif" style="clear:both; margin-bottom:16px; margin-top:0px; height:1px; margin-left:15px;">');
    $('#DergiListRepeater .DergiThumbContainer:eq(1),#DergiListRepeater .DergiThumbContainer:eq(3)').after('<img src="' + dir + '/App_Themes/CarpeDiem/hor.gif" style="clear:both; margin-bottom:16px; margin-top:0px; height:1px; margin-left:15px;">');

    $('.CMSSearchDialogSearchForTextBox').attr("style", "width:109px; background-color:#f7f7f7; padding:4px; position:relative; margin-bottom:-4px; font-family:Tahoma, Arial, font-size:11px; color:#767561; border:none;");
}
