window.hzmr = window.hzmr || [];
/************* Start spaceActions.js for locale en-US **************/
try {function showAddToMyGalleryForm(e){}function showPostToForumForm(e,t){}function showAprilFoolsDialog(){HZ.spaceActions.AprilFoolsDialog||(HZ.spaceActions.AprilFoolsDialog=new HZ.spaceActions.AprilFoolsClass,HZ.spaceActions.AprilFoolsDialog.prepare()),HZ.ui.Yamdi.show(HZ.spaceActions.AprilFoolsDialog)}function showEmbedDialog(e){HZ.spaceActions.EmbedDialog.setSpaceId(e),HZ.ui.Yamdi.show(HZ.spaceActions.EmbedDialog)}HZ.ns("HZ.spaceActions"),HZ.spaceActions.QuestionDialog=new function(){var i,o,e,n,t,s,a=0,l=1,r=2,d=3,c=null,u=null,p=null,h=!1,g=!1,m=null,v="quotaReached";this.SPACE_TOPIC=14,this.PRODUCT_TOPIC=17,this.JSON_KEY_DAILY_QUESTIONS_QUOTA_EXCEEDED=null,this.JSON_KEY_SPACE_ID=null,this.JSON_KEY_QUESTIONS=null;var H=this.SPACE_TOPIC,f=_hgt("Ask a question about this photo.")+" ",b=_hgt("Ask a question about this product.")+" ",Z=_hgt("Your question was posted."),I=(_hgt("Write your question here. (ex: Love the chair! Where is it from?)"),_hgt("Write your question here. (ex: Love the chair! What is it made of?)"),"<div id='questionDialog_"+a+"'><div class='dialogTitle'>"+f+"</div><div class='dialogBody'><div class='dialogCenterCaption'>"+_hgt("Please wait...")+HZ.ui.AjaxThrobber.getThrobber()+"</div><div class='dialogControls'></div></div></div>"),S="<div id='questionDialog_"+l+"'><div class='dialogTitle'>"+f+"</div><div class='dialogBody'><div class='dialogStatus' id='questionQuotaExceeded'>"+_hgt("You've reached the maximum number of questions permitted per day. Please visit us again tomorrow if you have more questions.")+"</div><div class='dialogCaption' id='questionsListCaption'>"+_hgt("The answer you need may already be here:")+"</div><div class='dialogList' id='questionsList'></div><div class='dialogControls'></div></div></div>",A="<div id='questionDialog_"+r+"'><div class='dialogTitle'>"+f+"</div><div class='dialogBody'><form id='askQuestionForm' name='postToForumForm' action='javascript:;'><div class='dialogStatus' id='questionFormError'></div><div><input class='form-control' id='askQuestionInputTitle' type='text' maxlength='70' placeholder='"+_hgt("Write your question here. (ex: Love the chair! Where is it from?)")+"'></div><div><textarea class='form-control' id='askQuestionInputComment' placeholder='"+_hgt("Tell us the details here.")+"'></textarea></div><div id='questionsGuidelines'><div id='questionGuidelinesBody'>"+_hgt("Pros on Houzz are encouraged but not obligated to answer questions.<br/>Polite questions are more likely to receive responses.")+"</div></div><input type='submit' style='display:none'/><div class='dialogControls'></div></form></div></div>",_="<div id='questionDialog_"+d+"'><div class='dialogTitle'>"+Z+"</div><div class='dialogBody'><div id='askQuestionConfirmationMessage' class='pll prl'></div><div class='dialogControls'></div></div></div>";function y(){return H==HZ.spaceActions.QuestionDialog.PRODUCT_TOPIC}function w(e){var t="questionDialog_"+e;u.children().each(function(e){this.style.display=this.id==t?"block":"none"}),p.center()}function C(){p.hide(null)}function E(e){HZ.ui.AjaxThrobber.setInCall(!1),e.success&&(e[HZ.spaceActions.QuestionDialog.JSON_KEY_DAILY_QUESTIONS_QUOTA_EXCEEDED]||0<e[HZ.spaceActions.QuestionDialog.JSON_KEY_QUESTIONS].length?function(e){for(var t=e[HZ.spaceActions.QuestionDialog.JSON_KEY_QUESTIONS],e=(e[HZ.spaceActions.QuestionDialog.JSON_KEY_SPACE_ID],e[HZ.spaceActions.QuestionDialog.JSON_KEY_DAILY_QUESTIONS_QUOTA_EXCEEDED]),i="<ul>",o=0;o<t.length;o++){var s=t[o],a=parseInt(s.numberOfAnswers,10);switch(i+="<li><a href='javascript:HZ.spaceActions.QuestionDialog.openQuestionPage("+s.questionId+")'>"+s.title+"</a>",0<a&&(i+=" <span class='reply'>("),parseInt(s.numberOfAnswers,10)){case 0:break;case 1:i+=_hgt("1 reply");break;default:i+=_hgt("{replyCount} replies",{replyCount:s.numberOfAnswers})}0<a&&(i+=")</span>")}i+="</ul>",$("#questionsList").empty().append(i),$("#questionsListCaption")[0].style.display=0<t.length?"block":"none",$("#questionQuotaExceeded")[0].style.display=e?"block":"none",n[0].style.display=e?"none":"inline",w(l)}(e):D())}function k(e){$("#questionFormError").empty().append(e),e?$("#questionFormError").show():$("#questionFormError").hide(),$("[placeholder]","#askQuestionDialog").initPlaceHolders("refresh")}function D(){w(r)}function T(){if(!HZ.ui.AjaxThrobber.isInCall()){$("#askQuestionDialog").trigger("submit.question");var e=UIHelper.trim(i.value),t=UIHelper.trim(o.value);return""==e?k(_hgt("Please write your question.")):(HZ.ui.AjaxThrobber.setInCall(!0),$("#space-action__submit-question-button").attr("disabled","disabled"),HZ.ajaz.Services.postToForum(c,e,t,H,$.proxy(U,this))),!1}}function U(e){var t;$("#space-action__submit-question-button").removeAttr("disabled"),HZ.ui.AjaxThrobber.setInCall(!1),"true"==e.success?(t=_hgt("More questions about your project or decor?"),e[v]&&(t="<div class='overQuota'>"+_hgt("Please note: You have reached the maximum number of questions permitted per day.")+"</div>"+t),$("#askQuestionConfirmationMessage").empty().append(t),null!=m&&HZ.utils.Logger.sendEventLogOnce(m),w(d)):(HZ.ui.Yamdi.hide(this),HZ.ui.yamdi.Common.alert(e.error))}this.init=function(e,t){c=e},this.setDelegate=function(e){p=e},this.setTrackingEventSource=function(e){m=e},this.setShowLinkOnNewWindow=function(e){h=e},this.setQuestionTopic=function(e){H=e},this.setQuestionUpsellLink=function(e){s=e},this.openQuestionPage=function(e){e=HZ.utils.Links.getQuestionLink(e);h?window.open(e):window.location=e},this.getView=function(){return u||(u=$("<div id='askQuestionDialog'></div>").addClass("dialogFrame").append(I).append(S).append(A).append(_),e=HZ.ui.InputButtonUtils.createPrimaryInputButton(_hgt("Submit"),"space-action__submit-question-button",$.proxy(T,this)),n=HZ.ui.InputButtonUtils.createPrimaryInputButton(_hgt("I have another question"),"",$.proxy(D,this)),t=HZ.ui.InputButtonUtils.createPrimaryInputButton(_hgt("Go to Advice"),null,function(){window.location.href=s},null,null,"seeWorkButton"),$("body").append(u),$("#questionDialog_"+a+" .dialogControls",u).append(HZ.ui.InputButtonUtils.createSecondaryInputButton(_hgt("Cancel"),null,null,null,null,"cancelButton")),$("#questionDialog_"+l+" .dialogControls",u).append(HZ.ui.InputButtonUtils.createSecondaryInputButton(_hgt("Cancel"),null,null,null,null,"cancelButton")).append(n),$("#questionDialog_"+r+" .dialogControls",u).append(HZ.ui.AjaxThrobber.getThrobber()).append(HZ.ui.InputButtonUtils.createSecondaryInputButton(_hgt("Cancel"),null,null,null,null,"cancelButton")).append(e),$("#questionDialog_"+d+" .dialogControls",u).append(HZ.ui.InputButtonUtils.createSecondaryInputButton(_hgt("No Thanks"),null,null,null,null,"cancelButton")).append(t),$(".cancelButton",u).click($.proxy(C,this)),i=$("#askQuestionInputTitle")[0],$("#askQuestionInputTitle").charCount({css:"counter text-xs",counterElement:"div",allowed:70,prewarning:20,warning:10,counterText:_hgt("Characters Left")+" "}),o=$("#askQuestionInputComment")[0]),u},this.viewLoaded=function(){k(""),i.value="",$(i).trigger("change"),o.value="",HZ.ui.AjaxThrobber.setInCall(!1),g?$("[placeholder]","#askQuestionDialog").initPlaceHolders("refresh"):(g=!0,$("[placeholder]","#askQuestionDialog").initPlaceHolders({saveContainer:"#askQuestionDialog",saveEvent:"submit.question"}));var e=y()?b:f;y();HZ.utils.Config.isResponsive&&$("#askQuestionInputTitle").attr("placeholder",_hgt("Title")),$("#questionDialog_"+a+" .dialogTitle",u).html(e),$("#questionDialog_"+l+" .dialogTitle",u).html(e),$("#questionDialog_"+r+" .dialogTitle",u).html(e),y()?$("#questionsGuidelines").hide():$("#questionsGuidelines").show(),function(){w(a),HZ.ui.AjaxThrobber.setInCall(!0),HZ.spaceActions.getExistingQuestions(c,$.proxy(E,this))}()},this.viewUnloaded=function(){}},HZ.spaceActions.DontPrintDialog=new function(){var o=null,t=null,i="photo";this.setDelegate=function(e){0},this.lastInvokedDate=function(){return t},this.setLastInvokedDate=function(e){t=e},this.setPrintSubject=function(e){i=e},this.getPrintSubject=function(){return i},this.daysElapsedFromToday=function(){var e=this.currentDateAsTimestamp(),t=new Date(this.lastInvokedDate()),t=Math.abs(e-t);return Math.floor(t/864e5)},this.currentDateAsTimestamp=function(){return(new Date).getTime()},this.checkUserPref=function(t,i,e){!this.lastInvokedDate()||1<this.daysElapsedFromToday()?(this.setPrintSubject(e),this.setLastInvokedDate(this.currentDateAsTimestamp()),HZ.ajaz.Services.updateUserPreferences(15,null,function(e){}),HZ.utils.Logger.sendEventLog("dpd_shown"),HZ.ui.Yamdi.show(HZ.spaceActions.DontPrintDialog,null),(e=$("#continueToPrint"))&&e.click(function(e){HZ.utils.Logger.sendEventLog("dpd_print"),HZ.ui.Yamdi.hide(null),HZ.utils.Print.printUrl(t,i)})):HZ.utils.Print.printUrl(t,i)},this.getView=function(){var e,t,i;return o||(i=t=e="",i="photo"==this.getPrintSubject()?(e=_hgt("Print Photo"),t=_hgt("Help the environment by sharing this photo another way:"),_hgt("No thanks. Please print this photo")):(e=_hgt("Print Ideabook"),t=_hgt("Help the environment by sharing this ideabook another way:"),_hgt("No thanks. Please print this ideabook")),o=$("<div id='dontPrintDialog'>").addClass("dialogFrame").append("<div class='dialogTitle'><span id='dontPrintTitleIcon'></span>"+e+"</div><div class='dialogBody'><div class='dialogSection'><div class='dialog-section-header'>"+t+"</div><div id='emailSection' class='dialogSection-item'><div class='image-container'><a href='javascript:;' onclick=sendMail()> <div id='emailIcon'></div><p class='image-caption colorLink' href='javascript:;'>"+_hgt("Email{contextEmailVerb}",{"context.emailVerb":""})+"</p><p class='secondary-caption'>"+_hgt("Send it now")+"</p></a></div></div><div id='downloadAppSection' class='dialogSection-item'><div class='image-container'><a href='"+HZ.utils.Links.getPageUrl("mobileApps")+"'><div id='downloadAppIcon'></div><p class='image-caption colorLink' href='javascript:;'>"+_hgt("Houzz App")+"</p><p class='secondary-caption'>"+_hgt("Take it with you")+"</p></a></div></div></div><div class='dialogControls'><a id='continueToPrint' class='colorLink' href='javascript:;'>"+i+"</a></div></div></div>"),$("body").append(o)),o},this.viewLoaded=function(){},this.viewUnloaded=function(){},sendMail=function(){HZ.ui.Yamdi.hide(null),"function"==typeof showSendEmailDialog?showSendEmailDialog():HZ.lb.plugins.SpaceActions.handleEmail()}},HZ.spaceActions.PhotoOverlay=new function(){var e=null;this.getPromoView=function(){return e=e||$("<div class='wrapper-block'><div class='wrapper-table'><div class='wrapper-cell'><div id='signup_overlay' class='promote' data-type='hover'><span class='likeIt icon-wrap'>"+_hgt("Save Photo")+"<span class='more-icon'></span></span><br/></div></div></div></div>")},this.assembleOverlayElements=function(){var e=[];return null===HZ.data.CurrentSessionUser&&e.push(this.getPromoView()),e}},HZ.spaceActions.AprilFoolsClass=function(){var t={"":HZ.utils.Config.siteBaseUrl+"/ideabooks/46342399",uk:HZ.utils.Config.siteBaseUrl+"/ideabooks/46510556",au:HZ.utils.Config.siteBaseUrl+"/ideabooks/46495938",ru:HZ.utils.Config.siteBaseUrl+"/ideabooks/46510315",de:HZ.utils.Config.siteBaseUrl+"/ideabooks/46510299",fr:HZ.utils.Config.siteBaseUrl+"/ideabooks/46511131/list/pt=61d4bbfda7043bdc1366aa98c362bbd1/houzzlenz-une-nouvelle-facon-de-voir-votre-interieur"};function i(){this.getDelegate().hide(null)}HZ.spaceActions.AprilFoolsClass.superclass.constructor.call(this),this.prepare=function(){var e=HZ.ui.InputButtonUtils.createPrimaryInputButton(_hgt("Done"),_hgt("cancel"),$.proxy(i,this)),e={body:$("<div>").append(HZ.utils.Html.template("<h1 class='header-1'>%MAIN_HEADER%\t\t\t\t\t\t<a href='javascript:void(0);' onclick='HZ.spaceActions.AprilFoolsDialog.closeDiag(); return false;'><span class='closeButton hzi-font hzi-CloseX'></span></a>\t\t\t\t\t</h1>\t\t\t\t\t<h2 class='header-5 houzzlenz-subheader'>%SUB_HEADER%</h2>\t\t\t\t\t<iframe width='640' height='385' src='%VIDEO_LINK%' allowTransparency='true' frameborder='0' webkitAllowFullScreen allowfullscreen></iframe>\t\t\t\t\t<div class='ideabook-link-container'>\t\t\t\t\t\t<a href='%HOUZZ_LENZ_IDEABOOK_LINK%' class='hzBtn primary ideabook-btn'>%IDEABOOK_LINK_LABEL%</a>\t\t\t\t\t</div>",{SUB_HEADER:_hgt("The New Way To Design And Experience Your Home"),HOUZZ_LENZ_IDEABOOK_LINK:t[HZ.utils.Config.currentSite],VIDEO_LINK:"//www.youtube.com/embed/HYIKDcMwreY?modestbranding=1&controls=1&showinfo=0&rel=0&fs=1&wmode=opaque",IDEABOOK_LINK_LABEL:_hgt("Pre-order Now"),MAIN_HEADER:_hgt("Announcing HouzzLenz")})),dialogClassName:"embedPhotoDialog aprilFoolsDialog",controls:[e],onViewLoaded:$.proxy(this.onViewLoaded,this)};this.init(e)},this.closeDiag=function(){$.proxy(i,this)()}},HZ.extend(HZ.spaceActions.AprilFoolsClass,HZ.ui.yamdi.Dialog),HZ.spaceActions.EmbedDialogClass=function(){var i,o,t=null,s="<div class='dialogCaption'>"+_hgt("Copy this code to embed this photo on your site:")+"</div><div class='dialogCaption' style='margin-top:10px;'>"+_hgt("Large Image (500 pixels):")+"</div><textarea onclick='this.select()' readonly='readonly' class='embedPhoto500 form-control'></textarea><div class='dialogCaption' style='margin-top:10px;'>"+_hgt("Small Image (320 pixels):")+"</div><textarea onclick='this.select()' readonly='readonly' class='embedPhoto320 form-control'></textarea><div class='dialogCaption' style='margin-top:10px;'>"+_hgt("WordPress <t1>Shortcode</t1>:",{t1:{tag:"a",attr:{href:HZ.utils.Links.getPageUrl("buttonsAndBadges")+"#shortcode"}}})+"</div><textarea onclick='this.select()' readonly='readonly' class='embedShortcode form-control'></textarea><div class='dialogCaption' style='margin-top:10px;font-size:12px;color:#a4a4a4;'>"+_hgt('This tool is provided to you "as is" and subject to <t1>Houzz terms of use</t1>',{t1:{tag:"a",attr:{href:HZ.utils.Links.getPageUrl("termsOfUse"),target:"_blank"}}})+"</div>";function a(){this.getDelegate().hide(null)}function e(e){e.success&&(i.val(e.largeImageEmbedCode),o.val(e.smallImageEmbedCode),shortcodeTextarea.val(e.wordpressShortcode))}HZ.spaceActions.EmbedDialogClass.superclass.constructor.call(this),this.prepare=function(){var e=HZ.ui.InputButtonUtils.createPrimaryInputButton(_hgt("Done"),_hgt("cancel"),$.proxy(a,this)),t=$("<div>").append(s);i=$(".embedPhoto500",t),o=$(".embedPhoto320",t),shortcodeTextarea=$(".embedShortcode",t);e={title:_hgt("Embed a Photo"),body:t,dialogClassName:"embedPhotoDialog",controls:[e],onViewLoaded:$.proxy(this.onViewLoaded,this)};this.init(e)},this.setSpaceId=function(e){t=e},this.onViewLoaded=function(){i.val(""),o.val(""),shortcodeTextarea.val(""),HZ.ajaz.Services.getEmbedSpaceCode(t,$.proxy(e,this))}},HZ.extend(HZ.spaceActions.EmbedDialogClass,HZ.ui.yamdi.Dialog),HZ.spaceActions.EmbedDialog=new HZ.spaceActions.EmbedDialogClass,HZ.spaceActions.EmbedDialog.prepare(),HZ.spaceActions.handleButtonClick=function(e,t){var i=e.closest(".ic"),o=e.closest("[lb-sid]"),s=e.data("sid");if(!s)if(o.length)s=o.attr("lb-sid");else if(i.length)s=i.attr("objid");else{i=e.closest(".feed-snapshot-placeholder").find("img[lb-sid]");if(!i.length)return;s=i.attr("lb-sid")}e=e.data("type");t.isCobrand?window.location=t.cobrandRedirectUrl:HZ.spaceActions.invokeSignupAndThenActionDialog(s,e,t.emailShareAfterSignup)},HZ.spaceActions.invokeSignupAndThenActionDialog=function(t,i,o){var e,s;t&&i&&(HZ.data.CurrentSessionUser?"ideabook"===i||"hover"===i?HZ.spaceActions.showAddToIdeabookDialog(t):"email"===i&&HZ.spaceActions.showEmailDialog(t,!0):(s=null,(e=HZ.data.Spaces.get(t))&&e.iids&&e.iids[0]&&(s=e.iids[0]),s=JSON.stringify({houseId:t,redirectUrl:window.location.href,imageId:s,buttonType:i}),"email"!==i||o?HZ.ajaz.Services.setVisitorProperty("postSignupHouseId",s,function(e){"ideabook"===i||"hover"===i?HZ.auth.Manager.signup(HZ.spaceActions.addToIdeabookSignupSource,HZ.spaceActions.addToIdeabookMessageId,window.location.href):"email"===i&&HZ.auth.Manager.signup(HZ.spaceActions.spaceActionsEmailSignupSource,HZ.spaceActions.spaceActionsEmailMessageId,window.location.href)}):HZ.ajaz.Services.setVisitorProperty("postSignupHouseId",s,function(e){HZ.spaceActions.showEmailDialog(t,o)})))},HZ.spaceActions.showAddToIdeabookDialog=function(e){var t,i,o=HZ.data.Spaces.get(e);HZ.data.CurrentSessionUser?HZ.spaceActions.isUniversalGalleryEnabled||HZ.ctx&&HZ.ctx.config&&HZ.ctx.config.GALLERY_ITEMS_ENABLED?o.prod?HZ.modules.SaveToUniversalGallery.saveProduct(e):HZ.modules.SaveToUniversalGallery.saveSpace(e):(HZ.spaceActions.AddToIdeabookDialog.init(e),HZ.ui.Yamdi.show(HZ.spaceActions.AddToIdeabookDialog)):(i=null,t=window.location.href,o&&o.iids&&o.iids[0]&&(i=o.iids[0]),i=JSON.stringify({houseId:e,redirectUrl:t,imageId:i,buttonType:"ideabook"}),HZ.ajaz.Services.setVisitorProperty("postSignupHouseId",i,function(e){HZ.auth.Manager.signup(HZ.spaceActions.addToIdeabookSignupSource,HZ.spaceActions.addToIdeabookMessageId,t)}))},HZ.spaceActions.showEmailDialog=function(e,t){var i,o,s=null;HZ.data&&HZ.data.Spaces&&(s=HZ.data.Spaces.get(e)),!HZ.data.CurrentSessionUser&&t?(o=null,i=window.location.href,s&&s.iids&&s.iids[0]&&(o=s.iids[0]),o=JSON.stringify({houseId:e,redirectUrl:i,imageId:o,buttonType:"email"}),HZ.ajaz.Services.setVisitorProperty("postSignupHouseId",o,function(e){HZ.auth.Manager.signup(HZ.spaceActions.spaceActionsEmailSignupSource,HZ.spaceActions.spaceActionsEmailMessageId,i)})):s&&(HZ.dialogs.EmailDialog.prepare({type:HZ.sendEmail.types.SPACE,referenceId:s.id,subject:s.t,message:s.prod?HZ.sendEmail.texts.DEFAULT_MESSAGE_PRODUCT:HZ.sendEmail.texts.DEFAULT_MESSAGE_SPACE,staticMessageData:!(!s.prod||!HZ.lb.Config.tradeUser)&&HZ.lb.Config.tradeUser,signupOnSend:!t}),HZ.ui.Yamdi.show(HZ.dialogs.EmailDialog))},HZ.spaceActions.Share={GOOGLE_PLUS:HZ.utils.Config.socialSharePlatforms.googlePlus,FACEBOOK:HZ.utils.Config.socialSharePlatforms.facebook,TWITTER:HZ.utils.Config.socialSharePlatforms.twitter,LINKEDIN:HZ.utils.Config.socialSharePlatforms.linkedIn,VKONTAKTE:HZ.utils.Config.socialSharePlatforms.vkontakte,ODNOKLASSNIKI:HZ.utils.Config.socialSharePlatforms.odnoklassniki,LINE:HZ.utils.Config.socialSharePlatforms.line,openShareWindowForSpace:function(e,t){var i,o,s,a,n,l,r="",d="";HZ.data&&HZ.data.Spaces&&(l=HZ.data.Spaces.get(t))&&(a=HZ.utils.Links.getSpaceLink(l.id),n=l.t,d=l.c,e==this.FACEBOOK&&(i=HZ.utils.Styles.getStyleUrl(l.s),t=HZ.data.Categories.getCategoryById(l.cat),o=l.ma,s=HZ.data.Users.get(l.ow),i&&(n+=" - "+i),t&&(n+=" - "+t.name),o&&(n+=" - "+o),s&&(n+=_hgt(" - by {owner}",{owner:s.d})),r="",o=HZ.utils.Links.getFbFeedRedirectLink(),s="popup"),this.openShareWindow(e,a,n,r,o,s,d))},openShareWindow:function(e,t,i,o,s,a,n){var l;switch(n=n||"",e){case this.FACEBOOK:l="https://www.facebook.com/dialog/feed?app_id="+HZ.utils.Config.fbAppId+"&link="+encodeURIComponent(t)+"&caption="+encodeURIComponent(o)+"&name="+encodeURIComponent(i)+"&redirect_uri="+encodeURIComponent(s)+"&display="+encodeURIComponent(a)+"&description="+encodeURIComponent(n);break;case this.TWITTER:l="http://twitter.com/intent/tweet?url="+encodeURIComponent(t)+"&text="+encodeURIComponent(i);break;case this.GOOGLE_PLUS:l="https://plus.google.com/share?url="+encodeURIComponent(t);break;case this.LINKEDIN:l="http://www.linkedin.com/shareArticle?mini=true&url="+encodeURIComponent(t)+"&title="+encodeURIComponent(i)+"&summary="+encodeURIComponent(o);break;case this.VKONTAKTE:l="http://vkontakte.ru/share.php?url="+encodeURIComponent(t)+"&title="+encodeURIComponent(i)+"&description="+encodeURIComponent(n);break;case this.ODNOKLASSNIKI:l="http://www.odnoklassniki.ru/dk?st.cmd=addShare&st.s=1&st._surl="+encodeURIComponent(t)+"&st.title="+encodeURIComponent(i)+"&st.comments="+encodeURIComponent(n);break;case this.LINE:l="http://line.me/R/msg/text/?"+encodeURIComponent(i)+"%0D%0A"+encodeURIComponent(t)}l&&window.open(l,"lbShare"+e,"height=600,width=660,resizable=0,toolbar=0,menubar=0,status=0,location=0,scrollbars=0")},EventBinder:new function(){this.init=function(e){e.spaceId&&this.setSpaceId(e.spaceId),e.$element&&this.initShareButtons(e.$element)},this.setSpaceId=function(e){this.spaceId=e},this.initShareButtons=function(e){e&&e.on("click",".icon-socialshare",$.proxy(this.onShareButtnClick,this))},this.onShareButtnClick=function(e){var t=$(e.currentTarget),e=this.spaceId;void 0===e&&(e=t.data("id")),HZ.spaceActions.Share.openShareWindowForSpace(t.data("social"),e)}},populateToGallerySelect:function(e,t){var i,o,s,a,n,l,r,d=HZ.spaceActions.AddToIdeabookDialog.getGalleries(),c=$(e);0<(i=d?(o=d.recent).length:i)&&HZ.ui.Utils.addOptionGroupToSelect(c,_hgt("Recently Used:"),-1,"recentIdeabooks");for(var u=0;u<i;u++)r=(n=o[u]).featured?" ("+_hgt("Featured")+")":"",l=n.id==t,HZ.ui.Utils.addOptionToGroupSelect(c,n.title+r,n.id,l,"recentIdeabooks");HZ.ui.Utils.addOptionGroupToSelect(c,_hgt("Your Ideabooks:"),-1,"yourIdeabooks"),d&&(i=(s=d.own).length);for(u=0;u<i;u++)r=(n=s[u]).featured?" ("+_hgt("Featured")+")":"",l=n.id==t,HZ.ui.Utils.addOptionToGroupSelect(c,n.title+r,n.id,l,"yourIdeabooks");0<(i=d?(a=d.shared).length:i)&&HZ.ui.Utils.addOptionGroupToSelect(c,_hgt("Shared Ideabooks:"),-1,"sharedIdeabooks");for(u=0;u<i;u++)l=(n=a[u]).id==t,HZ.ui.Utils.addOptionToGroupSelect(c,n.title+_hgt("(Shared)"),n.id,l,"sharedIdeabooks")}};

window.hzmr.push("spaceActions:29383330");
} catch (err) {HZ.utils.Logger.sendJsExceptionStackTrace(err)}

