找出已發佈的,類型為 Page 或 Story 的 node:
<?php
$sql = "SELECT * FROM {node} WHERE status = '%d' AND type IN (".db_placeholders($types, 'varchar').") ";
$r = db_query($sql, array_merge((array)$status, $types));
?>
找出已發佈的,類型為 Page 或 Story 的 node:
<?php
$sql = "SELECT * FROM {node} WHERE status = '%d' AND type IN (".db_placeholders($types, 'varchar').") ";
$r = db_query($sql, array_merge((array)$status, $types));
?>