var objs=document.getElementsByTagName("title")
for(var i=0;i<objs.length;i++)
{
   if(objs[i].text==x)
   {
       alert("相等")
   }
}