From f86a944979de75225dc3ddd00920ebedbfe307ed Mon Sep 17 00:00:00 2001 From: Kjartan Mannes Date: Sun, 12 May 2002 15:40:57 +0000 Subject: - applied Stevens link patch. - fixed block permissions. - fixed user admin page errors: http://www.drupal.org/node.php?id=173. - cleaned up common.inc a bit: removed format_info, path_img, field_merge. --- modules/aggregator/aggregator.module | 40 ++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 20 deletions(-) (limited to 'modules/aggregator/aggregator.module') diff --git a/modules/aggregator/aggregator.module b/modules/aggregator/aggregator.module index c12ee48ed..83c2bba69 100644 --- a/modules/aggregator/aggregator.module +++ b/modules/aggregator/aggregator.module @@ -29,7 +29,7 @@ function import_link($type) { } if ($type == "page" && user_access("access news feeds")) { - $links[] = lm(t("news feeds"), array("mod" => "import"), t("Read the latest news from syndicated websites.")); + $links[] = lm(t("news feeds"), array("mod" => "import"), "", array("title" => t("Read the latest news from syndicated websites."))); } return $links ? $links : array(); @@ -53,7 +53,7 @@ function import_format_item($item, $feed = 0) { global $theme, $user; if ($user->uid && user_access("post blogs")) { - $output .= lm("image("blog.gif") ."\" border=\"0\" width=\"12\" height=\"16\" alt=\"". t("Blog this item") ."\" />", array("mod" => "node", "op" => "add", "type" => "blog", "iid" => $item->iid), t("Comment on this news item in your personal blog.")); + $output .= lm("image("blog.gif") ."\" border=\"0\" width=\"12\" height=\"16\" alt=\"". t("Blog this item") ."\" />", array("mod" => "node", "op" => "add", "type" => "blog", "iid" => $item->iid), "", array("title" => t("Comment on this news item in your personal blog."))); } // external link @@ -98,7 +98,7 @@ function import_get_bundles($attributes = 0) { $i = 0; while ($bundle = db_fetch_object($result)) { $block[$i]["subject"] = $bundle->title; - $block[$i]["content"] = import_bundle_block($bundle->attributes) ."

". lm(t("more"), array("mod" => "import", "op" => "bundle", "id" => $bundle->bid), t("View this bundle's recent news.")) ."

"; + $block[$i]["content"] = import_bundle_block($bundle->attributes) ."

". lm(t("more"), array("mod" => "import", "op" => "bundle", "id" => $bundle->bid), "", array("title" => t("View this bundle's recent news."))) ."

"; $block[$i]["info"] = "$bundle->title bundle"; $i++; @@ -113,7 +113,7 @@ function import_get_feeds($attributes = 0) { $i = 0; while ($feed = db_fetch_object($result)) { $block[$i]["subject"] = $feed->title; - $block[$i]["content"] = import_feed_block($feed) ."

". lm(t("more"), array("mod" => "import", "op" => "feed", "id" => $feed->fid), t("View this feed's recent news.")) ."

"; + $block[$i]["content"] = import_feed_block($feed) ."

". lm(t("more"), array("mod" => "import", "op" => "feed", "id" => $feed->fid), "", array("title" => t("View this feed's recent news."))) ."

"; $block[$i]["info"] = "$feed->title feed"; $i++; @@ -522,10 +522,10 @@ function import_admin() { function import_page_info() { global $theme; - $links[] = lm(t("latest news"), array("mod" => "import"), t("Read the latest news from syndicated websites.")); - $links[] = lm(t("news by source"), array("mod" => "import", "op" => "feeds"), t("View the latest headlines sorted by source.")); - $links[] = lm(t("news by topic"), array("mod" => "import", "op" => "bundles"), t("View the latest headlines sorted by topic.")); - $links[] = lm(t("news sources"), array("mod" => "import", "op" => "sources"), t("View a list of all the websites we syndicate from.")); + $links[] = lm(t("latest news"), array("mod" => "import"), "", array("title" => t("Read the latest news from syndicated websites."))); + $links[] = lm(t("news by source"), array("mod" => "import", "op" => "feeds"), "", array("title" => t("View the latest headlines sorted by source."))); + $links[] = lm(t("news by topic"), array("mod" => "import", "op" => "bundles"), "", array("title" => t("View the latest headlines sorted by topic."))); + $links[] = lm(t("news sources"), array("mod" => "import", "op" => "sources"), "", array("title" => t("View a list of all the websites we syndicate from."))); return "
". $theme->links($links) ."
"; } @@ -537,11 +537,11 @@ function import_page_last() { $output .= ""; while ($item = db_fetch_object($result)) { - $links[] = lm(t("blog it"), array("mod" => "node", "op" => "add", "type" => "blog", "iid" => $item->iid), t("Comment on this news item in your personal blog.")); - $links[] = lm(t("feed"), array("mod" => "import", "op" => "feed", "id" => $item->fid), t("Read more syndicated news from this feed.")); + $links[] = lm(t("blog it"), array("mod" => "node", "op" => "add", "type" => "blog", "iid" => $item->iid), "", array("title" => t("Comment on this news item in your personal blog."))); + $links[] = lm(t("feed"), array("mod" => "import", "op" => "feed", "id" => $item->fid), "", array("title" => t("Read more syndicated news from this feed."))); if ($item->link) { - $output .= "\n"; + $output .= "\n"; } if ($item->description) { @@ -563,7 +563,7 @@ function import_page_feed($fid) { $feed = db_fetch_object(db_query("SELECT * FROM feed WHERE fid = '%s'", $fid)); - $header .= "

