Come together with the global Drupal community in Rotterdam, 28 Sept – 1 Oct 2026. Sessions, contribution, connection, and Early Bird savings until 8 June.
the code below displays the last 10 nodes in a blog ---- blog could be replace with any node creating module ie story weblink ex ...
/**
* the following displays a list of the 10 most recent weblog titles
* and links to the full weblogs. If you want to increase/reduce
* the number of titles displayed..simply change $listlength value
*
* This php snippet works with drupal 4.6.
*
*/
$listlength="10";
$output = node_title_list(db_query_range(db_rewrite_sql("SELECT n.nid, n.title, n.created FROM {node} n WHERE n.type = 'blog' AND n.status = 1 ORDER BY n.created DESC"), 0, $listlength));
print $output;
Right after posting my original question, I remembered this could be a use for taxonomy. I simply created a term for "headline", pointed users to that taxonomy and now have real-time updates of nodes on a non-front page.
Comments
Yes
Yes you can.
They probably want to know
They probably want to know how too!
Great...now
How do I do this?
Wi-Fi Daily
Easy create a new page and
Easy create a new page and assign a path to it ie
latest_stories
enable php code
and add one of the snippets to it hey presto nodes on other pages
http://drupal.org/node/23220
the code below displays the last 10 nodes in a blog ---- blog could be replace with any node creating module ie story weblink ex ...
then go to
http://www.mysite.com/?q=latest_stories
thats it
Taxonomy works, also
Right after posting my original question, I remembered this could be a use for taxonomy. I simply created a term for "headline", pointed users to that taxonomy and now have real-time updates of nodes on a non-front page.
Wi-Fi Daily