/* imploded by cf{implode_file} @ 18.04.2010 17:14:40 */


/* filename: default.js @ 10, hash: da39a3ee5e6b4b0d3255bfef95601890afd80709 */





/* filename: jquery.elastic.js @ 40, hash: ab95c1299f2b096f7a8e4a90a9aa2743130e0fde */



(function(jQuery){jQuery.fn.extend({elastic:function(){var mimics=['paddingTop','paddingRight','paddingBottom','paddingLeft','fontSize','lineHeight','fontFamily','width','fontWeight'];return this.each(function(){if(this.type!='textarea'){return false;}
var $textarea=jQuery(this),$twin=jQuery('<div />').css({'position':'absolute','display':'none'}),lineHeight=parseInt($textarea.css('line-height'),10)||parseInt($textarea.css('font-size'),'10'),minheight=parseInt($textarea.css('height'),10)||lineHeight*3,maxheight=parseInt($textarea.css('max-height'),10)||Number.MAX_VALUE,goalheight=0,i=0;$twin.appendTo($textarea.parent());var i=mimics.length;while(i--){$twin.css(mimics[i].toString(),$textarea.css(mimics[i].toString()));}
function setHeightAndOverflow(height,overflow){curratedHeight=Math.floor(parseInt(height,10));if($textarea.height()!=curratedHeight){$textarea.css({'height':curratedHeight+'px','overflow':overflow});}}
function update(){var textareaContent=$textarea.val().replace(/<|>/g,' ').replace(/\n/g,'<br />').replace(/&/g,"&amp;");var twinContent=$twin.html();if(textareaContent+'&nbsp;'!=twinContent){$twin.html(textareaContent+'&nbsp;');if(Math.abs($twin.height()+lineHeight-$textarea.height())>3){var goalheight=$twin.height()+lineHeight;if(goalheight>=maxheight){setHeightAndOverflow(maxheight,'auto');}else if(goalheight<=minheight){setHeightAndOverflow(minheight,'hidden');}else{setHeightAndOverflow(goalheight,'hidden');}}}}
$textarea.css({'overflow':'hidden'});$textarea.keyup(function(){update();});$textarea.live('input paste',function(e){setTimeout(update,250);});update();});}});})(jQuery);


/* filename: jquery.cf_box.js @ 50, hash: 18d334d0e9aa38acc77ea194ab0e5921e7bc8eb5 */



(function($){$.extend({cf_box_current_z_index:1000,cf_box_new_z_index:function(){return $.cf_box_current_z_index++;}});$.fn.extend({cf_box:function(options){var defaults={title:'...',top:'50px',width:'620px',modal:false,buttons:[]};var options=$.extend(defaults,options);var prepend_elements=[];$(this).each(function(){prepend_elements.push(this);});var obj={reposition:function(){var scroll_top=parseInt((document.documentElement.scrollTop)?document.documentElement.scrollTop:document.body.scrollTop,10)+'px';var client_height=parseInt((document.documentElement.clientHeight)?document.documentElement.clientHeight:document.body.clientHeight,10)+'px';this.box_modal.css({height:client_height});this.box_body.css({top:scroll_top});var max_height=parseInt(''+$(window).height(),10)-this.offset_top-120;if(this.optional_height&&max_height>this.optional_height){this.box_content.css({height:this.optional_height+'px'});return this.optional_height;}
if(max_height<20){max_height=20;}
this.box_content.css({height:max_height+'px'});return max_height;},title:function(t){if(typeof(t)=='undefined'){return this.box_title.html();}
return this.box_title.html(t);},empty:function(){this.box_content.empty();},show:function(on_show){this.box_container.hide();this.box_body.show();var t=this;this.box_container.fadeIn('fast',function(){t.box_button_inner.find('input:first').focus();try{on_show(t);}
catch(e){}});},hide:function(on_hide){var t=this;this.box_container.fadeOut('fast',function(){t.box_body.hide();try{on_hide(t);}
catch(e){}});},append:function(element){return this.box_content.append(element);},create:function(opt){this.modal=(opt.modal)?true:false;this.box_body=$(document.createElement('div')).addClass('cf_box').css({display:'none'}).appendTo('body');this.box_modal=$(document.createElement('div')).addClass('cf_box_modal').css({zIndex:$.cf_box_new_z_index(),height:'200px'}).appendTo(this.box_body);if(opt.modal){this.box_modal.fadeTo('fast',0.1);}
else{this.box_modal.hide();}
this.box_middle=$(document.createElement('div')).addClass('cf_box_middle').css({top:opt.top,width:opt.width,zIndex:$.cf_box_new_z_index()}).appendTo(this.box_body);this.box_container=$(document.createElement('div')).addClass('cf_box_cont').css({zIndex:$.cf_box_new_z_index()}).appendTo(this.box_middle);this.box_title=$(document.createElement('div')).addClass('cf_box_title').html(opt.title).appendTo(this.box_container);this.box_content=$(document.createElement('div')).addClass('cf_box_content').appendTo(this.box_container);if(prepend_elements.length){while(true){var element=prepend_elements.shift();if(!element){break;}
this.box_content.append(element);}}
if(typeof(opt.buttons)=='undefined'){this.box_content.css({'border-bottom-width':'1px'});}
else{this.box_button_outter=$(document.createElement('div')).addClass('cf_box_button_outter').appendTo(this.box_container);this.box_button_inner=$(document.createElement('div')).addClass('cf_box_button_inner').appendTo(this.box_button_outter);this.box_buttons={};for(var but in opt.buttons){this.box_buttons[but]=$(document.createElement('input')).attr({type:'button'}).val(but).addClass('cf_box_button').click(opt.buttons[but]).appendTo(this.box_button_inner);}}
this.optional_height=(typeof(opt.height)!='undefined')?parseInt(opt.height,10):false;this.offset_top=parseInt(opt.top,10);this.reposition();var t=this;$(window).resize(function(){t.reposition();});$(window).scroll(function(){t.reposition();});return true;}};obj.create(options);return obj;}});})(jQuery);


