how do i create a new link in node.tpl.php by preprocess function in drupal? I have content type in which I have two or three links .In node.tpl.php, all links are displaying from a single variable "$links" in node.tpl.php. i want to remove one particular link from the "$links" variable by preprocess function and assign that link to a new variables , so i can display it where ever I want.

I created a preprocess function  to implement it

function sample_preprocess_node(&amp;$variables){
  if($variables['type']="product"){
    $node=$variables['node'];
    $create_review=array();
    $create_review=$node-&gt;links['review_field_product_review'];
    $variables['create_review']=$create_review;
    unset($node-&gt;links['shopping_review_field_shopping_product_review']);
  }
}


and I pasted the following code in node.tpl.php

print $create_review; 


It displays "array" in product page and that particular link is not removed from the variable ($links) in node.tpl.php

Can you tell me how to remove the particular link from the "$link " variable in node.tpl.php and display it by another variable in node.tpl.php?
This line will always return true, since you are assigning a value with the '=' operator:

if($variables['type']="product"){


This should be a comparison, so use '==':

if($variables['type']=="product"){