Skip to main content

array

array

<!--?php

$nid=51245;

$query_key=mysql_query("select td.name  from node n inner join term_node tn ON n.nid = tn.nid
 LEFT JOIN term_data td ON tn.tid = td.tid where n.nid=$nid and td.vid in ('7')");

while($rows = mysql_fetch_assoc($query_key)) {
 $row .= $rows['name'].", "; 
}
echo $str = rtrim($row,", ");

//$terms = taxonomy_node_get_terms($nid);// get term from nodes
//rsort($terms); //rsort() just sort an array in reverse order
//$myterm = $terms[0]--->
<p>name; //get a value //echo $myterm; ?&gt;</p>
 

Enjoy our work? Help us keep going.

Now in its 75th year, American Heritage relies on contributions from readers like you to survive. You can support this magazine of trusted historical writing and the volunteers that sustain it by donating today.

Donate