/*************  End spaceActions.js  **************/
/************* Start socialSdk.js for locale en-US **************/
try {HZ.ns("HZ.sns"),HZ.sns.JsSdk={fb:{},google:{},loader:{},apple:{}},HZ.sns.JsSdk.fb.init=function(){},HZ.sns.JsSdk.fb.setFbTokenExpiration=function(){},HZ.sns.JsSdk.fb.isFbTokenExpired=function(){},HZ.sns.JsSdk.fb.getFbAccessToken=function(){},HZ.sns.JsSdk.loader.loadThirdPartyJsSdk=function(){},HZ.sns.JsSdk.loader.loadThirdPartyJsSdkFIF=function(){},HZ.sns.JsSdk.loader.loadOnDocumentReady=function(){},HZ.sns.JsSdkConstants={},HZ.sns.JsSdkConstants.STATUS_NOT_LOADED=1,HZ.sns.JsSdkConstants.STATUS_LOADING=2,HZ.sns.JsSdkConstants.STATUS_LOADED=3,HZ.sns.JsSdkConstants.FB=1,HZ.sns.JsSdkConstants.GOOGLE=2,HZ.sns.JsSdkConstants.TW=3,HZ.sns.JsSdkConstants.VK=4,HZ.sns.JsSdkConstants.OD=5,HZ.sns.JsSdkConstants.LINE=6,HZ.sns.JsSdkConstants.APPLE=7,HZ.sns.JsSdkConstants.GOOGLE_IS=8,HZ.sns.JsSdkController={},HZ.sns.JsSdkController.sdkLoaded={},HZ.sns.JsSdkController.sdkConfig={},HZ.sns.JsSdkController.sdkConfig[HZ.sns.JsSdkConstants.FB]={url:HZ.utils.Config.fbJsLibUrl,id:"facebook-jssdk"},HZ.sns.JsSdkController.sdkConfig[HZ.sns.JsSdkConstants.GOOGLE]={url:"https://apis.google.com/js/platform.js",id:"gplatform-js"},HZ.sns.JsSdkController.sdkConfig[HZ.sns.JsSdkConstants.GOOGLE_IS]={url:"https://accounts.google.com/gsi/client",id:"google-identity-service-js"},HZ.sns.JsSdkController.sdkConfig[HZ.sns.JsSdkConstants.TW]={url:"//platform.twitter.com/widgets.js",id:"twitter-wjs"},HZ.sns.JsSdkController.sdkConfig[HZ.sns.JsSdkConstants.VK]={url:"http://vkontakte.ru/js/api/openapi.js",id:"vk-js"},HZ.sns.JsSdkController.sdkConfig[HZ.sns.JsSdkConstants.OD]={url:"https://connect.ok.ru/connect.js",id:"od-js"},HZ.sns.JsSdkController.sdkConfig[HZ.sns.JsSdkConstants.LINE]=null,HZ.sns.JsSdkController.sdkConfig[HZ.sns.JsSdkConstants.APPLE]={url:HZ.utils.Config.appleJSUrl,id:"apple-js"},HZ.sns.JsSdkController.sdkStatus={},HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.FB]=HZ.sns.JsSdkConstants.STATUS_NOT_LOADED,HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.GOOGLE]=HZ.sns.JsSdkConstants.STATUS_NOT_LOADED,HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.GOOGLE_IS]=HZ.sns.JsSdkConstants.STATUS_NOT_LOADED,HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.TW]=HZ.sns.JsSdkConstants.STATUS_NOT_LOADED,HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.APPLE]=HZ.sns.JsSdkConstants.STATUS_NOT_LOADED,HZ.sns.JsSdkConstants.EVENT_FACEBOOK_AUTH_REQUESTED="far",HZ.sns.JsSdkConstants.EVENT_FACEBOOK_AUTH_SUCCEEDED="fas",HZ.sns.JsSdkConstants.EVENT_FACEBOOK_AUTH_FAILED="faf",HZ.sns.JsSdk.loader.loadThirdPartyJsSdk=function(s,t){if(s)for(Object.prototype.toString.call(s)!==Object.prototype.toString.call([])&&(s=[s]);s.length;){var i,a=s.shift(),n=HZ.sns.JsSdkController.sdkConfig[a];n&&(i=n.url,n=n.id,a==HZ.sns.JsSdkConstants.FB&&(HZ.tmpFbLoader.addFbRootDiv(),window.fbAsyncInit||(window.fbAsyncInit=function(){HZ.tmpFbLoader.requireInitialization(null),$(document).trigger("fbJsLoaded")})),a===HZ.sns.JsSdkConstants.APPLE&&HZ.tmpAppleLoader.initAppleState(t.appleState),function(s,t,n){var o,e=s.getElementsByTagName(t)[0];s.getElementById(n)||((t=s.createElement(t)).id=n,t.src=i,t.onload=(o=a,function(){HZ.sns.JsSdk.loader.onLibLoad(o)}),e.parentNode.insertBefore(t,e))}(document,"script",n))}},HZ.sns.JsSdk.loader.onLibLoad=function(s){HZ.sns.JsSdkController.sdkStatus[s]=HZ.sns.JsSdkConstants.STATUS_LOADED,s==HZ.sns.JsSdkConstants.GOOGLE||s==HZ.sns.JsSdkConstants.GOOGLE_IS?HZ.sns.JsSdk.google.initiateAuth():s==HZ.sns.JsSdkConstants.APPLE?HZ.sns.JsSdk.apple.initiateAuth():s===HZ.sns.JsSdkConstants.FB&&HZ.sns.JsSdk.fb.subscribeFbEvent()},HZ.sns.JsSdk.loader.loadThirdPartyJsSdkFIF=function(e){if(e){Object.prototype.toString.call(e)!==Object.prototype.toString.call([])&&(e=[e]);var i,a,t,s,n=!1,d=window,o=document.createElement("iframe");o.src="javascript:false",o.title="",(o.frameElement||o).style.cssText="position: absolute; left: -10000px; top: -10000px; width: 0; height: 0; border: 0",(s=(s=document.getElementsByTagName("script"))[s.length-1]).parentNode.insertBefore(o,s);try{t=(i=o.contentWindow).document}catch(s){a=document.domain,o.src="javascript:var d=document.open();d.domain='"+a+"';void(0);",t=(i=o.contentWindow).document}if(Array.prototype.indexOf)n=-1!==e.indexOf(HZ.sns.JsSdkConstants.FB);else for(var r=e.length,l=0;l<=r;l++)if(e[l]===HZ.sns.JsSdkConstants.FB){n=!0;break}n&&HZ.tmpFbLoader.addFbRootDiv(),n&&!window.fbAsyncInit&&(window.fbAsyncInit=function(){HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.FB]=HZ.sns.JsSdkConstants.STATUS_LOADED,HZ.tmpFbLoader.requireInitialization(null),$(document).trigger("fbJsLoaded")}),t.open()._l=function(){for(;e.length;){var s,t,n,o=e.shift();HZ.sns.JsSdkController.sdkStatus[o]===HZ.sns.JsSdkConstants.STATUS_NOT_LOADED&&(HZ.sns.JsSdkController.sdkStatus[o]=HZ.sns.JsSdkConstants.STATUS_LOADING,t=(s=HZ.sns.JsSdkController.sdkConfig[o]).id,this.getElementById(t)||(i.inDapIF=!0,n=this.createElement("script"),a&&(this.domain=a),t&&(n.id=t),n.readyState?n.onreadystatechange=function(s){return function(){"loaded"!=n.readyState&&"complete"!=n.readyState||(n.onreadystatechange=null,HZ.sns.JsSdkController.sdkStatus[s]=HZ.sns.JsSdkConstants.STATUS_LOADED,s===HZ.sns.JsSdkConstants.TW?(d.twttr=d.twttr||i.twttr||{},d.twttr&&d.twttr.widgets.load(d.document.getElementById("shareList"))):s!==HZ.sns.JsSdkConstants.GOOGLE&&s!==HZ.sns.JsSdkConstants.GOOGLE_IS||(d.gapi=d.gapi||i.gapi||{},d.gapi&&(i.gapi=d.gapi,d.___gcfg=i.___gcfg={lang:"en-US",parsetags:"explicit"},d.gapi.plus.go(d.document.getElementById("shareList")))))}}(o):n.onload=function(s){return function(){HZ.sns.JsSdkController.sdkStatus[s]=HZ.sns.JsSdkConstants.STATUS_LOADED,s===HZ.sns.JsSdkConstants.TW?(d.twttr=d.twttr||i.twttr||{},d.twttr&&d.twttr.widgets.load(d.document.getElementById("shareList"))):s!==HZ.sns.JsSdkConstants.GOOGLE&&s!==HZ.sns.JsSdkConstants.GOOGLE_IS||(d.gapi=d.gapi||i.gapi||{},d.gapi&&(i.gapi=d.gapi,d.___gcfg=i.___gcfg={lang:"en-US",parsetags:"explicit"},d.gapi.plus.go(d.document.getElementById("shareList"))))}}(o),n.src=s.url,this.body.appendChild(n)))}},t.write('<body onload="document._l();">'),t.close()}},HZ.sns.JsSdk.loader.loadOnDocumentReady=function(s,t){$(document).ready(this.loadThirdPartyJsSdk(s,t))},HZ.tmpGoogleLoader=new function(){var o=null;this.initiateAuth=function(){gapi.load("auth2",function(){o=gapi.auth2.init({client_id:HZ.utils.Config.googleClientId,cookiepolicy:"single_host_origin",fetch_basic_profile:!1,scope:"profile email"})})},this.requestGoogleAuth=function(s,t,n){console.log("Requesting Google auth code through old Google library ..."),o.grantOfflineAccess(n).then(s,t)}},HZ.tmpGoogleIdentityServiceLoader=new function(){var s=null;this.initiateAuth=function(){HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.GOOGLE_IS]===HZ.sns.JsSdkConstants.STATUS_LOADED&&(s=google.accounts.oauth2.initCodeClient({client_id:HZ.utils.Config.googleClientId,scope:"profile email",ux_mode:"popup",callback:HZ.auth.Manager.handleGoogleAuthSuccess,error_callback:HZ.auth.Manager.handleGoogleAuthFailure,include_granted_scopes:!1}))},this.requestGoogleAuth=function(){console.log("Requesting Google auth code through new Google library ..."),s&&s.requestCode()}},HZ.tmpGoogleLoader&&(HZ.sns.JsSdk.google=HZ.tmpGoogleLoader),HZ.tmpFbLoader=new function(){var n,o=""+HZ.utils.Config.fbAppId,e=!1,i=null,a=null,d=null,r=null,l=null,u=0,S=null,c=!1,k=HZ.utils.Links.getPicUrl("channel.html");function p(s){var t;(S=s)&&("connected"==s.status?(c=!0,l=s.authResponse.accessToken,i=s.authResponse.userID,t=.001*(new Date).getTime(),u=t+parseInt(s.authResponse.expiresIn,10)):c="not_authorized"==s.status)}this.setFbAppId=function(s){o=s},this.getFbAppId=function(){return o},this.isFbLoggedIn=function(){return c},this.getFbUserId=function(){return i},this.getFbLastName=function(){return d},this.getFbFirstName=function(){return a},this.getFbEmail=function(){return r},this.getFbAccessToken=function(){return l},this.init=function(s){s&&"function"==typeof s&&(e?s():$(document).bind("fbJsLoaded",s))},this.addFbRootDiv=function(){var s,t;document.getElementById("fb-root")||(s=document.body.firstChild,(t=document.createElement("div")).id="fb-root",document.body.insertBefore(t,s))},this.setFbTokenExpiration=function(s){u=s},this.getFbTokenExpiration=function(){return u},this.isFbTokenExpired=function(){var s=.001*(new Date).getTime();return u<s},this.requireInitialization=function(s){return HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.FB]!=HZ.sns.JsSdkConstants.STATUS_LOADED&&s?(HZ.sns.JsSdk.fb.init(function(){s.callee.apply(HZ.sns.JsSdk.fb,s)}),HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.FB]==HZ.sns.JsSdkConstants.STATUS_NOT_LOADED&&HZ.sns.JsSdk.loader.loadOnDocumentReady(HZ.sns.JsSdkConstants.FB),!1):(e||(t={appId:o,status:!1,cookie:!0,xfbml:!0,channelUrl:k},""!=HZ.utils.Config.fbApiVersion&&(t.version="v"+HZ.utils.Config.fbApiVersion),FB.init(t),e=!0),!0);var t},this.getFbAuthResponse=function(){return S},this.requestFbAuth=function(s,n,o,e,t){var i;this.requireInitialization(arguments)&&(i={scope:s=s||HZ.utils.Config.fbDefaultScope},t&&(i=$.extend(i,t)),HZ.utils.Logger.sendEventLogOnce(HZ.sns.JsSdkConstants.EVENT_FACEBOOK_AUTH_REQUESTED),FB.login(function(s){var t;p(s),s&&"connected"==s.status?(HZ.utils.Logger.sendEventLogOnce(HZ.sns.JsSdkConstants.EVENT_FACEBOOK_AUTH_SUCCEEDED),e?(t=n,HZ.sns.JsSdk.fb.graphApi("/me",function(s){s.first_name&&(a=s.first_name),s.last_name&&(d=s.last_name),s.email&&(r=s.email),"function"==typeof t&&t()})):"function"==typeof n&&n()):(HZ.utils.Logger.sendEventLogOnce(HZ.sns.JsSdkConstants.EVENT_FACEBOOK_AUTH_FAILED),"function"==typeof o&&o())},i))},this.subscribeFbEvent=(n={},function(s,t){if(HZ.sns.JsSdkController.sdkStatus[HZ.sns.JsSdkConstants.FB]===HZ.sns.JsSdkConstants.STATUS_LOADED)return function(){for(var s in n){var t;n.hasOwnProperty(s)&&(t=n[s],FB.Event.subscribe(s,t))}}(),FB.Event.subscribe;n[s]=t}),this.graphApi=function(s,t){FB.api(s,t)},this.getFbLoginStatus=function(t){this.requireInitialization(arguments),S?"function"==typeof t&&t(S):FB.getLoginStatus(function(s){p(s),"function"==typeof t&&t(s)})},this.postToFeed=function(s,t,n,o,e){FB.ui({method:"feed",redirect_uri:e,link:s,picture:o,name:t,caption:"",description:n},function(s){})}},HZ.tmpFbLoader&&(HZ.sns.JsSdk.fb=HZ.tmpFbLoader),HZ.tmpAppleLoader=new function(){var s=HZ.utils.Config.appleWebClientId,t=HZ.utils.Config.appleScope,n=HZ.utils.Config.appleWebRedirectUri;this.initiateAuth=function(){AppleID.auth.init({clientId:s,scope:t,redirectURI:n,state:this.appleState})},this.initAppleState=function(s){this.appleState=s}},HZ.tmpAppleLoader&&(HZ.sns.JsSdk.apple=HZ.tmpAppleLoader);

