$(document).ready(function(){

$('input.show_responses').live('click', function()
{
    var id='';
    id= $(this).attr('name');
    $('.comm_response_'+id).slideToggle(500, function()
    {
        $('.content').attr('style', 'overflow: visible; height: auto;');
    });
    if( $(this).hasClass('open') ) 
    {
		$(this).css('background', ' url(/dizajn/toggle1.png) no-repeat 0 -18px');
		$(this).removeClass('open');
	} else 
	{
		$(this).css('background', ' url(/dizajn/toggle1.png) no-repeat 0 0');
		$(this).addClass('open');
	}
});

$('input.respond').live('click', function()
{
    var id= $(this).attr('name');
    var lang= $('#comm_lang').attr('value');
    var lang_name= $('#comm_lang').attr('name');
    Shadowbox.open({player:'iframe', content:'../../php/shadowbox_comments.php?lang='+lang+'&lang_name='+lang_name+'&parent='+id, height:600, width:600});
});
});

$('a.admin_responses').live('click', function(){
	var id= $(this).attr('name');
	Shadowbox.open({player:'iframe', content:'include/php/shadowbox_admin_comments.php?&parent='+id, height:600, width:800});
});