/* filename: main_menu.js @ 50, hash: 48d019bbaa8762b2eeae0fa99a62d06b8b7605e3 */



function contribute_open_close(){return function(){if(!contribute_window){var contribute_iframe=$(document.createElement('iframe')).attr({'scrolling':'auto','frameborder':'0','src':'/objava/'}).css({'border':'none','width':'100%','height':'580px'});contribute_window=$(document.createElement('div')).append(contribute_iframe).cf_box({title:$('div.contribute_container a').attr('title'),width:'822px',height:'580px',top:'20px',buttons:{'Prekliči':function(){contribute_window.hide(function(){contribute_window_visible=false;});}}});}
if(!contribute_window_visible){contribute_window.show();contribute_window_visible=true;}
return false;}}
function main_menu_mobile_site_mouse(over){return function(){$('div.mobile_site_container img').attr({'src':'/image/mobile_page'+((over)?'_over':'')+'.png'}).css({'width':'42px','height':'60px'});}}
function main_menu_mobile_site_open(){return function(){$.cf_mobile_box.url=mobile_url;$.cf_mobile_box.show();}}
var contribute_window=null;var contribute_window_visible=false;$(document).ready(function(){$('div.mobile_site_container a').mouseenter(main_menu_mobile_site_mouse(true)).mouseleave(main_menu_mobile_site_mouse(false)).click(main_menu_mobile_site_open());$(document.createElement('a')).attr({href:'#',title:$('div.contribute_container span').attr('title')}).html($('div.contribute_container span').html()).click(contribute_open_close()).appendTo($('div.contribute_container div.button').empty());});


/* filename: jquery.cf_box.js @ 50, hash: 18d334d0e9aa38acc77ea194ab0e5921e7bc8eb5 */



