'test_page', 'title' => 'Title of testing page', 'callback' => 'test_page_function', 'access' => user_access('access content'), 'type' => MENU_CALLBACK); } return $items; } function test_page_function(){ if(is_numeric(arg(1))){ return 'test page:'.arg(1); } else{ return 'top of the test page'; } } function test_nodeapi(&$node, $op, $a3 = NULL, $a4 = NULL){ switch($op){ case 'delete': case 'insert': case 'load': case 'prepare': case 'search result': case 'print': case 'submit': case 'update': case 'submit': case 'update index': case 'validate': case 'rss item': break; case 'view': /*print '
';
print_r($node);
print '';
*/
$sql = 'SELECT n.nid, n.title, n.created FROM {node} n WHERE n.status = 1 ORDER BY n.created DESC';
$nodes = db_query_range(db_rewrite_sql($sql), 0, 20);
while ($n = db_fetch_object($nodes)) {
$node->body .= $n->title.'