


if(  document.getElementById('text-product-desc') ) {

	descText= document.getElementById('text-product-desc') ;
 	pS="";
  		pS += descText.innerHTML  ;

 pS=pS.replace( 'Perfect for:', '<strong>Perfect for:</strong>');
 pS=pS.replace( 'Materials:', '<strong>Materials: </strong>');
 pS=pS.replace( 'Item code:', '<strong>Item code: </strong>');
 pS=pS.replace( 'Size:', '<strong>Size:</strong>');

 descText.innerHTML= pS;





}


if(  document.getElementById('qFindProduct') ) {
		descText= document.getElementById('qFindProduct') ;


 descText = descText.innerHTML.replace('Use keywords to find the product you are looking for.' , 'search our extensive range of lovely things') ;
document.getElementById('qFindProduct').innerHTML = descText;


}



// tidy up the menu
if(  document.getElementById('panel-navigation') ){
	thePanelString = document.getElementById('panel-navigation').innerHTML;
	thePanelString= thePanelString.replace(/&nbsp;-/gi, '');

 	document.getElementById('panel-navigation').innerHTML = '' ;
	document.getElementById('panel-navigation').innerHTML = thePanelString ;

}

// replace the heading fro about us
//  <h1 class="heading-main">About Us</h1>

dHeading2 =  '<h1 class="heading-main">all about iapetus</h1>' ;
dHeading1 =  '<H1 class=heading-main>all about iapetus</H1>' ;
/**

IE 7 renders is like this

<H1 class=heading-main>all about iapetus</H1>


***/

  dBodyText =  document.body.innerHTML ;
  dHeadingpos1 =  dBodyText.indexOf(dHeading1);
  dHeadingpos2 =  dBodyText.indexOf(dHeading2);

	  //alert(dHeadingpos1 + ' ' + dHeadingpos2 );
	  if( (dHeadingpos1 >0) || (dHeadingpos2 >0)) {
	 // dBodyText = dBodyText.replace( dHeading1, '' );
	 // dBodyText = dBodyText.replace( dHeading2, '' );
	// document.body.innerHTML =  dBodyText   ;
	 // document.body.innerHTML = '<form><textarea>'   +  dBodyText   + '</textarea> </form>';
	}



// remove cat heading id = select-category-heading
// /store/department/195/ceramics/
if( document.getElementById('select-category-heading') ) {

	document.getElementById('select-category-heading').innerHTML = '';
	document.getElementById('select-category-heading').height='0';
 }




 //<div  id="customProducts"></div> in the home page content

 if( document.getElementById('panel-newproduct') ) {

	 dNew = document.getElementById('panel-newproduct').innerHTML;
	 document.getElementById('panel-newproduct').innerHTML = '';
	 if( document.getElementById('customProducts'))  {
	 document.getElementById('customProducts').innerHTML =  dNew;
	// alert(   document.getElementById('customProducts').innerHTML)


	 }

}

// hide the worl pay logo

im = document.images.length;
for( x=0 ; x<im; x++ ){

	if( document.images[x].src == 'https://www.worldpay.com/cgenerator/logos/poweredByWorldPay.gif'){
		//alert(x + '  ' + document.images[x].src );

          document.images[x].style.display='none';
          break;

		}


	}


/****  for advanced search labels    ***/

function reWriteByTagName( tagType,  dTag, newValue   ) {
x = document.getElementsByTagName( tagType   ) ;
//alert(x.length);
dValues ='';
  for( j=0; j< x.length ; j++ )  {
  //alert(x[j]);
  if( x[j].innerHTML == dTag     ){
      dValues += x[j].innerHTML  + ' =   '  +  x[j].value + "\n"  ;
       x[j].innerHTML   = newValue ;
    }
  }
}


//rewrite the label tage type in the advanced search page.
reWriteByTagName( 'label',  'Type' , 'Who\'s it for ' ) ;
reWriteByTagName( 'label',  'Department' , 'What do  they like ' ) ;
//hide the keyword search
//document.getElementById('keyword').style.display='none'  ;
//reWriteByTagName( 'label',  'Keywords' , '' ) ;

// Hide the them drop down
if( document.getElementById('theme_dropdown')   ){
 document.getElementById('theme_dropdown').style.display = 'none';
 document.getElementById('theme_dropdown').style.position = 'relative';
 document.getElementById('theme_dropdown').style.visibility = 'hidden';
}
