
(function(jQuery){var self=null;jQuery.fn.autogrow=function(o)
{return this.each(function(){new jQuery.autogrow(this,o);});};jQuery.autogrow=function(e,o)
{this.options=o||{};this.dummy=null;this.interval=null;this.line_height=this.options.lineHeight||parseInt(jQuery(e).css('line-height'));this.min_height=this.options.minHeight||parseInt(jQuery(e).css('min-height'));this.max_height=this.options.maxHeight||parseInt(jQuery(e).css('max-height'));;this.textarea=jQuery(e);if(this.line_height==NaN)
this.line_height=0;this.init();};jQuery.autogrow.fn=jQuery.autogrow.prototype={autogrow:'1.2.2'};jQuery.autogrow.fn.extend=jQuery.autogrow.extend=jQuery.extend;jQuery.autogrow.fn.extend({init:function(){var self=this;this.textarea.css({overflow:'hidden',display:'block'});this.textarea.bind('focus',function(){self.startExpand();}).bind('blur',function(){self.stopExpand();});this.checkExpand();},startExpand:function(){var self=this;this.interval=window.setInterval(function(){self.checkExpand();},400);},stopExpand:function(){clearInterval(this.interval);},checkExpand:function(){if(this.dummy==null)
{this.dummy=jQuery('<div></div>');this.dummy.css({'font-size':this.textarea.css('font-size'),'font-family':this.textarea.css('font-family'),'width':this.textarea.css('width'),'padding':this.textarea.css('padding'),'line-height':this.line_height+'px','overflow-x':'hidden','position':'absolute','top':0,'left':-9999}).appendTo('body');}
var html=this.textarea.val().replace(/(<|>)/g,'');if($.browser.msie)
{html=html.replace(/\n/g,'<BR>new');}
else
{html=html.replace(/\n/g,'<br>new');}
if(this.dummy.html()!=html)
{this.dummy.html(html);if(this.max_height>0&&(this.dummy.height()+this.line_height>this.max_height))
{this.textarea.css('overflow-y','auto');}
else
{this.textarea.css('overflow-y','hidden');if(this.textarea.height()<this.dummy.height()+this.line_height||(this.dummy.height()<this.textarea.height()))
{this.textarea.animate({height:(this.dummy.height()+this.line_height)+'px'},100);}}}}});})(jQuery);$(function(){var flashvars={'id':'player3','file':'http://www.youtube.com/v/aTrg_yrv6t4&amp;hl=de_DE&amp;fs=1?color1=0xcc2550&amp;color2=0xe87a9f','autostart':'false'};var params={'allowfullscreen':'true','allowscriptaccess':'always','bgcolor':'#FFFFFF'};var attributes=false;swfobject.embedSWF('http://www.youtube.com/v/aTrg_yrv6t4&amp;hl=de_DE&amp;fs=1?color1=0xcc2550&amp;color2=0xe87a9f','startswf','300','250','9','false',flashvars,params,attributes);if($('#colorselect').length){var values=['00','33','66','99','CC','FF'];var colorselect='<table>';for(var i=0;i<36;i++){colorselect+='<tr>';for(var j=0;j<6;j++){var hex=values[(i%6)]+values[Math.floor(i/6)]+values[j];colorselect+='<td bgcolor="#'+hex+'" width="20" height="8" onclick="trackivwpi(\'colsel\');alert(\'Farbcode: '+hex+'\')" style="cursor:pointer;"></td>';}
colorselect+='</tr>';}
colorselect+='</table>';$('#colorselect').html(colorselect);}
if($('.hasEditor').length){$('.hasEditor').htmlarea({toolbar:[["bold","italic","underline","strikethrough","|"],["orderedlist","unorderedlist","justifyleft","justifycenter","justifyright"]]});$('.jHtmlArea iframe').css({'border':'1px solid #CCC','width':'404px'});}
$('.scrolldown').click(function(){ScrollDown('#'+$(this).parent().parent().parent().attr('id')+' .scrollDiv');$('#ivpi').attr('src','http://mamiweb.ivwbox.de/cgi-bin/ivw/CP/BoxScrollableDown;[comment]?r='+escape(document.referrer)+'&d='+(Math.random()*100000));_gaq.push(['_trackPageview']);});$('.scrollup').click(function(){ScrollUp('#'+$(this).parent().parent().parent().attr('id')+' .scrollDiv');$('#ivpi').attr('src','http://mamiweb.ivwbox.de/cgi-bin/ivw/CP/BoxScrollableDown;[comment]?r='+escape(document.referrer)+'&d='+(Math.random()*100000));_gaq.push(['_trackPageview']);});$('#question').click(function(){$('#new_question').show(500);$('#ivpi').attr('src','http://mamiweb.ivwbox.de/cgi-bin/ivw/CP/slidertoggle;[comment]?r='+escape(document.referrer)+'&d='+(Math.random()*100000));_gaq.push(['_trackPageview']);});$('body').click(function(event){if(!$('#question_text').val()&&!$('#question').val()&&$(event.target).parents('#write_new_question').attr('id')==undefined){$('#new_question').hide();}
if(!$('#StatusText').val()){$('#StatusText').css('height','20px');}
if($(event.target).is('.vote img')){antwortenstorerateing($(event.target).next().attr('id').substring(2),$(event.target),0);}else if($(event.target).is('.vote span')){antwortenstorerateing($(event.target).attr('id').substring(2),$(event.target),1);}else if($(event.target).is('.vote_frage img')){fragenstorerateing($(event.target).next().attr('id').substring(2),$(event.target),0);}else if($(event.target).is('.vote_frage span')){fragenstorerateing($(event.target).attr('id').substring(2),$(event.target),1);}});$('#StatusText').focus(function(){if($(this).val()=='Was machst du gerade'){$(this).val('');}});$('#question_text').click(function(){$('#ivpi').attr('src','http://mamiweb.ivwbox.de/cgi-bin/ivw/CP/slidertoggle;[comment]?r='+escape(document.referrer)+'&d='+(Math.random()*100000));_gaq.push(['_trackPageview']);});$('#text').click(function(){$('#ivpi').attr('src','http://mamiweb.ivwbox.de/cgi-bin/ivw/CP/slidertoggle;[comment]?r='+escape(document.referrer)+'&d='+(Math.random()*100000));_gaq.push(['_trackPageview']);});$('.Kommentar').click(function(){$('#ivpi').attr('src','http://mamiweb.ivwbox.de/cgi-bin/ivw/CP/slidertoggle;[comment]?r='+escape(document.referrer)+'&d='+(Math.random()*100000));_gaq.push(['_trackPageview']);});$('#StatusText').click(function(){$('#ivpi').attr('src','http://mamiweb.ivwbox.de/cgi-bin/ivw/CP/slidertoggle;[comment]?r='+escape(document.referrer)+'&d='+(Math.random()*100000));_gaq.push(['_trackPageview']);});$('#text').autogrow();$('#StatusText').autogrow();});function ScrollDown(obj){$(obj).find('ul:first').animate({marginTop:'-30px'},300,function(){$(this).css({marginTop:'0px'}).find('li:first').appendTo(this);});}
function ScrollUp(obj){$(obj).find('ul:first').animate({marginTop:'30px'},150,function(){$(this).css({marginTop:'0px'}).find('li:last').prependTo(this);});}
function fragenstorerateing(_fragen_id,element,self){$.getJSON(configs.absolutpfad+'A_helpers/AJAX/fragenvote.php?id='+_fragen_id,function(data){hideLoader(true);if(0<parseInt(data.message)){if(self){element.text(parseInt(element.text())+1);}else{element.next().text(parseInt(element.next().text())+1);}
alert('Dein Voting wurde gespeichert!');}else{if(0>parseInt(data.message)){alert('Du musst eingeloggt sein, um eine Antwort bewerten zu können!');location.href=data.redirect;}else{alert('Du hast bereits abgestimmt!');}}});trackivwpi('fragenstorerat');}
function antwortenstorerateing(_fragen_id,element,self){$.getJSON(configs.absolutpfad+'A_helpers/AJAX/antwortenvote.php?id='+_fragen_id,function(data){hideLoader(true);if(0<parseInt(data.message)){if(self){element.text(parseInt(element.text())+1);}else{element.next().text(parseInt(element.next().text())+1);}
alert('Dein Voting wurde gespeichert!');}else{if(0>parseInt(data.message)){alert('Du musst eingeloggt sein, um eine Antwort bewerten zu können!');location.href=data.redirect;}else{alert('Du hast bereits abgestimmt!');}}});trackivwpi('antwortstorerat');}
function showuserprofilepreview(_a,_b){showOverlayPopupJSON(configs.absolutpfad+'A_helpers/AJAX/getprofile.php?&id='+_a+'&ref='+_b,'big');}
function showOverlayPopupJSON(_a,_b,_c,_d,_e,_f){overlay.loadjson(_a,_f,null,_b,false,true);}
function showSmileyBox(_a){emoticons.show(_a);}
function getScrollXY(){var scrOfX=0,scrOfY=0;if(typeof(window.pageYOffset)=='number'){scrOfY=window.pageYOffset;scrOfX=window.pageXOffset;}else if(document.body&&(document.body.scrollLeft||document.body.scrollTop)){scrOfY=document.body.scrollTop;scrOfX=document.body.scrollLeft;}else if(document.documentElement&&(document.documentElement.scrollLeft||document.documentElement.scrollTop)){scrOfY=document.documentElement.scrollTop;scrOfX=document.documentElement.scrollLeft;}
return{x:scrOfX,y:scrOfY};}
function trackivwpi(_pi_name){$('#ivpi').attr('src','http://mamiweb.ivwbox.de/cgi-bin/ivw/CP/'+_pi_name+';[comment]?r='+escape(document.referrer)+'&d='+(Math.random()*100000));_gaq.push(['_trackPageview']);}
function count_chars(_text,_max,_elm){$('#'+_elm).text(_max-_text.length);if(_text.length>_max){alert('Du darfst maximal '+_max+' Zeichen eingeben!');}}
function logged_neu_findengutmore(_user_actionlog_id){if($('#findengut'+_user_actionlog_id).css('display')=='none'){$('#findengut'+_user_actionlog_id).show();}else{$('#findengut'+_user_actionlog_id).hide();}
trackivwpi('findengutmore');}
var kommentartext='Einen Kommentar schreiben';function logged_neu_kommentieren(_id){$('#form'+_id).show('slow');$('#log'+_id+' > .showlink').hide();$('#form'+_id+' > textarea').attr('value',kommentartext);}
function logged_neu_textareafocus(_id){var current=$('#form'+_id+' > textarea').attr('value');if(current==kommentartext){$('#form'+_id+' > textarea').attr('value','');}}
function logged_neu_textareablur(_id){var current=$('#form'+_id+' > textarea').attr('value');if(current==undefined){$('#form'+_id+' > textarea').attr('value',kommentartext);}}
function logged_neu_entrymore(_user_actionlog_id){$('#entry'+_user_actionlog_id+' .hide').show();$('#entry'+_user_actionlog_id+'more').hide();trackivwpi('moreactionlog');}
function openBrowserPopup(_a,_b,_c,_d){var add='';if(_b!=undefined)add+="width="+_b+",";if(_c!=undefined)add+="height="+_c+",";thewindow=window.open(_a,"Mamiwin"+_d,add+"left=100,top=200,scrollbars=yes");thewindow.focus();}
function report_misuse(_a,_b,_c){showOverlayPopupJSON(configs.absolutpfad+'formal/reportmisuse.php?type='+_a+'&id='+_b+'&parentid='+_c,'big');}
function reportmisusesubmit(){if($('#misuseform [name=\'reason\']').attr('value')<1){alert('Bitte wähle eine Begründung aus!');return;}
if(!$('#misuseform [name=\'testimony\']').attr('value')||$('#misuseform [name=\'testimony\']').attr('value').length<1){alert('Bitte gib eine Zeugenaussage ein!');return;}
$('#misuseform').ajaxSubmit({dataType:'json',success:function(data){overlay.setoverlay('reportmisuse','Mißbrauch gemeldet',data.htmldata,'small',false,true);}});overlay.loader();}
function mitglieder_changegbooklayout(_layoutname){$('#design_head').removeClass();$('#design_body').removeClass();$('#text').removeClass();$('#design_foot').removeClass();$('#design_head').addClass(_layoutname+'head');$('#design_body').addClass(_layoutname+'body');$('#text').addClass(_layoutname+'text');$('#design_foot').addClass(_layoutname+'foot');trackivwpi('mitglieder_changegbooklayout');}
function mitglieder_gbookprofiedit(_a){if(_a){}else{alert('Der Proieditor kann nicht beendetw erden - Sorry!');}}
function mitglieder_showmoreoptions(){$('#moreguestbookoptions').hide();$('#gaestebuchoptionen').show();}