PageSourceSearch

https://techsposingapore.sg/wp-content/cache/min/1/wp-content/plugins/advanced-iframe/js/ai.js?ver=1782695238

js techsposingapore.sg collected 2026-10-04 22:24:55 UTC 40,441 bytes, 121 lines download raw bytes

1var aiEnableCookie=!1;var aiId='';var aiExtraSpace=0;var accTime=0;var aiReadyCallbacks=(typeof aiReadyCallbacks!=='undefined'&&aiReadyCallbacks instanceof Array)?aiReadyCallbacks:[];function aiResizeIframe(obj,resize_width,resize_min_height){try{if(obj.contentWindow.location.href=='about:blank'){return}
2if(obj.contentWindow.document.body!=null){var oldScrollposition=jQuery(document).scrollTop();obj.height=Number(resize_min_height);obj.style.height=Number(resize_min_height)+'px';var newheight=aiGetIframeHeight(obj);obj.height=newheight;obj.style.height=newheight+'px';if(jQuery('#ai-zoom-div-'+obj.id).length!==0){var zoom=window['zoom_'+obj.id];jQuery('#ai-zoom-div-'+obj.id).css('height',newheight*zoom)}
3if(aiEnableCookie&&aiExtraSpace===0){aiWriteCookie(newheight)}
4jQuery(document).scrollTop(oldScrollposition);if(resize_width==='true'){var newWidth=aiGetIframeWidth(obj);obj.width=newWidth;obj.style.width=newWidth+'px'}
5var fCallback=window['resizeCallback'+obj.id];fCallback();if(window.frameElement!=null){parent.jQuery('iframe').trigger('onload')}}else{setTimeout(function(){aiResizeIframe(obj,resize_width)},100)}}catch(e){if(console&&console.log){console.log('Advanced iframe configuration error: You have enabled the resize of the iframe for pages on the same domain. But you use an iframe page on a different domain. You need to use the external workaround like described in the settings. Also check the next log. There the browser message for this error is displayed.');console.log(e)}}}
6function aiGetIframeHeight(obj){var bodyHeight=Math.max(obj.contentWindow.document.body.scrollHeight,obj.contentWindow.document.body.offsetHeight,obj.contentWindow.document.documentElement.scrollHeight,obj.contentWindow.document.documentElement.offsetHeight);var newheight=bodyHeight+aiExtraSpace;return newheight}
7function aiGetIframeWidth(obj){var oldWidth=obj.width;obj.width=1;obj.style.width='1px';var bodyWidth=Math.max(obj.contentWindow.document.body.scrollWidth,obj.contentWindow.document.body.offsetWidth,obj.contentWindow.document.documentElement.scrollWidth,obj.contentWindow.document.documentElement.offsetWidth);if(bodyWidth!==1){obj.width=bodyWidth;obj.style.width=bodyWidth+'px'}else{obj.width=oldWidth;obj.style.width=oldWidth+'px'}
8return bodyWidth}
9function aiGetParentIframeWidth(obj){if(obj!=null&&jQuery('#'+obj.id).length!==0){return jQuery('#'+obj.id).width()}else{return-1}}
10function aiResizeIframeHeightById(id,nHeight){try{var fCallback=window['resizeCallback'+id];fCallback();var height=parseInt(nHeight,10)+aiExtraSpace;var iframe=document.getElementById(id);var oldScrollposition=jQuery(document).scrollTop();iframe.height=height;iframe.style.height=height+'px';jQuery(document).scrollTop(oldScrollposition);if(aiEnableCookie&&aiExtraSpace===0){aiWriteCookie(height)}
11var parentResizeCall=window['aiExecuteWorkaround_'+id];if(parentResizeCall!=null){parentResizeCall()}}catch(e){if(console&&console.log){console.log('Advanced iframe configuration error: The id of the parent and the external workaround are different! Check your settings.');console.log(e)}}}
12function aiScrollToTop(id,position){if(position==='iframe'){var pos=jQuery('#'+id).position();window.scrollTo(0,pos.top)}else{window.scrollTo(0,0)}}
13function aiWriteCookie(height){var cookieName='ai-last-height';if(aiId!==''){cookieName=cookieName+'-'+aiId}
14var cookieStr=cookieName+'='+height;document.cookie=cookieStr}
15function aiUseCookie(){var cookieName='ai-last-height';if(aiId!==''){cookieName=cookieName+'-'+aiId}
16var allcookies=document.cookie;var cookiearray=allcookies.split(';');for(var i=0;i<cookiearray.length;i++){var name=cookiearray[i].split('=')[0];var value=cookiearray[i].split('=')[1];if(name===cookieName&&value!==null&&ai_is_numeric(value)){var iframe=document.getElementById(aiId);iframe.height=parseInt(value,10);iframe.style.height=value+'px'}}}
17function ai_is_numeric(input){return!isNaN(input)}
18function aiDisableHeight(){jQuery('#additional_height').attr('readonly','readonly');jQuery('#additional_height').val('0')}
19function aiEnableHeight(){jQuery('#additional_height').removeAttr('readonly')}
20function aiShowElementOnly(iframeId,showElement){try{var iframe=jQuery(iframeId).contents().find('body');var selectedBox=iframe.find(showElement).clone(!0,!0);iframe.find('*').not(jQuery('script')).remove();
20iframe.prepend(selectedBox)}catch(e){if(console&&console.log){console.log('Advanced iframe configuration error: You have enabled to show only one element of the iframe for pages on the same domain. But you use an iframe page on a different domain. You need to use the pro version of the external workaround like described in the settings. Also check the next log. There the browser message for this error is displayed.');console.log(e)}}}
21function checkIfValidTarget(evt,elements){var targ;if(!evt){evt=window.event}
22if(evt.target){targ=evt.target}else if(evt.srcElement){targ=evt.srcElement}
23if(targ.nodeType===3){targ=targ.parentNode}
24var parts=elements.split(',');for(var i=0;i<parts.length;++i){var selectorArray=parts[i].split(':');if(selectorArray[0].toLowerCase()===targ.nodeName.toLowerCase()){if(selectorArray.length>1){if(targ.id.toLowerCase().indexOf(selectorArray[1].toLowerCase())!==-1){return!0}}else{return!0}}}
25return!1}
26function openSelectorWindow(url){var local_width=jQuery('#width').val();var local_height=jQuery('#height').val();if(local_width.indexOf('%')>=0||Number(local_width)<900){local_width=900}
27local_width=Number(local_width)+40;if(local_width>(screen.width)){local_width=screen.width}
28if(local_height.indexOf('%')>=0){local_height=screen.height}else{local_height=Number(local_height)+480}
29if(local_height>(screen.height-50)){local_height=screen.height-50}
30var options='width='+local_width+',height='+local_height+',left=0,top=0,resizable=1,scrollbars=1';var popup_window=window.open(url,'',options);popup_window.focus()}
31function openTab(id){jQuery(id).next().show()}
32function aiDisableAiResizeOptions(value){jQuery('#onload_resize_delay').prop('readonly',value);jQuery('input[id=store_height_in_cookie1]:radio').attr('disabled',value);jQuery('input[id=store_height_in_cookie2]:radio').attr('disabled',value);jQuery('#additional_height').prop('readonly',value);jQuery('input[id=onload_resize_width1]:radio').attr('disabled',value);jQuery('input[id=onload_resize_width2]:radio').attr('disabled',value);jQuery('#resize_on_click').prop('readonly',value);jQuery('#resize_on_click_elements').prop('readonly',value);jQuery('#resize_on_ajax').prop('readonly',value);jQuery('input[id=resize_on_ajax_jquery1]:radio').attr('disabled',value);jQuery('input[id=resize_on_ajax_jquery2]:radio').attr('disabled',value)}
33function aiDisablePartOfIframeOptions(value){jQuery('#show_part_of_iframe_x').prop('readonly',value);jQuery('#show_part_of_iframe_y').prop('readonly',value);jQuery('#show_part_of_iframe_height').prop('readonly',value);jQuery('#show_part_of_iframe_width').prop('readonly',value);jQuery('input[id=show_part_of_iframe_allow_scrollbar_horizontal1]:radio').attr('disabled',value);jQuery('input[id=show_part_of_iframe_allow_scrollbar_horizontal2]:radio').attr('disabled',value);jQuery('input[id=show_part_of_iframe_allow_scrollbar_vertical1]:radio').attr('disabled',value);jQuery('input[id=show_part_of_iframe_allow_scrollbar_vertical2]:radio').attr('disabled',value);jQuery('#show_part_of_iframe_next_viewports').prop('readonly',value);jQuery('input[id=show_part_of_iframe_next_viewports_loop1]:radio').attr('disabled',value);jQuery('input[id=show_part_of_iframe_next_viewports_loop2]:radio').attr('disabled',value);jQuery('#show_part_of_iframe_new_window').prop('readonly',value);jQuery('#show_part_of_iframe_new_url').prop('readonly',value);jQuery('input[id=show_part_of_iframe_next_viewports_hide1]:radio').attr('disabled',value);jQuery('input[id=show_part_of_iframe_next_viewports_hide2]:radio').attr('disabled',value);jQuery('#show_part_of_iframe_style').prop('readonly',value);jQuery('input[id=show_part_of_iframe_zoom1]:radio').attr('disabled',value);jQuery('input[id=show_part_of_iframe_zoom2]:radio').attr('disabled',value);jQuery('input[id=show_part_of_iframe_zoom3]:radio').attr('disabled',value)}
34function aiDisableLazyLoadOptions(value){jQuery('#enable_lazy_load_threshold').prop('readonly',value);jQuery('#enable_lazy_load_fadetime').prop('readonly',value);jQuery('input[id=enable_lazy_load_reserve_space1]:radio').attr('disabled',value);jQuery('input[id=enable_lazy_load_reserve_space2]:radio').attr('disabled',value);jQuery('input[id=enable_lazy_load_manual1]:radio').attr('disabled',value);jQuery('input[id=enable_lazy_load_manual2]:radio').attr('disabled',value);jQuery('input[id=enable_lazy_load_manual3]:radio').attr('disabled',value)}
35function aiDisableIframeAsLayerOptions(value){jQuery('input[id=show_iframe_as_layer_full]:radio').attr('disabled',value);jQuery('#show_iframe_as_layer_header_file').prop('readonly',value);jQuery('#show_iframe_as_layer_header_height').prop('readonly',value);jQuery('input[id=show_iframe_as_layer_header_position1]:radio').attr('disabled',value);jQuery('input[id=show_iframe_as_layer_header_position2]:radio').attr('disabled',value);jQuery('input[id=show_iframe_as_layer_full1]:radio').attr('disabled',value);jQuery('input[id=show_iframe_as_layer_full2]:radio').attr('disabled',value);jQuery('input[id=show_iframe_as_layer_full3]:radio').attr('disabled',value);jQuery('input[id=show_iframe_as_layer_keep_content1]:radio').attr('disabled',value);jQuery('input[id=show_iframe_as_layer_keep_content2]:radio').attr('disabled',value)}
36var instance;function initAdminConfiguration(isPro,acc_type){if(jQuery('input[type=radio][name=onload_resize]:checked').val()==='false'){aiDisableAiResizeOptions(!0)}
37jQuery('input[type=radio][name=onload_resize]').click(function(){if(jQuery(this).val()==='true'){jQuery('input
37:radio[name=enable_external_height_workaround]')[1].checked=!0;aiDisableAiResizeOptions(!1)}else{jQuery('#onload_resize_delay').val('');aiDisableAiResizeOptions(!0)}});jQuery('input[type=radio][name=enable_external_height_workaround]').click(function(){if(jQuery(this).val()==='true'){jQuery('input:radio[name=onload_resize]')[1].checked=!0;jQuery('#onload_resize_delay').val('');aiDisableAiResizeOptions(!0)}});if(jQuery('input[type=radio][name=show_part_of_iframe]:checked').val()==='false'){aiDisablePartOfIframeOptions(!0)}
38jQuery('input[type=radio][name=show_part_of_iframe]').click(function(){if(jQuery(this).val()==='false'){aiDisablePartOfIframeOptions(!0)}else{aiDisablePartOfIframeOptions(!1)}});if(jQuery('input[type=radio][name=show_iframe_as_layer]:checked').val()==='false'){aiDisableIframeAsLayerOptions(!0)}
39jQuery('input[type=radio][name=show_iframe_as_layer]').click(function(){if(jQuery(this).val()==='false'){aiDisableIframeAsLayerOptions(!0)}else{aiDisableIframeAsLayerOptions(!1)}});if(jQuery('input[type=radio][name=expert_mode]:checked').val()==='true'){jQuery('.description').css('display','none');jQuery('table.form-table th').css('cursor','pointer');jQuery('table.form-table th').css('padding-top','8px').css('padding-bottom','2px');jQuery('table.form-table td').css('padding-top','5px').css('padding-bottom','5px');jQuery('table.form-table th').click(function(){jQuery('.description').css('display','none');jQuery('.description',jQuery(this).parent()).css('display','block')})}
40jQuery('input[type=radio][name=expert_mode]').click(function(){if(jQuery(this).val()==='false'){jQuery('.description').css('display','block');jQuery('table.form-table th').css('cursor','auto');jQuery('table.form-table th').off('click');jQuery('table.form-table th').css('padding-top','20px').css('padding-bottom','20px');jQuery('table.form-table td').css('padding-top','15px').css('padding-bottom','15px')}else{jQuery('.description').css('display','none');jQuery('table.form-table th').css('cursor','pointer');jQuery('table.form-table th').css('padding-top','8px').css('padding-bottom','2px');jQuery('table.form-table td').css('padding-top','5px').css('padding-bottom','5px');jQuery('table.form-table th').click(function(){jQuery('.description').css('display','none');jQuery('.description',jQuery(this).parent()).css('display','block')})}});jQuery('#accordion').find('h1').click(function(){jQuery(this).next().slideToggle(accTime)}).next().hide();jQuery('#accordion').find('a').click(function(){var hash=jQuery(this).prop('hash');var hash_only='#h1-'+hash.substring(1);jQuery(hash_only).next().show();location.hash=hash_only});if(jQuery('input[type=radio][name=enable_lazy_load_manual]:checked').val()==='false'){jQuery('#enable_lazy_load_manual_element').prop('readonly',!0)}
41jQuery('input[type=radio][name=enable_lazy_load_manual]').click(function(){if(jQuery(this).val()==='false'||jQuery(this).val()==='auto'){jQuery('#enable_lazy_load_manual_element').prop('readonly',!0)}else{jQuery('#enable_lazy_load_manual_element').prop('readonly',!1)}});if(jQuery('input[type=radio][name=enable_lazy_load]:checked').val()==='false'){aiDisableLazyLoadOptions(!0);jQuery('#enable_lazy_load_manual_element').prop('readonly',!0)}
42jQuery('input[type=radio][name=enable_lazy_load]').click(function(){if(jQuery(this).val()==='false'){aiDisableLazyLoadOptions(!0);jQuery('#enable_lazy_load_manual_element').prop('readonly',!0)}else{aiDisableLazyLoadOptions(!1);if(jQuery('input[type=radio][name=enable_lazy_load_manual]:checked').val()==='false'||jQuery('input[type=radio][name=enable_lazy_load_manual]:checked').val()==='auto'){jQuery('#enable_lazy_load_manual_element').prop('readonly',!0)}else{jQuery('#enable_lazy_load_manual_element').prop('readonly',!1)}}});jQuery('.confirmation').on('click',function(){return confirm('Are you sure?')});jQuery('a.post').click(function(e){e.stopPropagation();e.preventDefault();var href=this.href;var parts=href.split('?');var url=parts[0];var params=parts[1].split('&');var pp,inputs='';url+='?'+params[0];for(var i=1,n=params.length;i<n;i++){pp=params[i].split('=');inputs+='<input type="hidden" name="'+pp[0]+'" value="'+pp[1]+'" />'}
43jQuery('body').append('<form action="'+url+'" method="post" id="poster">'+inputs+'</form>');jQuery('#poster').submit()});jQuery('.ai-input-search').keyup(function(e){var searchTerm=jQuery('input.ai-input-search').val().toLowerCase();aiSettingsSearch(searchTerm,acc_type)});jQuery('.ai-input-search').on('click',function(e){setTimeout(function(){var searchTerm=jQuery('input.ai-input-search').val().toLowerCase();aiSettingsSearch(searchTerm,acc_type)},100)});jQuery(document).on('click','.nav-tab-wrapper a',function(){var current_tab=jQuery(this).attr('id');jQuery('section').hide();jQuery('section.'+current_tab).show();jQuery('#current_tab').val(current_tab.substr(4,1));jQuery('.nav-tab').removeClass('nav-tab-active');jQuery(this).addClass('nav-tab-active');jQuery(this).blur();return!1});jQuery(document).on('click','a#external-workaround-link',function(){jQuery('.external-workaround').click();jQuery(document).scrollTop(0);return!1});jQuery(document).on('click','a#resize-same-link',function(){jQuery('.advanced-settings-tab').click();location.hash='rt';return!1});jQuery(document).on('click','a.jquery-help-link',function(){jQuery('.help-tab').click();jQuery('#jquery-help').show();location.hash='jqh';showHeader();return!1});jQuery(document).on('click','a#browser-detection-link',function(){jQuery('.help-tab').click();jQuery('#browser-help').show();location.hash='browser-detection-id';showHeader();return!1});jQuery(document).on('click','a.howto-id-link',function(){jQuery('.help-tab').click();location.hash='how-id';showHeader();return!1});jQuery(document).on('click','.modifycontent-link',function(){jQuery('.advanced-settings-tab').click();jQuery('#h1-mi').next().show();location.hash='#mi-id';showHeader();return!1});jQuery(document).on('click','a.link-external-domain',function(){location.hash='#h-external-domain';showHeader();return!1});jQuery(document).on('click','a#user-help-link',function(){jQuery('#user-help').css('display','block');return!1});jQuery(document).on('click','a#user-meta-link',function(){jQuery('#meta-help').css('display','block');return!1});jQuery(document).on('click','#ai-selector-help-link',function(){jQuery('#ai-selector-help').slideDown(1000);return!1});jQuery(document).on('click','.ai-selector-help-link-move',function(){location.hash='#ai-selector-help-link';showHeader();jQuery('#ai-selector-help').show('slow');return!1});jQuery(document).on('click','a.post-message-help-link',function(){jQuery('.help-tab').click();location.hash='com-post-message';showHeader();return!1});jQuery('#ai_form').submit(function(){var openSections='';jQuery('#accordion').find('div:visible').each(function(){var $this=jQuery(this);var open=$this.prev('h1').attr('id');if(open!==undefined){if(openSections!==''){openSections+=','}
44openSections+='#'+open}});jQuery('#current_open_sections').val(openSections);setAiScrollposition()})}
45function aiSettingsSearch(searchTerm,acc_type){var found=0;if(searchTerm!==''){jQuery('#ai p').not('.form-table p').hide();jQuery('#ai ul').not('.form-table ul').hide();jQuery('#ai ol').not('.form-table ol').hide();if(acc_type!=='false'){jQuery('#ai h1').not('.show-always').hide();jQuery('#ai #accordion').attr('id','acc');jQuery('#ai #acc > div').show();jQuery('#ai #spacer-div').show()}
46jQuery('#ai h2,#ai .icon_ai,#ai h3,#ai h4').not('.show-always').hide();jQuery('#ai .form-table').addClass('ai-remove-margin');jQuery('#ai hr, .signup_account_container, .config-file-block').hide();jQuery('#ai .hide-always').hide();jQuery('#ai .hide-search').hide()}else{jQuery('#ai p').not('.form-table p').show();jQuery('#ai section .ai-anchor').show();jQuery('#ai ul').not('.form-table ul').show();jQuery('#ai ol').not('.form-table ol').show();if(acc_type!=='false'){jQuery('#ai h1').not('.show-always').show();jQuery('#ai #acc').attr('id','accordion');jQuery('#ai #accordion > div').hide();jQuery('#ai #spacer-div').hide()}
47jQuery('#ai h2,#ai .icon_ai,#ai h3,#ai h4').not('.show-always').show();jQuery('#ai .form-table').removeClass('ai-remove-margin');jQuery('#ai hr, .signup_account_container, .config-file-block').show();jQuery('#ai .sub-domain-container').show();jQuery('#ai .hide-search').show();jQuery('#ai .hide-always').hide()}
48jQuery('#ai .mark-tab-header').removeClass('mark-tab-header');var firstHit='';jQuery('#ai tr').each(function(){var $this=jQuery(this);var valueLabel=$this.find('th').text();var valueDescription=$this.find('p.description').text();valueLabel=(valueLabel!==undefined)?valueLabel.toLowerCase():'XXXXXXX';
48valueDescription=(valueDescription!==undefined)?valueDescription.toLowerCase():'XXXXXXX';if(valueLabel.indexOf(searchTerm)===-1&&valueDescription.indexOf(searchTerm)===-1){$this.addClass('hide-setting')}else{$this.closest('table').prevAll('h2:first').show();$this.closest('table').prevAll('#ai .icon_ai:first').show();$this.closest('table').nextAll('p.button-submit:first').show();$this.removeClass('hide-setting');$this.closest('.hide-search').show();if(searchTerm.length>2){var header_id=$this.closest('section').attr('class');if(header_id!==undefined){jQuery('#'+header_id).addClass('mark-tab-header');if(firstHit===''){firstHit=header_id}}}
49found++}});if(found===0){jQuery('#ai-input-search-result').show();jQuery('#ai .mark-tab-header').removeClass('mark-tab-header')}else{jQuery('#ai-input-search-result').hide();instance&&instance.revert();if(searchTerm!==''&&searchTerm.length>2){var regex=RegExp(searchTerm,'gi');instance=findAndReplaceDOMText(document.getElementById('tab_wrapper'),{find:regex,wrap:'em'})}
50jQuery('#'+firstHit).click()}}
51function aiResizeIframeRatio(obj,ratio){var width=jQuery('#'+obj.id).width();var valueRatio=parseFloat(ratio.replace(',','.'));var newHeight=Math.ceil(width*valueRatio);obj.height=newHeight;obj.style.height=newHeight+'px'}
52function aiGenerateShortcode(){var output='[advanced_iframe ';if(jQuery('#securitykey').val()!==''){output+='securitykey="'+jQuery('#securitykey').val()+'" '}
53output+='use_shortcode_attributes_only="true" ';var include_html_val=jQuery('#include_html').val();var include_url_val=jQuery('#include_url').val();var document_domain_add=jQuery('#document_domain_add').val();if(include_html_val===undefined||(include_html_val===''&&include_url_val==='')){var src=jQuery('#src').val();if(src===''){alert('Required url is missing.')}else{output+='src="'+src+'" '}
54output+=aiGenerateTextShortcode('width');output+=aiGenerateTextShortcode('height');output+=aiGenerateRadioShortcode('scrolling','none');output+=aiGenerateRadioShortcode('enable_ios_mobile_scolling','false');output+=aiGenerateTextShortcode('marginwidth');output+=aiGenerateTextShortcode('marginheight');output+=aiGenerateTextShortcode('frameborder');output+=aiGenerateRadioShortcode('transparency','true');output+=aiGenerateTextShortcode('class');output+=aiGenerateTextShortcode('style');output+=aiGenerateTextShortcode('id');output+=aiGenerateTextShortcode('name');output+=aiGenerateRadioShortcode('allowfullscreen','false');output+=aiGenerateTextShortcode('url_forward_parameter');output+=aiGenerateTextShortcode('map_parameter_to_url');output+=aiGenerateRadioShortcode('add_iframe_url_as_param','false');output+=aiGenerateTextShortcode('add_iframe_url_as_param_prefix');output+=aiGenerateRadioShortcode('onload_scroll_top','false');output+=aiGenerateRadioShortcode('hide_page_until_loaded','false');output+=aiGenerateRadioShortcode('show_iframe_loader','false');output+=aiGenerateTextShortcode('hide_content_until_iframe_color');output+=aiGenerateTextShortcode('iframe_zoom');output+=aiGenerateRadioShortcode('iframe_zoom_ie8','false');output+=aiGenerateRadioShortcode('use_zoom_absolute_fix','false');output+=aiGenerateRadioShortcode('auto_zoom','false');output+=aiGenerateTextShortcode('auto_zoom_by_ratio');output+=aiGenerateRadioShortcode('enable_responsive_iframe','false');output+=aiGenerateTextShortcode('iframe_height_ratio');output+=aiGenerateRadioShortcode('enable_lazy_load','false');output+=aiGenerateTextShortcodeWithDefault('enable_lazy_load_threshold','3000');output+=aiGenerateRadioShortcode('enable_lazy_load_reserve_space','true');output+=aiGenerateTextShortcode('enable_lazy_load_fadetime');
54output+=aiGenerateRadioShortcode('enable_lazy_load_manual','false');output+=aiGenerateRadioShortcode('enable_lazy_load_manual_element','false');output+=aiGenerateTextShortcode('reload_interval');output+=aiGenerateTextShortcode('hide_elements');output+=aiGenerateTextShortcode('content_id');output+=aiGenerateTextShortcode('content_styles');output+=aiGenerateTextShortcode('parent_content_css');output+=aiGenerateRadioShortcode('add_css_class_parent','false');output+=aiGenerateTextShortcode('change_parent_links_target');output+=aiGenerateRadioShortcode('show_iframe_as_layer','false');output+=aiGenerateRadioShortcode('show_iframe_as_layer_full','false');output+=aiGenerateTextShortcode('show_iframe_as_layer_header_file');output+=aiGenerateTextShortcodeWithDefault('show_iframe_as_layer_header_height','100');output+=aiGenerateRadioShortcode('show_iframe_as_layer_header_position','top');output+=aiGenerateRadioShortcode('show_iframe_as_layer_keep_content','true');var showPartOfIframe=aiGenerateRadioShortcode('show_part_of_iframe','false');output+=showPartOfIframe;if(showPartOfIframe!==''){output+=aiGenerateTextShortcodeWithDefault('show_part_of_iframe_x',-1);output+=aiGenerateTextShortcodeWithDefault('show_part_of_iframe_y',-1);output+=aiGenerateTextShortcode('show_part_of_iframe_width');output+=aiGenerateTextShortcode('show_part_of_iframe_height');output+=aiGenerateRadioShortcode('show_part_of_iframe_allow_scrollbar_horizontal','false');output+=aiGenerateRadioShortcode('show_part_of_iframe_allow_scrollbar_vertical','false');output+=aiGenerateTextShortcode('show_part_of_iframe_style');output+=aiGenerateRadioShortcode('show_part_of_iframe_zoom','false');output+=aiGenerateTextShortcode('show_part_of_iframe_next_viewports');output+=aiGenerateRadioShortcode('show_part_of_iframe_next_viewports_loop','false');output+=aiGenerateTextShortcode('show_part_of_iframe_new_window');output+=aiGenerateTextShortcode('show_part_of_iframe_new_url');output+=aiGenerateRadioShortcode('show_part_of_iframe_next_viewports_hide','false')}
55output+=aiGenerateTextShortcode('hide_part_of_iframe');output+=aiGenerateRadioShortcode('add_css_class_iframe','false');output+=aiGenerateTextShortcode('iframe_hide_elements');output+=aiGenerateTextShortcode('onload_show_element_only');output+=aiGenerateTextShortcode('iframe_content_id');output+=aiGenerateTextShortcode('iframe_content_styles');output+=aiGenerateTextShortcode('iframe_content_css');output+=aiGenerateTextShortcode('change_iframe_links');output+=aiGenerateTextShortcode('change_iframe_links_target');output+=aiGenerateTextShortcode('onload');output+=aiGenerateRadioShortcode('onload_resize','false');output+=aiGenerateTextShortcode('onload_resize_delay');output+=aiGenerateRadioShortcode('store_height_in_cookie','false');output+=aiGenerateTextShortcode('additional_height');output+=aiGenerateRadioShortcode('onload_resize_width','false');output+=aiGenerateTextShortcode('resize_on_ajax');output+=aiGenerateRadioShortcode('resize_on_ajax_jquery','true');output+=aiGenerateTextShortcode('resize_on_click');output+=aiGenerateTextShortcodeWithDefault('resize_on_click_elements','a');output+=aiGenerateTextShortcode('resize_on_element_resize');output+=aiGenerateTextShortcodeWithDefault('resize_on_element_resize_delay','250');output+=aiGenerateTextShortcode('tab_hidden');output+=aiGenerateTextShortcode('tab_visible');output+=aiGenerateRadioShortcode('add_document_domain','false');if(document_domain_add==='true'){output+=aiGenerateTextShortcode('document_domain')}
56output+=aiGenerateRadioShortcode('enable_external_height_workaround','external');output+=aiGenerateRadioShortcode('hide_page_until_loaded_external','false');output+=aiGenerateTextShortcode('pass_id_by_url');output+=aiGenerateRadioShortcode('multi_domain_enabled','false');output+=aiGenerateRadioShortcode('use_post_message','false');output+=aiGenerateTextShortcode('additional_css');output+=aiGenerateTextShortcode('additional_js');output+=aiGenerateTextShortcode('additional_js_file_iframe');output+=aiGenerateTextShortcode('additional_css_file_iframe')}else{if(include_html_val===''){output+=aiGenerateTextShortcode('include_url');output+=aiGenerateTextShortcode('include_content');output+=aiGenerateTextShortcode('include_height');output+=aiGenerateTextShortcode('include_fade');output+=aiGenerateRadioShortcode('include_hide_page_until_loaded','false')}else{output+=aiGenerateTextShortcode('include_html')}}
57output+=aiGenerateRadioShortcode('debug_js','false');output+=']';jQuery('#gen-shortcode').html(output)}
58function aiGenerateTextShortcodeWithDefault(field,defaultValue){var output='';var value=jQuery('#'+field);var val=value.val();if(value.length>0&&val!==''&&val!==defaultValue){output=field+'="'+val+'" '}
59return output}
60function aiGenerateTextShortcode(field){var output='';var value=jQuery('#'+field);var val=value.val();if(value.length>0&&val!==''&&val!=='0'){output=field+'="'+val+'" '}
61return output}
62function aiGenerateRadioShortcode(field,defaultValue){var output='';
62var value=jQuery('input:radio[name='+field+']:checked');var val=value.val();if(value.length>0&&val!==defaultValue){output+=field+'="'+val+'" '}
63return output}
64function aiAddCssClassAllParents(element){var parents=jQuery(element).parentsUntil('html');var ai_class='ai-class-';for(var i=0;i<parents.length;i++){var id=jQuery(parents[i]).attr('id');if(typeof id!=='undefined'){if(id.indexOf('ai-')!==0){jQuery(parents[i]).addClass(ai_class+id)}}else{jQuery(parents[i]).addClass(ai_class+i)}}}
65function aiAutoZoomExternalHeight(id,width,height,responsive){var parentWidth=aiAutoZoomExternal(id,width,responsive);var zoomRatio=window['zoom_'+id];var oldScrollposition=jQuery(document).scrollTop();var newHeight=Math.ceil(height*zoomRatio);jQuery('#ai-zoom-div-'+id).css('height',newHeight);jQuery(document).scrollTop(oldScrollposition);return parentWidth}
66function aiAutoZoomExternal(id,width,responsive){var obj=document.getElementById(id);var objAround=document.getElementById('ai-zoom-div-'+id);var jObj=jQuery('#'+id);if(responsive==='true'){jObj.css('max-width','100%')}
67var iframeWidth=width;var parentWidth=aiGetParentIframeWidth(obj);if(parentWidth===iframeWidth){parentWidth=aiGetParentIframeWidth(objAround)}
68var zoomRatio=parentWidth/iframeWidth;var zoomRatioRounded=Math.floor(zoomRatio*100)/100;if(zoomRatioRounded>1){zoomRatioRounded=1}
69setZoom(id,zoomRatioRounded);window['zoom_'+id]=zoomRatioRounded;jObj.width(iframeWidth).css('max-width','none');return parentWidth}
70function aiAutoZoom(id,responsive,ratio){var parts=ratio.split('|');ratio=parts[0];var width=-1;if(parts.length!==1){width=parts[1]}
71var obj=document.getElementById(id);var iframeWidth;if(width===-1){obj.width=1;obj.style.width='1px';iframeWidth=aiGetIframeWidth(obj);obj.width=iframeWidth;obj.style.width=iframeWidth+'px'}else{iframeWidth=width}
72var parentWidth=aiAutoZoomExternal(id,iframeWidth,responsive);if(ratio===''){aiResizeIframe(obj,!1)}else{var newheight=Math.ceil(iframeWidth*ratio);obj.height=newheight;obj.style.height=newheight+'px';if(jQuery('#ai-zoom-div-'+obj.id).length!==0){var zoom=window['zoom_'+obj.id];jQuery('#ai-zoom-div-'+obj.id).css('height',Math.ceil(newheight*zoom))}}
73return parentWidth}
74function setZoom(id,zoom){var obj=jQuery('#'+id);if(aiIsIe8===!0){obj.css('-ms-zoom',zoom)}
75obj.css({'-ms-transform':'scale('+zoom+')','-moz-transform':'scale('+zoom+')','-o-transform':'scale('+zoom+')','-webkit-transform':'scale('+zoom+')','transform':'scale('+zoom+')'})}
76function aiAutoZoomViewport(id,full){var viewport_div=jQuery(id);var outer_div=viewport_div.parent();var counter=0;while(outer_div.is('p')||(outer_div.attr('id')!==undefined&&outer_div.attr('id').indexOf('ai-')===0)){outer_div=outer_div.parent();if(counter++>10){alert('Unexpected div structure. Please disable the zoom.');break}}
77var viewport_div_width=viewport_div.width();var outer_div_width=outer_div.width();var viewport_div_height=viewport_div.height();var zoom=outer_div_width/viewport_div_width;if(full==='true'&&zoom>1){zoom=1}
78setZoom(viewport_div.attr('id'),zoom);var margin_left=-Math.round((viewport_div_width-viewport_div_width*zoom)/2);var margin_top=-Math.round((viewport_div_height-viewport_div_height*zoom)/2);viewport_div.css({'margin-left':margin_left+'px','margin-right':margin_left+'px','margin-top':margin_top+'px','margin-bottom':margin_top+'px'})}
79function resetAiSettings(){jQuery('#action').val('reset')}
80function aiCheckInputNumber(inputField){inputField.value=inputField.value.split(' ').join('');var f=inputField.value;if(inputField.value===''){return}
81var match=f.match(/^(\-){0,1}([\d\.])+(px|%|em|pt)?(\-|\+){0,1}([\d\.]){0,7}(px|%|em|pt)?$/);if(!match){alert('Please check the value you have entered. Only numbers with a dot or with an optional px, %, em or pt are allowed.');setTimeout(function(){inputField.focus()},10)}}
82function aiCheckInputNumberOnly(inputField){inputField.value=inputField.value.split(' ').join('');var f=inputField.value;if(inputField.value===''){inputField.value='0';return}
83var match=f.match(/^(\-){0,1}([\d\.])+$/);if(!match){alert('Please check the value you have entered. Only numbers without a dot or optional px, %, em or pt are allowed.');setTimeout(function(){inputField.focus()},10)}}
84function showHeader(){var y=jQuery(window).scrollTop();jQuery(window).scrollTop(y-40)}
85function setAiScrollposition(){var scrollposition=jQuery(document).scrollTop();jQuery('#scrollposition').val(scrollposition)}
86function resetShowPartOfAnIframe(id){jQuery('#'+id).css('top','0px').css('left','0px').css('position','static');jQuery('#ai-div-'+id).css('width','auto').css('height','auto').css('overflow','auto').css('position','static')}
87function ai_showLayerIframe(event,id,path,hide_until_loaded,show_loading_icon,keep,reload){keep=(keep===undefined)?!1:keep;reload=(reload===undefined)?!0:reload;var layer_id='#'+id;jQuery('#ai-zoom-div-'+id).show();if(reload&&hide_until_loaded==='true'){jQuery(layer_id).css('visibility','hidden')}
88jQuery(layer_id).show();if(jQuery('#ai-layer-div-'+id).length){layer_id='#ai-layer-div-'+id;jQuery(layer_id).show()}
89jQuery('body').css('overflow','hidden');jQuery('html').css('overflow-y','visible');jQuery('body').append('<img id="ai_backlink" src="'+path+'close.png" style="z-index:100005;position:fixed;top:0;right:0;cursor:pointer" />');var icon='<!-- -->';if(reload&&show_loading_icon==='true'){icon='<div id="ai-div-loader-global" style="position: fixed;z-index:100004;margin-left:-33px;left: 50%;top:50%;margin-top:-33px"><img src="'+path+'loader.gif" width="66" height="66" title="Loading" alt="Loading"></div>'}
90jQuery(layer_id).parent().append('<div id="ai_backlayer" style="z-index:100001;position:fixed;top:0;left:0;width:100%;height:100%;background-color: rgba(50,50,50,0.5);overflow:hidden;cursor:pointer"><!-- --></div>'+icon);jQuery('#ai_backlink, #ai_backlayer').click(function(){ai_hideLayerIframe(id,keep)});if(!reload){event.preventDefault();event.stopPropagation()}}
91function ai_hideLayerIframe(id,keep){jQuery('#'+id).hide();if(!keep){jQuery('#'+id).attr('src','about:blank');ai_layer_iframe_hrefs[id]='about:blank'}
92jQuery('#ai-zoom-div-'+id).hide();jQuery('#ai-layer-div-'+id).hide();jQuery('#ai_backlink').remove();jQuery('#ai_backlayer').remove();jQuery('#ai-div-loader-global').remove();jQuery('body').css('overflow','auto');jQuery('html').css('overflow-y','scroll')}
93var ai_layer_iframe_hrefs=[];function ai_checkReload(link,id){var iframe_src;if(typeof ai_layer_iframe_hrefs[id]==='undefined'){iframe_src=jQuery('#'+id).attr('src')}else{iframe_src=ai_layer_iframe_hrefs[id]}
94var link_href=jQuery(link).attr('href');
94ai_layer_iframe_hrefs[id]=link_href;return(iframe_src!==link_href)}
95function aiChangeUrlParam(loc,param,orig,prefix){var newUrl;if(loc!==encodeURIComponent(orig)){newUrl=aiSetGetParameter(param,loc);var removeProtocol=!0;if(prefix){var repUrl=newUrl.replace(prefix,'');if(repUrl===newUrl){removeProtocol=!1}
96newUrl=repUrl}
97if(removeProtocol){newUrl=newUrl.replace('http%3A%2F%2F','');if(window.location.href.toLowerCase().startsWith("http:")){newUrl=newUrl.replace('https%3A%2F%2F','')}else{newUrl=newUrl.replace('https%3A%2F%2F','s|')}}}else{var fullUrl=window.location.href;newUrl=aiRemoveURLParameter(fullUrl,param)}
98if(aiSupportsHistoryApi()){newUrl=newUrl.replace(/%2F/g,'/');window.history.pushState({},'',newUrl);window.onpopstate=function(event){if(event&&event.state){window.history.back()}}}}
99function aiSupportsHistoryApi(){return!!(window.history&&history.pushState)}
100function aigetIframeLocation(id){try{var location=document.getElementById(id).contentWindow.location;return encodeURIComponent(location)}catch(e){if(console&&console.log){console.log('Advanced iframe configuration error: You have enabled to add the url to the url on the same domain. But you use an iframe page on a different domain. You need to use the pro version of the external workaround like described in the settings. Also check the next log. There the browser message for this error is displayed.');console.log(e)}}}
101function aiSetGetParameter(paramName,paramValue){var url=window.location.href;var splitAtAnchor=url.split('#');url=splitAtAnchor[0];var anchor=typeof splitAtAnchor[1]==='undefined'?'':'#'+splitAtAnchor[1];if(url.indexOf(paramName+'=')>=0){var prefix=url.substring(0,url.indexOf(paramName));var suffix=url.substring(url.indexOf(paramName));suffix=suffix.substring(suffix.indexOf('=')+1);suffix=(suffix.indexOf('&')>=0)?suffix.substring(suffix.indexOf('&')):'';url=prefix+paramName+'='+paramValue+suffix}else{if(url.indexOf('?')<0){url+='?'+paramName+'='+paramValue}else{url+='&'+paramName+'='+paramValue}}
102return url+anchor}
103function aiRemoveURLParameter(url,parameter){var urlparts=url.split('?');if(urlparts.length>=2){var prefix=encodeURIComponent(parameter)+'=';var pars=urlparts[1].split(/[&;]/g);for(var i=pars.length;i-->0;){if(pars[i].lastIndexOf(prefix,0)!==-1){pars.splice(i,1)}}
104if(pars.length!==0){url=urlparts[0]+'?'+pars.join('&')}else{url=urlparts[0]}
105return url}else{return url}}
106function aiAddCss(id,css){css=decodeURIComponent(css.replace(/\+/g,'%20'));var body=jQuery(id).contents().find('body');var s=document.createElement('style');s.setAttribute('type','text/css');if(s.styleSheet){s.styleSheet.cssText=css}else{s.appendChild(document.createTextNode(css))}
107body.append(s)}
108function aiAddCssFile(id,filename){var body=jQuery(id).contents().find('body');var link=document.createElement('link');link.rel='stylesheet';link.type='text/css';link.href=filename;body.append(link)}
109function aiAddJsFile(id,filename){jQuery.ajaxSetup({cache:!0});var body=jQuery(id).contents().find('body');var script=document.createElement('script');script.type='text/javascript';script.src=filename;body.append(script)}
110function aiPresetFullscreen(){jQuery('#style').val('position:fixed;z-index:9000;top:0px;left:0px;margin:0px');jQuery('#width').val('100%');jQuery('#height').val('100%');jQuery('#content_id').val('html,body');jQuery('#content_styles').val('overflow:hidden');jQuery('#hide_content_until_iframe_color').val('#ffffff')}
111jQuery(document).ready(function(){jQuery.each(aiReadyCallbacks,function(index,callback){callback()});jQuery('#checkIframes').on('click',function(){jQuery(this).addClass('disabled');jQuery('.ai-spinner').css('display','inline-table');setTimeout(ai_disableCheckIframes,200)});var moved=!1;jQuery('#aiDebugDivTotal').mousedown(function(){moved=!1}).mousemove(function(){moved=!0}).mouseup(function(event){if(!moved){var elem=jQuery('#aiDebugDiv');if(Math.floor(elem.height())>'300'){elem.height('38px')}else{elem.height('400px')}}});if(typeof ai_show_id_only!=='undefined'){if(jQuery('#'+ai_show_id_only).length===0){alert('The element with the id "'+ai_show_id_only+'" cannot be found. Please check your configuration.')}else{var element=jQuery('#'+ai_show_id_only);element.siblings().hide();var parents=element.parents();parents.siblings().hide();parents.css('padding','0px').css('margin','0px');if(parent===top){var elementRaw=element[0];var newHeightRaw=Math.max(elementRaw.scrollHeight,elementRaw.offsetHeight);var newHeight=parseInt(newHeightRaw,10);var data={'aitype':'height','height':newHeight,'id':ai_show_id_only};var json_data=JSON.stringify(data);parent.postMessage(json_data,'*')}}}});function ai_disableCheckIframes(){jQuery('#checkIframes').prop('disabled','disabled')}
112function gup(name,url){if(!url){url=location.href}
113name=name.replace(/[\[]/,'\\\[').replace(/[\]]/,'\\\]');var regexS='[\\?&]'+name+'=([^&#]*)';var regex=new RegExp(regexS);var results=regex.exec(url);return results==null?null:results[1]}
114function aiProcessMessage(event,id,debug){var jsObject;try{var jsObject=JSON.parse(event.data)}catch(e){if(debug==='debug'&&console&&console.log){console.log('The received message cannot be parsed and seems not to belong to advanced iframe pro. Please disable the postMessage debug mode if this o.k. and that this message is not shown anymore.');console.log(e)}
115var jsObject=event.data}
116try{if(jsObject.hasOwnProperty('aitype')){if(id===jsObject.id){var type=jsObject.aitype;if(type==='debug'){aiProcessDebug(jsObject)}else{if(type==='height'){aiProcessHeight(jsObject)}else if(type==='show'){aiProcessShow(jsObject)}
117for(var key in jsObject.data){if(jsObject.data.hasOwnProperty(key)){jQuery(key).html(jsObject.data[key])}}}}}}catch(e){if(debug==='debug'&&console&&console.log){console.log('The received message cannot be parsed and seems not to belong to advanced iframe pro. Please disable the postMessage debug mode if this o.k. and that this message is not shown anymore.');console.log(e)}}}
118function aiProcessDebug(jsObject){var debugData=jsObject.data;if(jQuery('#aiDebugDiv').length!==0){jQuery('#aiDebugDiv').append('<p class="ai-debug-remote"> r: '+debugData+'</p>')}}
119function aiProcessHeight(jsObject){var nHeight=jsObject.height;var nWidth=jsObject.width;var id=jsObject.id;if(nHeight!=null){try{var loc=jsObject.loc;if(loc!=null){aiChangeUrl(loc)}
120if(id!=null){var iHeight=parseInt(nHeight,10);var iWidth=parseInt(nWidth,10);aiResizeIframeHeightId(iHeight,iWidth,id);aiShowIframeId(id)}else{alert('Please update the ai_external.js to the current version.')}}catch(e){if(console&&console.log){console.log(e)}}}}
121function aiProcessShow(jsObject){var id=jsObject.id;try{aiShowIframeId(id)}catch(e){if(console&&console.log){console.log(e)}}}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.