(function($){$.extend({cf_box_current_z_index:1000,cf_box_new_z_index:function(){return $.cf_box_current_z_index++;}});$.fn.extend({cf_box:function(options){var defaults={title:'...',top:'50px',width:'620px',modal:false,buttons:[]};var options=$.extend(defaults,options);var prepend_elements=[];$(this).each(function(){prepend_elements.push(this);});var obj={reposition:function(){var scroll_top=parseInt((document.documentElement.scrollTop)?document.documentElement.scrollTop:document.body.scrollTop,10)+'px';var client_height=parseInt((document.documentElement.clientHeight)?document.documentElement.clientHeight:document.body.clientHeight,10)+'px';this.box_modal.css({height:client_height});this.box_body.css({top:scroll_top});var max_height=parseInt(''+$(window).height(),10)-this.offset_top-120;if(this.optional_height&&max_height>this.optional_height){this.box_content.css({height:this.optional_height+'px'});return this.optional_height;}
if(max_height<20){max_height=20;}
this.box_content.css({height:max_height+'px'});return max_height;},title:function(t){if(typeof(t)=='undefined'){return this.box_title.html();}
return this.box_title.html(t);},empty:function(){this.box_content.empty();},show:function(on_show){this.box_container.hide();this.box_body.show();var t=this;this.box_container.fadeIn('fast',function(){t.box_button_inner.find('input:first').focus();try{on_show(t);}
catch(e){}});},hide:function(on_hide){var t=this;this.box_container.fadeOut('fast',function(){t.box_body.hide();try{on_hide(t);}
catch(e){}});},append:function(element){return this.box_content.append(element);},create:function(opt){this.modal=(opt.modal)?true:false;this.box_body=$(document.createElement('div')).addClass('cf_box').css({display:'none'}).appendTo('body');this.box_modal=$(document.createElement('div')).addClass('cf_box_modal').css({zIndex:$.cf_box_new_z_index(),height:'200px'}).appendTo(this.box_body);if(opt.modal){this.box_modal.fadeTo('fast',0.1);}
else{this.box_modal.hide();}
this.box_middle=$(document.createElement('div')).addClass('cf_box_middle').css({top:opt.top,width:opt.width,zIndex:$.cf_box_new_z_index()}).appendTo(this.box_body);this.box_container=$(document.createElement('div')).addClass('cf_box_cont').css({zIndex:$.cf_box_new_z_index()}).appendTo(this.box_middle);this.box_title=$(document.createElement('div')).addClass('cf_box_title').html(opt.title).appendTo(this.box_container);this.box_content=$(document.createElement('div')).addClass('cf_box_content').appendTo(this.box_container);if(prepend_elements.length){while(true){var element=prepend_elements.shift();if(!element){break;}
this.box_content.append(element);}}
if(typeof(opt.buttons)=='undefined'){this.box_content.css({'border-bottom-width':'1px'});}
else{this.box_button_outter=$(document.createElement('div')).addClass('cf_box_button_outter').appendTo(this.box_container);this.box_button_inner=$(document.createElement('div')).addClass('cf_box_button_inner').appendTo(this.box_button_outter);this.box_buttons={};for(var but in opt.buttons){this.box_buttons[but]=$(document.createElement('input')).attr({type:'button'}).val(but).addClass('cf_box_button').click(opt.buttons[but]).appendTo(this.box_button_inner);}}
this.optional_height=(typeof(opt.height)!='undefined')?parseInt(opt.height,10):false;this.offset_top=parseInt(opt.top,10);this.reposition();var t=this;$(window).resize(function(){t.reposition();});$(window).scroll(function(){t.reposition();});return true;}};obj.create(options);return obj;}});})(jQuery);


/* filename: jquery.cf_mobile_box.js @ 50, hash: b97b946a164248d113d45c5da8f19cab43dcec69 */



$.cf_mobile_box={url:'',box_body:null,box_middle:null,box_content:null,show:function(on_show){if(!this.box_body){this.create();}
this.box_content.hide();this.box_body.show();this.box_content.fadeIn('fast',function(){try{if($.browser.msie){$(this).pngFix();}
on_show();}
catch(e){}});},hide:function(on_hide){if(!this.box_body){return false;}
var bb=this.box_body;this.box_content.fadeOut('fast',function(){bb.hide();try{on_hide();}
catch(e){}});},create:function(){this.box_body=$(document.createElement('div')).addClass('cf_mobile_box').css({display:'none'}).appendTo('body');this.box_middle=$(document.createElement('div')).addClass('cf_mobile_box_middle').appendTo(this.box_body);this.box_content=$(document.createElement('div')).addClass('cf_mobile_box_content').appendTo(this.box_middle);var table=$(document.createElement('table')).attr({'cellPadding':0,'cellSpacing':0}).appendTo(this.box_content);var top_tr=$(document.createElement('tr')).appendTo(table);$(document.createElement('td')).attr({'colSpan':3}).addClass('top').append($(document.createElement('img')).attr({'src':'/image/cf_mobile_box_bg_top.png'}).css({'width':'337px','height':'103px'})).appendTo(top_tr);var center_tr=$(document.createElement('tr')).appendTo(table);$(document.createElement('td')).addClass('left').append($(document.createElement('img')).attr({'src':'/image/cf_mobile_box_bg_left.png'}).css({'width':'28px','height':'419px'})).appendTo(center_tr);var content_td=$(document.createElement('td')).addClass('content').appendTo(center_tr);this.iframe=$(document.createElement('iframe')).attr({'scrolling':'auto','frameborder':'0','src':this.url}).appendTo(content_td);$(document.createElement('td')).addClass('right').append($(document.createElement('img')).attr({'src':'/image/cf_mobile_box_bg_right.png'}).css({'width':'28px','height':'419px'})).appendTo(center_tr);var bottom_tr=$(document.createElement('tr')).appendTo(table);var button_img=$(document.createElement('img')).attr({'src':'/image/cf_mobile_box_button.png','alt':'close'}).css({'width':'60px','height':'60px'});var button_div=$(document.createElement('div')).addClass('bottom').append($(document.createElement('a')).attr({'href':'#','title':'Zapri'}).append(button_img).click(function(){$.cf_mobile_box.hide();return false;})).appendTo(bottom_tr);$(document.createElement('td')).attr({'colSpan':3}).addClass('bottom').append(button_div).append($(document.createElement('img')).attr({'src':'/image/cf_mobile_box_bg_bottom.png'}).css({'width':'337px','height':'106px','z-index':10})).appendTo(bottom_tr);}};