window.hzmr.push("socialSdk:29383330");
} catch (err) {HZ.utils.Logger.sendJsExceptionStackTrace(err)}

/*************  End socialSdk.js  **************/
/************* Start siteAuth.js for locale en-US **************/
try {HZ.ns("HZ.auth"),HZ.auth.LoginWrapperDialog=new function(){var e=null,i=null,o=null,t=null,a=null;this.show=function(e,n,i,o){this.init(e),t=i||824,a=o||473,HZ.ui.Yamdi.show(this,n)},this.init=function(e){o=e},this.setDelegate=function(e){i=e},this.getView=function(){return e||(e=$("<div id='loginWrapperDialog'></div>").addClass("dlgWrapperFrame").append("<div id='loginWrapperDialog_0'><iframe id='loginWrapperDialog_0_frame' scrolling='no' frameborder='0' allowtransparency='false' style='border: medium none; overflow: hidden;'></iframe></div>"),$("body").append(e)),$("#loginWrapperDialog").css("width",t+"px"),$("#loginWrapperDialog").css("height",a+"px"),$("#loginWrapperDialog_0_frame").css("width",t+"px"),$("#loginWrapperDialog_0_frame").css("height",a+"px"),e},this.viewLoaded=function(){var n;o&&encodeURIComponent(o);document.getElementById("loginWrapperDialog_0_frame").src=HZ.utils.Config.secureUrl+o,n="loginWrapperDialog_"+0,e.children().each(function(e){this.style.display=this.id==n?"block":"none"}),i.center()},this.viewUnloaded=function(){$("#loginWrapperDialog").remove(),param=e=null}},HZ.auth.Manager=new function(){var o=null,t=null,n=!1,s=null,a=!1,r=null,l=null,u=null,g=null,c=null,d="",h=!1,p=!1,m=null,f=null,S=null,_=null,H=null,E=!1,Z=!0,y=!1,R=!1,I=!1,A=!1,i=!1,L=null,C=null,b=null,O=!1,U="/signup",v="/signin",w=null,D="",z=!1,M=null,k=null,P=null,N=null,j=null,G=null;function F(){r=r||top.location.href.toString();var e,n="",n="signup"===u?U:v,i={u:r,d:t};return g&&(i.username=g),c&&(i.m=c),S&&(i.t=S),f&&(i.ft=f),H&&(i.s=H),R&&(i.fl=R),A&&(i.f=1),k&&(i.sourceUser=k),b&&(e=Math.floor(.001*(new Date).getTime()-C)+L,i.rt=HZ.utils.Links.base64Encode(e+","+b)),n+"/"+function(e){var n,i=new Array;for(n in e)"u"==n?i.push(encodeURIComponent(n.toString())+"="+HZ.utils.Links.base64Encode(e[n].toString())):i.push(encodeURIComponent(n.toString())+"="+encodeURIComponent(e[n].toString()));return i.join("/")}(i)}function J(){window.location=F()}function T(e,n){e=e.getBody();e.find("div.form-group").removeClass("has-error"),e.find("label.control-label").text(_hgt("Email{contextEmailNoun}",{contextEmailNoun:""})),e.find("input#missingEmailInput").val(g),n&&(e.find("div.form-group").addClass("has-error"),e.find("label.control-label").text(_hgt(n)))}function W(e){HZ.ui.yamdi.Common.hideAllDialogs();var n=(P||(P=new HZ.ui.yamdi.Dialog,n=HZ.ui.InputButtonUtils.createPrimaryInputButton(_hgt("Continue"),"",function(){var e=$("#missingEmailInput").val();e?(HZ.auth.Manager.setDefaultEmail(e),B()):T(P,_hgt("Please enter an email address to complete your sign up:"))}),P.init({title:_hgt("Complete Your Signup"),dialogClassName:"missingEmail",controls:[n]}),P.setBody('<div class="container-fluid"><div class="mbl">'+_hgt("Please enter your email address to finish signing up.")+'</div><div class="form-group mbs"><label for="missingEmailInput" class="control-label"></label><input type="email" class="form-control" id="missingEmailInput" placeholder="'+_hgt("For example, yourname@email.com")+'"></div></div>')),P);T(n,e),HZ.ui.Yamdi.show(n)}function x(e){e=e||{},n?t="mobile":(t=t||"web",e.displayMode&&(t=e.displayMode)),e.callback&&(s=e.callback),e.redirectUrl&&(r=e.redirectUrl),e.screen&&(u=e.screen),e.email&&(g=e.email),e.messageId&&(c=e.messageId),(S=e.source?e.source:S)&&!_&&(_=S),e.hideFbLinking&&(y=e.hideFbLinking),e.layout&&(R=e.layout),e.hideLoadingDialog&&(I=e.hideLoadingDialog),e.reauthenticate&&(A=e.reauthenticate),e.openInNewWindow&&(i=e.openInNewWindow),e.rtEvent&&(b=e.rtEvent),e.googleAccountLinking&&(z=e.googleAccountLinking),e.googleAccountLinkingCallback&&(M=e.googleAccountLinkingCallback),e.sourceUser&&(k=e.sourceUser)}function Y(){HZ.sns.JsSdk.fb.getFbAccessToken()&&B()}function B(){I||(HZ.ui.yamdi.Common.hideAllDialogs(),HZ.ui.yamdi.Common.loading(_hgt("Connecting with Facebook..."))),r=r||top.location.href,HZ.ajaz.Services.fbSignUp(HZ.auth.Manager.externalSignUpHandler,r,g,!1,A)}function K(){"function"==typeof s&&s(!1)}function q(e){I||(HZ.ui.yamdi.Common.hideAllDialogs(),HZ.ui.yamdi.Common.loading(_hgt("Connecting with Google..."))),r=r||top.location.href,$.isEmptyObject(e)||(z?HZ.ajaz.Services.enableGoogleLogin(M,e.code):HZ.ajaz.Services.googleSignUp(HZ.auth.Manager.externalSignUpHandler,e.code,r,!1))}function V(e){}function X(e){var n,i=!1;a=r=!1,e&&e[HZ.ajaz.Authorize.JSON_KEY_REDIRECT_URL]&&(r=e[HZ.ajaz.Authorize.JSON_KEY_REDIRECT_URL]),e&&e.success&&"true"==e.success?(HZ.OmniLogAPI.signupFormStepCompleted(N,j,_),e[HZ.ajaz.Authorize.JSON_KEY_CREATE_PRO_PROFILE_URL]&&(l=e[HZ.ajaz.Authorize.JSON_KEY_CREATE_PRO_PROFILE_URL]),e[HZ.ajaz.Authorize.JSON_KEY_SURL]&&(i=e[HZ.ajaz.Authorize.JSON_KEY_SURL]),e.newUser?(E=!0,HZ.OmniLogAPI.signupFlowCompleted(N,"Sign Up",j,G,null,_),a=!0):(HZ.OmniLogAPI.signupFlowCompleted(N,"Sign In",j,G,null,_),window.localStorage.setItem(HZ.utils.Config.justAuthenticated,JSON.stringify({type:"login"})))):(d=_hgt("We're sorry, but an unexpected error has occurred.  Please try again."),e&&(e.errorMessage&&(d=e.errorMessage),e.error&&(m=e.error,n=m,h=-1!=HZ.ajaz.Authorize.EMAIL_MINOR_ERROR.indexOf(n),n=m,p=-1!=HZ.ajaz.Authorize.PASSWORD_ERROR.indexOf(n))));function o(){"function"==typeof s&&s(a,e)}i?HZ.ajaz.Services.setSession(i,o):o()}ADD_USER_EMAIL_EXISTS=7,ERROR_DEACTIVATED_ACCOUNT=13,ERROR_FB_MISSING_EMAIL=31,ERROR_GOOGLE_MISSING_EMAIL=32,this.useGoogleIdentityServiceLibrary=!1,this.setIsMobile=function(e){n=e},this.setDisplayMode=function(e){t=e},this.setSignupBaseUrl=function(e){U=e},this.setSigninBaseUrl=function(e){v=e},this.setSupportUrl=function(e){w=e},this.getDisplayMode=function(){return t},this.setUserId=function(e){o=e},this.getUserId=function(){return o},this.isUserCreated=function(){return E},this.getScreen=function(){return u},this.setSignupLabel=function(e){0},this.setSignupSource=function(e){_=e},this.getSignupSource=function(){return _},this.setSourcePage=function(e){H=e},this.getSourcePage=function(e){return H},this.setServerStartTime=function(e){L=e},this.getMessageId=function(){return c},this.getErrorMsg=function(){return d},this.getErrorCode=function(){return m},this.getMinorEmailError=function(){return h},this.getPasswordError=function(){return p},this.setDefaultEmail=function(e){g=e},this.setShowFbWelcome=function(e){Z=e},this.setDefaultFbLoginScope=function(e){O=e},this.getRedirectUrl=function(){return r},this.getCreateProProfileUrl=function(){return l},this.setGoogleScopes=function(e){D=e.join(" ")},this.setAuthType=function(e){N=e},this.getAuthType=function(){return N},this.setSignupFormType=function(e){j?G=e:j=e},this.loginComplete=function(e){"function"==typeof s?s(a,e):o&&(r?top.location=r:top.location.reload())},this.externalSignUpHandler=function(e){var n,i;a=!1,e&&"true"===e.success?(i="Google"===N?"Google Identity Service":N,HZ.OmniLogAPI.signup3rdPartyStepCompleted(i,j),a=!0,o=e.uid,n=!1,e[HZ.ajaz.Authorize.JSON_KEY_REDIRECT_URL]&&(r=e[HZ.ajaz.Authorize.JSON_KEY_REDIRECT_URL]),e[HZ.ajaz.Authorize.JSON_KEY_CREATE_PRO_PROFILE_URL]&&(l=e[HZ.ajaz.Authorize.JSON_KEY_CREATE_PRO_PROFILE_URL]),e[HZ.ajaz.Authorize.JSON_KEY_SURL]&&(n=e[HZ.ajaz.Authorize.JSON_KEY_SURL]),e.newUser?(E=!0,HZ.OmniLogAPI.signupFlowCompleted(i,"Sign Up",j,G,null,_)):(HZ.OmniLogAPI.signupFlowCompleted(i,"Sign In",j,G,null,_),window.localStorage.setItem(HZ.utils.Config.justAuthenticated,JSON.stringify({type:"login"}))),i=function(){e.newUser&&"mobile"!=t&&Z?function(){var e=HZ.signup.newPostSignup.init(function(){HZ.ui.yamdi.Common.hideAllDialogs(),HZ.ui.yamdi.Common.loading(_hgt("Please wait...")),HZ.ajaz.Services.homeownerSignup(function(){HZ.auth.Manager.loginComplete()})},function(){HZ.ui.yamdi.Common.hideAllDialogs(),HZ.ui.yamdi.Common.loading(_hgt("Please wait...")),HZ.ajaz.Services.proSignup(function(){var e=HZ.auth.Manager.getCreateProProfileUrl();top.location=e})});HZ.ui.yamdi.Common.hideAllDialogs();var n=new HZ.ui.yamdi.Dialog;n.init({title:"",dialogClassName:"userTypesDialog",controls:[]}),n.setBody(e),HZ.ui.Yamdi.show(n)}():(I||HZ.ui.yamdi.Common.hideAllDialogs(),HZ.auth.Manager.loginComplete(e))},n?HZ.ajaz.Services.setSession(n,i):i()):e&&e.error==ADD_USER_EMAIL_EXISTS&&!y?(g=e.email,e.redirectUrl?top.location=e.redirectUrl:(u="signin","g"===e.operation?c=10:(c=1,f="x"),J())):!e||e.error!=ERROR_FB_MISSING_EMAIL&&e.error!=ERROR_GOOGLE_MISSING_EMAIL?e&&e.error==ERROR_DEACTIVATED_ACCOUNT?(c=14,J()):I||(HZ.ui.yamdi.Common.hideAllDialogs(),HZ.ui.yamdi.Common.alert(_hgt("We're sorry, please refresh and try again!"),_hgt("We're sorry, but we encountered an unexpected issue - likely this page has timed out due to inactivity.  Please refresh this page and try again.<br/><br/>If you continue to have trouble logging in please contact us at {supportUrl} for assistance.",{supportUrl:w}))):W(g?_hgt("Please double-check the email address below:"):null)},this.fbLoginAuthorizedUser=function(e){x(e=e||{hideFbLinking:!0}),"undefined"!=typeof FB&&B()},this.fbLogin=function(e){x(e);var n=!1;e.reauthenticate&&(n={auth_type:"reauthenticate"},e.fbNonce&&(n.auth_nonce=e.fbNonce)),HZ.sns.JsSdk.fb.requestFbAuth(O,Y,K,!1,n)},this.handleGoogleAuthSuccess=function(e){q(e)},this.handleGoogleAuthFailure=function(e){},this.loadGoogleLoginOptions=function(e){var n={};return n.app_package_name=HZ.utils.Config.androidPackageName,n.scope=D,n.redirect_uri="postmessage",n.prompt="select_account",n},this.googleLogin=function(e){x(e),this.useGoogleIdentityServiceLibrary?HZ.sns.JsSdk.google.requestGoogleAuth():HZ.sns.JsSdk.google.requestGoogleAuth(q,V,this.loadGoogleLoginOptions(e))},this.emailSignup=function(e,n,i,o,t,a,r,l){s=l,HZ.ajaz.Services.signup(e,n,i,o,t,a,r,X)},this.inlineSignup=function(e,n,i,o,t,a){s=a,HZ.ajaz.Services.inlineSignup(e,n,i,o,t,X)},this.fbLoginLazyLoad=function(){HZ.sns.JsSdk.loader.loadOnDocumentReady(HZ.sns.JsSdkConstants.FB)},this.googleLoginLazyLoad=function(){this.useGoogleIdentityServiceLibrary?HZ.sns.JsSdk.loader.loadOnDocumentReady(HZ.sns.JsSdkConstants.GOOGLE_IS):HZ.sns.JsSdk.loader.loadOnDocumentReady(HZ.sns.JsSdkConstants.GOOGLE)},this.login=function(e){var n;if(i=A=I=R=y=!1,b=c=g=u=r=s=t=null,x(e),o)loginComplete();else switch(t){case"dialog":HZ.auth.LoginWrapperDialog.show(F(),"function"==typeof s?s:null,480,480);break;case"mobile":case"web":n=F(),i?window.open(n):top.location=n}},this.signup=function(e,n,i,o,t){e={screen:"signup",redirectUrl:i=i||top.location.href.toString(),source:e};n&&(e.messageId=n),o&&(e.callback=o),t&&t.displayMode&&"dialog"==t.displayMode&&UIHelper.isIE7&&(t.displayMode="web"),t&&(e=$.extend(e,t)),HZ.auth.Manager.login(e)},this.signin=function(e,n,i){n={screen:"signin",redirectUrl:n=n||top.location.href.toString()};e&&(n.messageId=e),i&&(n.callback=i),HZ.auth.Manager.login(n)},C=.001*(new Date).getTime()};

window.hzmr.push("siteAuth:29383330");
} catch (err) {HZ.utils.Logger.sendJsExceptionStackTrace(err)}