". t("Website") .":

". format_url($feed->link) ."

"; + $header .= "

". t("Website") .":

link\">$feed->link

"; $header .= "

". t("Description") .":

". check_output($feed->description, 1) ."

"; $header .= "

". t("Last update") .":

". format_interval(time() - $feed->timestamp) ." ". t("ago") ."url\">image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" />

\n"; @@ -571,11 +571,11 @@ function import_page_feed($fid) { $output .= "
". format_url($item->link, $item->title) ." · ". lm($item->ftitle, array("mod" => "import", "op" => "feed", "id" => $item->fid), t("View more information about this feed.")) ."". $theme->links($links) ."
link\">$item->title · ". lm($item->ftitle, array("mod" => "import", "op" => "feed", "id" => $item->fid), "", array("title" => t("View more information about this feed."))) ."". $theme->links($links) ."
"; while ($item = db_fetch_object($result)) { - $links[] = lm(t("blog it"), array("mod" => "node", "op" => "add", "type" => "blog", "iid" => $item->iid), t("Comment on this news item in your personal blog.")); + $links[] = lm(t("blog it"), array("mod" => "node", "op" => "add", "type" => "blog", "iid" => $item->iid), "", array("title" => t("Comment on this news item in your personal blog."))); $links[] = "link\">". t("visit") .""; if ($item->link) { - $output .= "\n"; + $output .= "\n"; } if ($item->description) { $output .= ""; @@ -596,7 +596,7 @@ function import_page_bundle($bid) { $bundle = db_fetch_object(db_query("SELECT * FROM bundle WHERE bid = '%s'", $bid)); - $header .= "

". t("Website") .":

". format_url(drupal_url(array("mod" => "import", "op" => "bundle", "id" => $bundle->bid), "module")) ."

"; + $header .= "

". t("Website") .":

". lm("", array("mod" => "import", "op" => "bundle", "id" => $bundle->bid)) ."

"; $header .= "

". t("Description") .":

". t("A composite news feed about") ." ". check_output($bundle->attributes) .".

"; $keys = explode(",", $bundle->attributes); @@ -605,12 +605,12 @@ function import_page_bundle($bid) { $output .= "
". format_url($item->link, $item->title) ."". $theme->links($links) ."
link\">$item->title". $theme->links($links) ."
". check_output($item->description, 1) ."

"; while ($item = db_fetch_object($result)) { - $links[] = lm(t("blog it"), array("mod" => "node", "op" => "add", "type" => "blog", "iid" => $item->iid), t("Comment on this news item in your personal blog.")); - $links[] = lm(t("feed"), array("mod" => "import", "op" => "feed", "id" => $item->fid), t("Read more syndicated news from this feed.")); + $links[] = lm(t("blog it"), array("mod" => "node", "op" => "add", "type" => "blog", "iid" => $item->iid), "", array("title" => t("Comment on this news item in your personal blog."))); + $links[] = lm(t("feed"), array("mod" => "import", "op" => "feed", "id" => $item->fid), "", array("title" => t("Read more syndicated news from this feed."))); $links[] = "link\">". t("visit") .""; if ($item->link) { - $output .= "\n"; + $output .= "\n"; } if ($item->description) { @@ -634,11 +634,11 @@ function import_page_sources() { $result = db_query("SELECT * FROM feed ORDER BY title"); while ($feed = db_fetch_object($result)) { - $output .= format_url(drupal_url(array("mod" => "import", "op" => "feed", "id" => $feed->fid), "module"), $feed->title); + $output .= lm("", array("mod" => "import", "op" => "feed", "id" => $feed->fid))); $output .= "
". check_output($feed->description, 1) ."

"; } - $output .= lm("image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" />", array("mod" => "import", "op" => "fd"), t("View the list of syndicated websites in XML format.")) ."
\n"; + $output .= lm("image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" />", array("mod" => "import", "op" => "fd"), "", array("title" => t("View the list of syndicated websites in XML format."))) ."
\n"; $theme->header(); $theme->box(t("News feeds"), import_page_info()); -- cgit v1.2.3
". format_url($item->link, $item->title) ." · ". lm($item->ftitle, array("mod" => "import", "op" => "feed", "id" => $item->fid), t("View more information about this feed.")) ."". $theme->links($links) ."
link\">$item->title · ". lm($item->ftitle, array("mod" => "import", "op" => "feed", "id" => $item->fid), "", array("title" => t("View more information about this feed."))) ."". $theme->links($links) ."