/* filename: jquery.cf_share.js @ 60, hash: fb21d9f264d77b2ed102bd5ab50349bf1bbc25fe */



var cf_share_channels=[{name:'facebook',title:'Facebook',get_url:function(opt){return'http://www.facebook.com/sharer.php?u='+opt.url_encoded+'&t='+opt.title_encoded;}},{name:'google',title:'Google',get_url:function(opt){return'http://www.google.com/bookmarks/mark?op=add&bkmk='+opt.url_encoded+'&title='+opt.title_encoded+'&annotation=';}},{name:'twitter',title:'Twitter',get_url:function(opt){return'http://twitter.com/home?status='+opt.url_encoded;}},{name:'gmail',title:'Gmail',get_url:function(opt){return'http://mail.google.com/mail/?view=cm&fs=1&to&su='+opt.title_encoded+'&body='+opt.url_encoded+'&ui=2&tf=1';}},{name:'yahoo',title:'Y!Mail',get_url:function(opt){return'http://compose.mail.yahoo.com/?To=&Subject='+opt.title_encoded+'&body='+opt.url_encoded;}},{name:'hotmail',title:'Hotmail',get_url:function(opt){return'http://www.hotmail.msn.com/secure/start?action=compose&to=&subject='+opt.title_encoded+'&body='+opt.url_encoded;}},{name:'myspace',title:'MySpace',get_url:function(opt){return'http://www.myspace.com/Modules/PostTo/Pages/?u='+opt.url_encoded+'&t='+opt.title_encoded;}},{name:'netlog',title:'NetLog',get_url:function(opt){return'http://www.netlog.com/go/manage/links/?view=save&origin=external&url='+opt.url_encoded+'&title='+opt.title_encoded+'&description=';}},{name:'linked_in',title:'LinkedIn',get_url:function(opt){return'http://www.linkedin.com/shareArticle?mini=true&url='+opt.url_encoded+'&title='+opt.title_encoded+'&ro=false&summary=&source=';}},{name:'bebo',title:'Bebo',get_url:function(opt){return'http://bebo.com/c/share?Url='+opt.url_encoded+'&Title='+opt.title_encoded;}},{name:'delicious',title:'Deliciuos',get_url:function(opt){return'http://del.icio.us/post?url='+opt.url_encoded+'&title='+opt.title_encoded+'&notes=';}},{name:'digg',title:'Digg',get_url:function(opt){return'http://digg.com/submit?url='+opt.url_encoded+'&title='+opt.title_encoded+'&bodytext=';}},{name:'reddit',title:'Reddit',get_url:function(opt){return'http://reddit.com/submit?url='+opt.url_encoded+'&title='+opt.title_encoded;}},{name:'stambleupon',title:'StumbleUpon',get_url:function(opt){return'http://www.stumbleupon.com/submit?url='+opt.url_encoded+'&title='+opt.title_encoded;}},{name:'blogger',title:'Blogger',get_url:function(opt){return'https://api.addthis.com/oexchange/0.8/facade?dest=blogger&url='+opt.url_encoded+'&title='+opt.title_encoded;}},{name:'live',title:'Live',get_url:function(opt){return'https://favorites.live.com/quickadd.aspx?marklet=1&mkt=en-us&url='+opt.url_encoded+'&title='+opt.title_encoded+'&top=1';}},{name:'wordpress',title:'WordPress',get_url:function(opt){return'https://api.addthis.com/oexchange/0.8/facade?dest=wordpress&url='+opt.url_encoded+'&title='+opt.title_encoded+'&html=';}},{name:'google_translate',title:'Google Translate',get_url:function(opt){return'http://translate.google.com/translate?hl=sl&u='+opt.url_encoded+'&sl=sl&tl=en';}}];function cf_share_click(opt){return function(){if(opt.allways_refresh_url){opt.url=window.location.href;if(typeof(this.obj)!='undefined'){delete(this.obj);}}
if(typeof(this.obj)=='undefined'){this.obj={};this.obj.content=$(document.createElement('div')).addClass('cf_share');var obj=this.obj;this.obj.cf_box=obj.content.cf_box({title:opt.title,width:'506px',height:'240px',buttons:{'Zapri':function(){obj.cf_box.hide();}}});$(document.createElement('div')).addClass('url').append(document.createTextNode(opt.url)).appendTo(this.obj.content);var list=$(document.createElement('ul')).addClass('channels').appendTo(this.obj.content);for(var ch in cf_share_channels){var item=$(document.createElement('li')).addClass('channel').addClass('ch_'+cf_share_channels[ch].name).appendTo(list);$(document.createElement('a')).addClass('channel_title').html(cf_share_channels[ch].title).attr({href:cf_share_channels[ch].get_url(opt),target:'_blank'}).appendTo(item);}
this.obj.content.append($(document.createElement('div')).css({clear:'left'}));}
this.obj.cf_box.show();return false;}}
(function($){$.fn.extend({cf_share:function(options){var defaults={'url':window.location.href,'title':document.title,'unbind':true};var opt=(typeof(options)=='undefined')?(defaults):($.extend(defaults,options));opt.url_encoded=encodeURIComponent(opt.url);opt.title_encoded=encodeURIComponent(opt.title);return this.each(function(){if(opt.unbind==true){$(this).unbind('click');}
$(this).click(cf_share_click(opt));});}});})(jQuery);