/*************  End siteAuth.js  **************/
/************* Start themedHouzzTv.js for locale en-US **************/
try {HZ.ns("HZ.modules.ThemedHouzzTV"),HZ.modules.ThemedHouzzTV=new function(){var d,e,i,a,o,t,n,l,s,r,c=null,u=null,h=null,m=!1,v=null,g=null,p=!1,f=null,V=null,y={playlistData:null,currentVideo:null,nextVideo:null,currentVideoIndex:0},b=(_hgt("NOW <br/>PLAYING"),'<li class="section-item video-item v-%VIDEO_ID% %EXTRA_CLASS%"><div class="media"><div class="media-left"><div class="img-responsive-wrapper video-thumb-ratio"><div class="img-responsive" style="background-image: url(%VIDEO_THUMB%)"></div><div class="video-thumb-cover"><div class="video-thumb-status">'+_hgt("NOW <br/>PLAYING")+'</div><div class="video-play-button"><i class="video-play-button-icon icon-font icon-play"></i></div></div></div></div><div class="media-body"><div class="header-3 text-primary">%VIDEO_TITLE%</div><div class="video-thumb-duration">%VIDEO_LENGTH%</div></div></div></li>'),x='<div class="video-context-menu"><input readonly id="videoContextMenuFocus" /><ul id="videoContextMenu" class="list-unstyled"><li><a id="optionVideoEmbedCode">'+_hgt("Get Embed Code")+'</a></li><li><a id="optionVideoUrl">'+_hgt("Get Video Url")+'</a></li><li><a id="optionVideoWordpress">'+_hgt("Get WordPress Embed Code")+"</a></li></ul></div>";function H(){p=!1,setTimeout(C,200)}function C(){p||g.hide()}function I(){var t=(HZ.utils.Config.isResponsive,b);$.each(y.playlistData,function(e,i){i.id;var o=i.name,i=HZ.utils.Html.template(t,{EXTRA_CLASS:i.id==n?"active":"",VIDEO_THUMB:i.thumbnail,VIDEO_TITLE:o,VIDEO_ID:i.id,VIDEO_LENGTH:0<i.duration?Math.floor(i.duration/60)+":"+(i.duration%60).toFixed():"0:0"});$(i).click(function(){HZ.modules.ThemedHouzzTV.loadVideo(e)}).appendTo($("#playlist"))}),d.loadVideo(y.currentVideoIndex,!0),1<y.playlistData.length&&$("#keepWatching").show()}this.init=function(e){var i;$(".section-anchors li").click(function(){$(this).siblings().removeClass("active"),$(this).addClass("active")}),(u=$(".video-content")).bind("contextmenu",function(e){g||(g=$(x),$("body").append(g),$("#optionVideoEmbedCode",g).click(d.embed),$("#optionVideoUrl",g).click(d.getUrl),$("#optionVideoWordpress",g).click(d.wordpressEmbed),$("#videoContextMenuFocus",g).blur(H)),p=!0,$(g).css({left:e.pageX,top:e.pageY}).show(),$("#videoContextMenuFocus",g).focus()}),o=e.playlistId,f=e.siteLanguage,V=e.siteLangCode,t=e.videoId,e.teaserId,l=e.isVisitor,s=e.embedPageUrl,c=e.playerType,d=this,$("#eos"),d.embedPageUrl=s,y.currentVideoIndex=e.currentVideoIndex,1==c?videojs("brightcoveplayer").ready(this.onPlayerReady):2==c&&brightcove.createExperiences(),HZ.utils.Config.isResponsive?void 0===r&&(r=new HZ.dialogs.HouzzTVPromo).prepare():(i={itemsPerPage:3,index:0,totalPage:null,init:function(){i.totalPage=Math.ceil($("#slidshowStrip .product-item").length/i.itemsPerPage),$(".navigator").click(function(){var e="navigatorRight"==$(this).attr("id")?1:-1;$(this).hasClass("disabled")||i.toggle(e)})},toggle:function(e){i.index=i.index+e,0==i.index?$(".navigator.nav-left").addClass("disabled"):i.index==i.totalPage-1?$(".navigator.nav-right").addClass("disabled"):$(".navigator").removeClass("disabled"),$("#slidshowStrip").css("left",-$("#slidshowStrip .product-item").eq(i.itemsPerPage*i.index).position().left)}}).init(),$("#hzEmbedBtn").attr("onclick","HZ.modules.ThemedHouzzTV.embed()")},this.embed=function(){var e='<div><div class="dialogCaption">'+_hgt("Copy this code to embed this video on your site:")+'</div><textarea onclick="this.select()" readonly="readonly" rows="4" class="form-control"><iframe class=\'houzztv-player\' src=\''+(d.embedPageUrl+"/"+d.currentVideoId)+"' width='490' height='310' frameborder='0'></iframe></textarea></div>";HZ.ui.yamdi.Common.alert(_hgt("Embed this video"),e)},this.wordpressEmbed=function(){var e=window.location.href;"https:"==window.location.protocol&&(e="http:"+window.location.href.substring(window.location.protocol.length));e='<div><div class="dialogCaption">'+_hgt("Copy this code to embed this video on your WordPress site:")+'</div><textarea onclick="this.select()" readonly="readonly" rows="4" class="form-control">[houzz='+e+"]</textarea></div>";HZ.ui.yamdi.Common.alert(_hgt("Embed this video"),e)},this.getUrl=function(){var e='<div><textarea onclick="this.select()" readonly="readonly" rows="2" class="form-control">'+window.location.href+"</textarea></div>";HZ.ui.yamdi.Common.alert(_hgt("Video Url"),e)},this.onSmartPlayerTemplateReady=function(){a=v.getModule(i.VIDEO_PLAYER),e=v.getModule(i.CONTENT),o?e.getPlaylistByID(o,function(e){var i=[];if(e&&e.videos&&0<e.videos.length)for(var o=0;o<e.videos.length;o++){var t=e.videos[o],a=d.getLocalizedVideoName(t);i.push({id:t.id,thumbnail:t.videoStillURL,name:a,duration:t.length})}y.playlistData=i,I()}):e.getMediaByID(t,function(e){e&&e.id&&(y.playlistData=[{id:e.id,thumbnail:e.videoStillURL,name:d.getLocalizedVideoName(e),duration:e.length}],I())})},this.onSmartPlayerTemplateLoad=function(e){m||(m=!0,v=brightcove.api.getExperience(e),i=brightcove.api.modules.APIModules)},this.onPlayerReady=function(){m||(m=!0,(a=this).on("play",function(){var e=a.textTracks().tracks_;if(e=e||a.textTracks())for(var i=V.toUpperCase(),o=0;o<e.length;o++)if(e[o].language){var t=e[o].language;if(t.toUpperCase()===i||t==f){e[o].mode="showing";break}}u.removeClass("user-landed"),u.removeClass("show-end-screen")}),a.on("ended",function(){HZ.utils.Config.isResponsive?y.currentVideoIndex+1<y.playlistData.length&&HZ.ui.Yamdi.show(r):(d.updateNextVideoHtml(),u.addClass("show-end-screen"))}),o?a.catalog.getPlaylist(o,function(e,i){if(!i||i[0]&&"PLAYLIST_NOT_FOUND"==i[0].error_code)d.handleError();else{for(var o=[],t=0;t<i.length;t++){var a=i[t];o.push({id:a.id,thumbnail:a.thumbnail,name:d.getLocalizedVideoName(a),duration:a.duration})}y.playlistData=o,I()}}):a.catalog.getVideo(t,function(e,i){i&&i.id?(y.playlistData=[{id:i.id,thumbnail:i.thumbnail,name:d.getLocalizedVideoName(i),duration:i.duration}],I()):d.handleError()}),$("#eos-video-next-btn").click(function(){d.playNextVideo()}),$("#eos .hzi-CloseX").click(function(){u.removeClass("show-end-screen")}),u.bind("contextmenu",function(e){e.preventDefault()}))},this.getLocalizedVideoName=function(e){var i="";if(e&&(e.displayName&&(i=e.displayName),e.name&&(i=e.name),e.long_description))try{e.localizedData=JSON.parse(e.long_description),e.localizedData[V]&&(i=e.localizedData[V].name)}catch(e){}return i},this.playNextVideo=function(){y.currentVideoIndex=y.currentVideoIndex+1,HZ.utils.Config.isResponsive&&HZ.ui.Yamdi.hide(),d.loadVideo(y.currentVideoIndex)},this.updateNextVideoHtml=function(){var e;y.currentVideoIndex+1<y.playlistData.length?(e=y.playlistData[(y.currentVideoIndex+1)%y.playlistData.length],$("#eos-video-thumb").css("background-image","url("+e.thumbnail+")"),$("#eos-video-title").html(e.name),$("#eos-video-next-btn").attr("next-video-id",e.id),$("#eos").removeClass("last-episode").css("background-image","url("+e.thumbnail+")")):$("#eos").addClass("last-episode")},this.handleError=function(){HZ.utils.Logger.sendError("Unable to load video or playlist")},this.replay=function(){u.removeClass("show-end-screen"),d.loadVideo(0,!0)},this.loadVideo=function(e,o){y.currentVideoIndex=e;e=y.playlistData[y.currentVideoIndex].id;2==c?a&&a.loadVideoByID(e):a.catalog.getVideo(e,function(e,i){i&&i.id?(d.currentVideoId=i.id,a.pause(),a.catalog.load(i),h&&clearTimeout(h),l&&-1!==$.inArray("reg_wall",i.tags)?HZ.utils.Config.isResponsive?HZ.modules.ThemedHouzzTV.signup():u.addClass("show-visitor-gate"):(u.removeClass("show-visitor-gate"),$("html,body").scrollTop(0),o?h=setTimeout(d.playVideo,3e3):d.playVideo()),$(".video-item").removeClass("active"),$(".video-item.v-"+d.currentVideoId).addClass("active")):d.handleError()})},this.playVideo=function(){a&&a.play()},this.signup=function(){var e=window.location.href;0<y.currentVideoIndex&&(e=-1!==e.indexOf("=")?e.split("=")[0]+"="+(y.currentVideoIndex+1):e+"/episode="+(y.currentVideoIndex+1)),HZ.auth.Manager.signup(106,21,e)}},HZ.ns("HZ.dialogs.HouzzTVPromo"),HZ.dialogs.HouzzTVPromo=function(){HZ.dialogs.HouzzTVPromo.superclass.constructor.call(this),this.prepare=function(){var e={title:"",body:$("#eos"),controls:[],hideDialogOnBgClick:!0,onViewLoaded:HZ.modules.ThemedHouzzTV.updateNextVideoHtml};this.init(e),$(".product-row").click(function(){HZ.ui.Yamdi.hide()})}},HZ.extend(HZ.dialogs.HouzzTVPromo,HZ.ui.yamdi.Dialog);

window.hzmr.push("themedHouzzTv:29383330");
} catch (err) {HZ.utils.Logger.sendJsExceptionStackTrace(err)}

