';if(typeof response.data!=="undefined"){if(typeof response.data.top_text!=="undefined"&&response.data.top_text){html+='
'+response.data.top_text+"
"}if(typeof response.data.notices!=="undefined"){$.each(response.data.notices,function(i,notice){html+='
'+notice+"
"})}if(typeof response.data.top_results!=="undefined"){$.each(response.data.top_results,function(i,topResults){var topResultsName=i;if(typeof topResults!=="undefined"&&topResults.length>0){$.each(topResults,function(i,topResult){var linkData=typeof topResult.link_data!=="undefined"?topResult.link_data:"";html+='
';html+='
'+topResult.name+"";html+='
';html+='';html+='';if(typeof topResult.heading!=="undefined"&&topResult.heading){html+=''+topResult.heading+""}html+=topResult.name;html+="";html+="";if(typeof topResult.content!=="undefined"&&topResult.content){html+=''+topResult.content+""}html+="";html+="
"})}})}}if(typeof response.tax!=="undefined"){$.each(response.tax,function(i,taxes){taxName=i;if(typeof taxes!=="undefined"&&taxes.length>0){$.each(taxes,function(i,taxitem){resultNum++;html+='
';html+='
'+taxitem.name+"";html+='
';html+='';html+='';if(typeof taxitem.heading!=="undefined"&&taxitem.heading){html+=''+taxitem.heading+""}html+=taxitem.name;if(taxitem.count){html+=' ('+taxitem.count+")"}if(typeof taxitem.hierarchy!=="undefined"&&taxitem.hierarchy){html+=''+taxitem.hierarchy+""}html+="";html+="";if(typeof taxitem.excerpt!=="undefined"&&taxitem.excerpt){html+=''+taxitem.excerpt+""}html+="";html+="
"})}})}if(typeof response.products!=="undefined"&&response.products.length>0){$.each(response.products,function(i,result){resultNum++;var isOnSale=result.on_sale?" on-sale":"";html+='
';html+='
'+result.title.replace(/<[^>]*>/g,"")+"";if(result.image){html+='
';html+='
';html+=""}html+='
';html+='';html+='';html+=result.title;if(result.featured){html+=''}html+="";if(result.price){html+=''+result.price+""}html+="";if(result.stock_status){var statusClass=result.stock_status.status?"in":"out";html+='';html+=result.stock_status.text;html+=""}if(result.sku){html+=''+translate.sku+result.sku+""}if(result.excerpt){html+=''+result.excerpt+""}if(typeof result.categories!=="undefined"&&result.categories){html+=''+result.categories+""}html+="";if(result.on_sale){html+='
';html+=''+translate.sale+"";html+=""}html+="
"});if(d.showMore&&d.showPage){html+='
'+translate.showmore+""}}if(!resultNum){methods.createAndDispatchEvent(document,"awsNoResults",{term:searchFor,instance:instance,form:self,data:d});html+='
'+translate.noresults+""}html+="