$(function(){

    $("#news").css({
        textAlign: "center",
        fontFamily: "tahoma",
        backgroundColor: "rgb(240,240,255)",
        marginRight: "30px",
        marginLeft: "30px"
    });
    window.setInterval('myf();', 100);
    
})

var ai = str.length - 3;
var si = str[ai].length + 1;
var w = 10;
function myf(){
    //alert("h");
    if (window.si <= window.str[ai].length) {
        tmp = str[ai].substr(0, si);
        ++si;
        if (si < window.str[ai].length) 
            tmp += "_";
        else 
            w = 0;
        $("#typeing").text(tmp);
    }
    else 
        if (w < 10) {
            w++;
        }
        else {
            si = 0;
            ai += 2;
            if (ai >= str.length - 1) 
                ai = 0;
            $("#typeing").attr("href", str[ai + 1]);
        }
    //	window.setTimeout('myf();',1000);
}


$(function(){
    $('#gold_holder').load('tala.php');
    $('#news_holder').load('news.php', function(){
        $('#news_holder a').attr('target', '_bank');
    });
    
    $("div#md_main div.list_image").mouseover(function(){
        $(this).css({
            backgroundColor: '#eef1ff'
        })
    })
    $("div#md_main div.list_image").mouseout(function(){
        $(this).css({
            backgroundColor: 'transparent'
        })
    })
    
    if ($.browser.msie == false) {
        var dh = $('#holder1 div').size() / 4;
        var h = parseInt($('#holder1 div').css('height')) + 4;
        $('#holder1').css('height', h * dh)
        $('#holder2').css('height', h * dh + 8)
    }
    else {
        var dh = $('#holder1 div').size() / 4;
        var h = parseInt($('#holder1 div').css('height'));
        $('#holder1').css({
            height: h * dh,
            padding: '1px',
            width: (198 * 4) + 'px'
        })
        $('#holder2').css('width', 198 * 4);
        
    }
})

function searchbox()
{
	$('#searchbox_holder').toggle('slow');
}

