function formatIFRAMECells1($oDom)
{
$oXpath = new DOMXpath($oDom);
$oElements = $oXpath->query("//td[@class='tditem']");
//Remove the TD element to the right of the logo cell. This xpath query finds the following TD element:
// <td bgcolor="#FFFFFF" height="2" class="tditem">
//
// Only remove it if it's also followed by:
//<div align="left"><img src="http://www.mobiles4everyone.com/images/horizontallineplain.jpg" width="100%" height="1"></div>
if (!is_null($oElements))
{
foreach ($oElements as $oElement)
{
if($oElement->hasChildNodes())
{
$oChildren = $oElement->childNodes;
for($i=0;$i<$oChildren->length;$i++)
{
$oChild = $oChildren->item($i);
if($oChild->nodeName == "div")
{
if($oChild->hasChildNodes())
{
$oDivChild = $oChild->firstChild;
if($oDivChild->nodeName == "img")
{
$oElement->parentNode->removeChild($oElement);
break;
}
}
}
}
}
}
}
return $oDom;
}