Magento get product by attribute

For example here we will product by it name

  $collectionss = Mage::getModel('catalog/product')->getCollection()->addAttributeToSelect('*')->addUrlRewrite();

$collectionss->addFieldToFilter(array( array('attribute'=>'name','eq'=>'test'), ))

Get Product By Id


$_newProduct = Mage::getModel('catalog/product')->load($id);