/* filename: cinema_iframe.js @ 90, hash: 436ddb00a54e6ad6f967c4f1d00bf23ba635f4a0 */



function cinema_show_all_comments(){if(!cfb){cfb=$('#cinema_all_comments').cf_box({title:cinema_title,width:'700px',buttons:{'Zapri':function(){cfb.hide();}}});}
$('#cinema_all_comments').empty();$(document.createElement('div')).addClass('cinema_comments_loading').html('Nalaganje komentarjev...').appendTo('#cinema_all_comments').append(document.createElement('br')).append(document.createElement('br')).append($(document.createElement('img')).attr({'src':'/image/iframe_loading.gif'}));cfb.show(function(){cinema_show_all_comments_refresh();});return true;}
function cinema_show_all_comments_refresh(){$.ajax({type:"POST",url:'/kino/',data:{'action':'get-all-comments','id_movie':id_movie},success:function(resp){try{var r=eval('('+resp+')');if(r.result){$('#cinema_all_comments').empty();if(r.comments.length){var ci=0;for(var c in r.comments){var comm=$(document.createElement('div')).addClass('comment_box').addClass('comment_'+r.comments[c].account_type).addClass('comment_box_zebra_'+ci).appendTo('#cinema_all_comments');var text=$(document.createElement('p')).addClass('text').appendTo(comm);$(document.createElement('span')).addClass('name').html(r.comments[c].name_lastname+' ').appendTo(text);if(r.cf_site!==r.comments[c].site){$(document.createElement('span')).addClass('site').html(r.comments[c].site_title+' ').appendTo(text);}
$(document.createTextNode(r.comments[c].value)).appendTo(text);var time=$(document.createElement('div')).addClass('time').appendTo(comm);if(r.comments[c].from_mobile){time.append($(document.createElement('img')).attr({'src':'/image/mobile.gif','title':'iz mobilne strani'}));}
time.append(document.createTextNode(((r.comments[c].from_mobile)?' ':'')+r.comments[c].insert_time_pretty));if(r.comments[c].id_user==r.id_user||r.user_class=='admin'){time.html(time.html()+' | ');$(document.createElement('a')).attr({href:'#'}).html('Brisanje').click(cinema_delete_comment(r.comments[c].id,true)).appendTo(time);}
ci=1-ci;}}
else{$(document.createElement('div')).css({'padding':'8px','text-align':'center'}).html('ni komentarjev...').appendTo('#cinema_all_comments');}
if(r.user_loged){var cont=$(document.createElement('div')).addClass('comment_box').addClass('comment_add_box').appendTo('#cinema_all_comments');$(document.createElement('div')).addClass('input').append($(document.createElement('input')).attr({'type':'text','value':'Napiši komentar...'})).appendTo(cont);var ta=$(document.createElement('div')).addClass('textarea').appendTo(cont);if($('#cinema_comment_text_box').length){$('#cinema_comment_text_box').val('').appendTo(ta);}
else{$(document.createElement('textarea')).attr({'id':'cinema_comment_text_box'}).appendTo(ta);}
$(document.createElement('div')).addClass('button').append($(document.createElement('input')).attr({'type':'button','value':'Komentiraj'})).click(cinema_comment_post(true)).appendTo(ta);comment_add_box_set(cont);}
else{$(document.createElement('div')).addClass('comment_box').html('V kolikor želite komentirati film, se morate ').append($(document.createElement('a')).attr({'href':'/prijava/?preusmeritev='+cinema_login_redirect}).html('prijaviti ali registrirati')).append(document.createTextNode('.')).appendTo('#cinema_all_comments');}
return true;}}
catch(e){}
alert('Pri osveževanju komentarjev je prišlo do napake!');},error:function(){}});}
function cinema_iframe_onresize(){var w=$('div.head_center').width();var w_half=Math.round((w-((w>1200)?40:20))/2);if(w_half>200){$('div.cinema_description').css({'float':'left'}).width(w_half);$('div.cinema_comments').css({'float':'right'}).width(w_half);}
else{$('div.cinema_description').css({'float':'none'}).width('auto');$('div.cinema_comments').css({'float':'none'}).width('auto');}
cinema_iframe_content_onresize();}
function cinema_iframe_content_onresize(){try{$('#iframe_content iframe').css({'height':(($(window).height())-($('div.iframe_background_line').height())-($('div.iframe_head').height())-8)+'px'});}
catch(e){}}
function cinema_like(){if(posting_like){return false;}
posting_like=true;$.ajax({type:"POST",url:'/kino/',data:{'action':'set-like','id_movie':id_movie,'status':1-current_user_like},success:function(resp){try{var r=eval('('+resp+')');if(r.result){current_user_like=(r.cinema.current_user_like)?1:0;$('#cinema_like').empty();if(r.cinema.like_count){if(r.cinema.current_user_like&&r.cinema.like_count==1){$('#cinema_like').html('Tebi je všeč. ');$(document.createElement('a')).attr({href:'#'}).html('Ni mi všeč').click(function(){return cinema_like()}).appendTo('#cinema_like');}
else if(r.cinema.current_user_like){$('#cinema_like').html('Tebi in '+(r.cinema.like_count-1)+' osebam je všeč. ');$(document.createElement('a')).attr({href:'#'}).html('Ni mi všeč').click(function(){return cinema_like()}).appendTo('#cinema_like');}
else{$('#cinema_like').html(r.cinema.like_count+' osebam je všeč. ');$(document.createElement('a')).attr({href:'#'}).html('Všeč mi je').click(function(){return cinema_like()}).appendTo('#cinema_like');}}
else{$(document.createElement('a')).attr({href:'#'}).html('Všeč mi je').click(function(){return cinema_like()}).appendTo('#cinema_like');}
posting_like=false;return true;}}
catch(e){}
posting_like=false;},error:function(){posting_like=false;}});return false;}
function cinema_comment_post(from_all_comments){return function(){return cinema_comment_post_action(from_all_comments);}}
function cinema_comment_post_action(from_all_comments){if(posting_comment){return false;}
var text=jQuery.trim($('#cinema_comment_text'+((from_all_comments)?'_box':'')).val());if(!text.length){alert('Prosimo vpišite vaš komentar!');return false;}
posting_comment=true;$.ajax({type:"POST",url:'/kino/',data:{'action':'add-comment','id_movie':id_movie,'text':text},success:function(resp){posting_comment=false;try{var r=eval('('+resp+')');if(r.result){$('#cinema_comment_text'+((from_all_comments)?'_box':'')).val('').blur();if(from_all_comments){cinema_show_all_comments_refresh();}
cinema_refresh_last_comments();return true;}}
catch(e){}
alert('Pri shranjevanju komentarja je prišlo do napake!');},error:function(){posting_comment=false;}});return false;}
function cinema_refresh_last_comments(){$('#cinema_last_comments div.comment_box').each(function(){$(this).fadeOut('fast');});$.ajax({type:"POST",url:'/kino/',data:{'action':'get-last-comments','id_movie':id_movie},success:function(resp){try{var r=eval('('+resp+')');if(r.result){if(r.cinema.comment_count>3){$('#cinema_show_all').empty().html('Prikaži vseh ');$(document.createElement('a')).attr({href:'#'}).html(r.cinema.comment_count+' komentarjev').click(function(){return cinema_show_all_comments();}).appendTo('#cinema_show_all');$('#cinema_show_all').fadeIn('fast');}
else{$('#cinema_show_all').fadeOut('fast');}
for(var c in r.cinema.last_comments){var nd=$(document.createElement('div')).addClass('comment_box').addClass('comment_'+r.cinema.last_comments[c].account_type).css({display:'none'}).appendTo('#cinema_last_comments');var np=$(document.createElement('p')).addClass('text').appendTo(nd);$(document.createElement('span')).addClass('name').html(r.cinema.last_comments[c].name_lastname+' ').appendTo(np);if(r.cf_site!==r.cinema.last_comments[c].site){$(document.createElement('span')).addClass('site').html(r.cinema.last_comments[c].site_title+' ').appendTo(np);}
$(document.createTextNode(r.cinema.last_comments[c].value)).appendTo(np);var nt=$(document.createElement('div')).addClass('time').appendTo(nd);if(r.cinema.last_comments[c].from_mobile){nt.append($(document.createElement('img')).attr({'src':'/image/mobile.gif','title':'iz mobilne strani'}));}
nt.append(document.createTextNode(((r.cinema.last_comments[c].from_mobile)?' ':'')+r.cinema.last_comments[c].insert_time_pretty));if(r.cinema.last_comments[c].id_user==r.id_user||r.user_class=='admin'){nt.html(nt.html()+' | ');$(document.createElement('a')).attr({href:'#'}).html('Brisanje').click(cinema_delete_comment(r.cinema.last_comments[c].id,false)).appendTo(nt);}
nd.fadeIn('fast');}
return true;}}
catch(e){}},error:function(){}});}
function cinema_delete_comment(id,from_all_comments){return function(){return cinema_delete_comment_action(id,from_all_comments);}}
function cinema_delete_comment_action(id,from_all_comments){if(confirm('Ali ste prepričani da želite izbrisati komentar?')){posting_comment=true;$.ajax({type:"POST",url:'/kino/',data:{'action':'delete-comment','id_comment':id},success:function(resp){posting_comment=false;try{var r=eval('('+resp+')');if(r.result){if(from_all_comments){cinema_show_all_comments_refresh();}
cinema_refresh_last_comments();return true;}}
catch(e){}
alert('Pri brisanju komentarja je prišlo do napake!');},error:function(){posting_comment=false;}});}
return false;}
function cinema_open_iframe(){$('#iframe_content').empty();$(document.createElement('iframe')).attr({'scrolling':'auto','frameborder':'0','src':cinema_url}).css({'border':'none','margin-bottom':'1px','width':'100%'}).appendTo('#iframe_content');cinema_iframe_content_onresize();}