/*************  End themedHouzzTv.js  **************/
/************* Start flashdetect.js for locale en-US **************/
try {var deconcept,oldunload;void 0===(deconcept=void 0===deconcept?new Object:deconcept).util&&(deconcept.util=new Object),void 0===deconcept.SWFObjectUtil&&(deconcept.SWFObjectUtil=new Object),deconcept.SWFObject=function(t,e,i,r,n,s,a,o,c,l,h){document.createElement&&document.getElementById&&(this.DETECT_KEY=h||"detectflash",this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY),this.params=new Object,this.variables=new Object,this.attributes=new Array,t&&this.setAttribute("swf",t),e&&this.setAttribute("id",e),i&&this.setAttribute("width",i),r&&this.setAttribute("height",r),n&&this.setAttribute("version",new deconcept.PlayerVersion(n.toString().split("."))),this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion(this.getAttribute("version"),a),s&&this.addParam("bgcolor",s),this.addParam("quality",o||"high"),this.setAttribute("useExpressInstall",a),this.setAttribute("doExpressInstall",!1),c=c||window.location,this.setAttribute("xiRedirectUrl",c),this.setAttribute("redirectUrl",""),l&&this.setAttribute("redirectUrl",l))},deconcept.SWFObject.prototype={setAttribute:function(t,e){this.attributes[t]=e},getAttribute:function(t){return this.attributes[t]},addParam:function(t,e){this.params[t]=e},getParams:function(){return this.params},addVariable:function(t,e){this.variables[t]=e},getVariable:function(t){return this.variables[t]},getVariables:function(){return this.variables},getVariablePairs:function(){var t,e=new Array,i=this.getVariables();for(t in i)e.push(t+"="+i[t]);return e},getSWFHTML:function(){var t,e,i,r="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){for(e in this.getAttribute("doExpressInstall")&&this.addVariable("MMplayerType","PlugIn"),r='<embed type="application/x-shockwave-flash" src="'+this.getAttribute("swf")+'" width="'+this.getAttribute("width")+'" height="'+this.getAttribute("height")+'"',r+=' id="'+this.getAttribute("id")+'" name="'+this.getAttribute("id")+'" ',t=this.getParams())r+=[e]+'="'+t[e]+'" ';0<(i=this.getVariablePairs().join("&")).length&&(r+='flashvars="'+i+'"'),r+="/>"}else{for(e in this.getAttribute("doExpressInstall")&&this.addVariable("MMplayerType","ActiveX"),r='<object id="'+this.getAttribute("id")+'" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+this.getAttribute("width")+'" height="'+this.getAttribute("height")+'">',r+='<param name="movie" value="'+this.getAttribute("swf")+'" />',t=this.getParams())r+='<param name="'+e+'" value="'+t[e]+'" />';0<(i=this.getVariablePairs().join("&")).length&&(r+='<param name="flashvars" value="'+i+'" />'),r+="</object>"}return r},write:function(t){var e;return this.getAttribute("useExpressInstall")&&(e=new deconcept.PlayerVersion([6,0,65]),this.installedVer.versionIsValid(e)&&!this.installedVer.versionIsValid(this.getAttribute("version"))&&(this.setAttribute("doExpressInstall",!0),this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl"))),document.title=document.title.slice(0,47)+" - Flash Player Installation",this.addVariable("MMdoctitle",document.title))),this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))?(("string"==typeof t?document.getElementById(t):t).innerHTML=this.getSWFHTML(),!0):(""!=this.getAttribute("redirectUrl")&&document.location.replace(this.getAttribute("redirectUrl")),!1)}},deconcept.SWFObjectUtil.getPlayerVersion=function(t,e){var i=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var r=navigator.plugins["Shockwave Flash"];r&&r.description&&(i=new deconcept.PlayerVersion(r.description.replace(/([a-z]|[A-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split(".")))}else{try{for(var n=new ActiveXObject("ShockwaveFlash.ShockwaveFlash"),s=3;null!=n;s++)n=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+s),i=new deconcept.PlayerVersion([s,0,0])}catch(t){}if(t&&i.major>t.major)return i;if(!t||(0!=t.minor||0!=t.rev)&&i.major==t.major||6!=i.major||e)try{i=new deconcept.PlayerVersion(n.GetVariable("$version").split(" ")[1].split(","))}catch(t){}}return i},deconcept.PlayerVersion=function(t){this.major=null!=parseInt(t[0])?parseInt(t[0]):0,this.minor=parseInt(t[1])||0,this.rev=parseInt(t[2])||0},deconcept.PlayerVersion.prototype.versionIsValid=function(t){return!(this.major<t.major)&&(this.major>t.major||!(this.minor<t.minor)&&(this.minor>t.minor||!(this.rev<t.rev)))},deconcept.util={getRequestParameter:function(t){var e=document.location.search||document.location.hash;if(e){var i=e.indexOf(t+"="),t=-1<e.indexOf("&",i)?e.indexOf("&",i):e.length;if(1<e.length&&-1<i)return e.substring(e.indexOf("=",i)+1,t)}return""}},deconcept.SWFObjectUtil.cleanupSWFs=function(){for(var t=document.getElementsByTagName("OBJECT"),e=0;e<t.length;e++)for(var i in t[e])"function"==typeof t[e][i]&&(t[e][i]=null)},"function"==typeof window.onunload?(oldunload=window.onunload,window.onunload=function(){deconcept.SWFObjectUtil.cleanupSWFs(),oldunload()}):window.onunload=deconcept.SWFObjectUtil.cleanupSWFs,null==Array.prototype.push&&(Array.prototype.push=function(t){return this[this.length]=t,this.length});var getQueryParamValue=deconcept.util.getRequestParameter,FlashObject=deconcept.SWFObject,SWFObject=deconcept.SWFObject;

window.hzmr.push("flashdetect:29383330");
} catch (err) {HZ.utils.Logger.sendJsExceptionStackTrace(err)}

/*************  End flashdetect.js  **************/
