From c1c612b12826ab9bf65283f5430f4c7558e24699 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Thu, 31 Jan 2002 20:23:44 +0000 Subject: - Made the calendar module accept a $date parameter such that you can jump directly to a certain date in the archives. Also made the calendar link to itself such that it is self-contained. - Code beautifications: quoted a lot of arrays, removed dead code and simplified a few things. - Replaced the Calendar class by one function "calendar_display": using a class (or class instance, or object) doesn't make sense in the archives' case. - Renamed "calendar.module" to "archive.module". - Fixed a /problem/ with node settings not always being saved like expected. - Reorganized the user menu: renamed a couple of links for clarity and structure. - Fixed a few typos. --- modules/node.module | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules/node.module') diff --git a/modules/node.module b/modules/node.module index 57fe3ad8c..983dcfd2b 100644 --- a/modules/node.module +++ b/modules/node.module @@ -1127,7 +1127,7 @@ function node_delete($edit) { } function node_page() { - global $op, $id, $user, $edit, $type, $theme, $meta, $date; + global $op, $id, $user, $edit, $type, $theme, $meta; if ($op == "feed") { node_feed(); @@ -1167,7 +1167,7 @@ function node_page() { $theme->box($title, node_delete($edit)); break; default: - $result = db_query("SELECT nid, type FROM node WHERE ". ($meta ? "attributes LIKE '%". check_input($meta) ."%' AND " : "") ." promote = '1' AND status = '1' AND (static = '1' OR created <= '". ($date > 0 ? check_input($date) : time()) ."') ORDER BY static DESC,created DESC LIMIT ". ($user->nodes ? $user->nodes : variable_get("default_nodes_main", 10))); + $result = db_query("SELECT nid, type FROM node WHERE ". ($meta ? "attributes LIKE '%". check_input($meta) ."%' AND " : "") ." promote = '1' AND status = '1' ORDER BY static DESC, created DESC LIMIT ". ($user->nodes ? $user->nodes : variable_get("default_nodes_main", 10))); while ($node = db_fetch_object($result)) { node_view(node_load(array("nid" => $node->nid, "type" => $node->type)), 1); } -- cgit v1.2.3