/* filename: comments.js @ 90, hash: 65f5e473c1534655fdf4454ee39022477d25eb19 */



function comment_add_box_set(cont){$(cont).find('div.input input').unbind('focus').focus(comment_add_box_set__input_focus(cont));$(cont).find('div.textarea textarea').elastic().unbind('blur').blur(comment_add_box_set__textarea_blur(cont));$(window).resize(comment_add_box_set__resize(cont));$(window).load(comment_add_box_set__resize(cont));comment_add_box_set__resize(cont)();}
function comment_add_box_set__input_focus(cont){return function(){$(cont).find('div.textarea').show();$(cont).find('div.input').hide();$(cont).find('div.textarea textarea').focus();}}
function comment_add_box_set__textarea_blur(cont){return function(){if(!$(this).val().length){$(cont).find('div.input').show();$(cont).find('div.textarea').hide();}}}
function comment_add_box_set__resize(cont){return function(){var w=$(cont).width()-8;$(cont).find('div.input input').css({'width':w+'px'});$(cont).find('div.textarea textarea').css({'width':w+'px'});}}
function comment_abbreviate(str,len){if(typeof(str)!='string'){return str;}
if(typeof(len)=='undefined'){len=200;}
else if(len<5){len=5;}
if(!(len<str.length)){return $(document.createTextNode(str));}
var text_node=$(document.createElement('span')).append(document.createTextNode(str.substr(0,len-3)+'...'));var show_all_button=$(document.createElement('span')).addClass('comment_abbreviate_show_all').click(function(){$(this).hide();text_node.fadeTo('fast',0.05,function(){$(this).empty().append(document.createTextNode(str)).fadeTo('fast',1);});}).html(' (preveri več)')
return $(document.createElement('span')).append(text_node).append(show_all_button);}


/* filename: jquery.pngFix.js @ 1000, hash: 4de410673503051a11659c852fd168045ffa5e80 */



eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('(s($){3.1s.1k=s(j){j=3.1a({12:\'1m.1j\'},j);8 k=(n.P=="r 10 Z"&&U(n.v)==4&&n.v.E("14 5.5")!=-1);8 l=(n.P=="r 10 Z"&&U(n.v)==4&&n.v.E("14 6.0")!=-1);o(3.17.16&&(k||l)){3(2).L("1r[m$=.M]").z(s(){3(2).7(\'q\',3(2).q());3(2).7(\'p\',3(2).p());8 a=\'\';8 b=\'\';8 c=(3(2).7(\'K\'))?\'K="\'+3(2).7(\'K\')+\'" \':\'\';8 d=(3(2).7(\'A\'))?\'A="\'+3(2).7(\'A\')+\'" \':\'\';8 e=(3(2).7(\'C\'))?\'C="\'+3(2).7(\'C\')+\'" \':\'\';8 f=(3(2).7(\'B\'))?\'B="\'+3(2).7(\'B\')+\'" \':\'\';8 g=(3(2).7(\'R\'))?\'1d:\'+3(2).7(\'R\')+\';\':\'\';8 h=(3(2).1c().7(\'1b\'))?\'19:18;\':\'\';o(2.9.y){a+=\'y:\'+2.9.y+\';\';2.9.y=\'\'}o(2.9.t){a+=\'t:\'+2.9.t+\';\';2.9.t=\'\'}o(2.9.w){a+=\'w:\'+2.9.w+\';\';2.9.w=\'\'}8 i=(2.9.15);b+=\'<x \'+c+d+e+f;b+=\'9="13:11;1q-1p:1o-1n;O:W-V;N:1l;\'+g+h;b+=\'q:\'+3(2).q()+\'u;\'+\'p:\'+3(2).p()+\'u;\';b+=\'J:I:H.r.G\'+\'(m=\\\'\'+3(2).7(\'m\')+\'\\\', D=\\\'F\\\');\';b+=i+\'"></x>\';o(a!=\'\'){b=\'<x 9="13:11;O:W-V;\'+a+h+\'q:\'+3(2).q()+\'u;\'+\'p:\'+3(2).p()+\'u;\'+\'">\'+b+\'</x>\'}3(2).1i();3(2).1h(b)});3(2).L("*").z(s(){8 a=3(2).T(\'N-S\');o(a.E(".M")!=-1){8 b=a.X(\'1g("\')[1].X(\'")\')[0];3(2).T(\'N-S\',\'1f\');3(2).Q(0).Y.J="I:H.r.G(m=\'"+b+"\',D=\'F\')"}});3(2).L("1e[m$=.M]").z(s(){8 a=3(2).7(\'m\');3(2).Q(0).Y.J=\'I:H.r.G\'+\'(m=\\\'\'+a+\'\\\', D=\\\'F\\\');\';3(2).7(\'m\',j.12)})}1t 3}})(3);',62,92,'||this|jQuery||||attr|var|style|||||||||||||src|navigator|if|height|width|Microsoft|function|padding|px|appVersion|margin|span|border|each|class|alt|title|sizingMethod|indexOf|scale|AlphaImageLoader|DXImageTransform|progid|filter|id|find|png|background|display|appName|get|align|image|css|parseInt|block|inline|split|runtimeStyle|Explorer|Internet|relative|blankgif|position|MSIE|cssText|msie|browser|hand|cursor|extend|href|parent|float|input|none|url|after|hide|gif|pngFix|transparent|blank|line|pre|space|white|img|fn|return'.split('|'),0,{}))
