- Added about 50 title tags.
parent
0542bbd752
commit
c71e133958
|
@ -29,7 +29,7 @@ function import_link($type) {
|
|||
}
|
||||
|
||||
if ($type == "page" && user_access("access news feeds")) {
|
||||
$links[] = "<a href=\"module.php?mod=import\">". t("news feeds") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import\" title=\"". t("Read the latest news from syndicated websites.") ."\">". t("news feeds") ."</a>";
|
||||
}
|
||||
|
||||
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 .= "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\"><img src=\"". $theme->image("blog.gif") ."\" border=\"0\" width=\"12\" height=\"16\" alt=\"". t("Blog this item") ."\" /></a> ";
|
||||
$output .= "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\"><img src=\"". $theme->image("blog.gif") ."\" border=\"0\" width=\"12\" height=\"16\" alt=\"". t("Blog this item") ."\" /></a> ";
|
||||
}
|
||||
|
||||
$output .= "<a href=\"". check_output($item->link) ."\" target=\"new\">". check_output($item->title) ."</a>";
|
||||
|
@ -97,7 +97,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) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=bundle&id=$bundle->bid\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["content"] = import_bundle_block($bundle->attributes) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=bundle&id=$bundle->bid\" title=\"". t("View this bundle's recent news.") ."\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["info"] = "$bundle->title bundle";
|
||||
|
||||
$i++;
|
||||
|
@ -112,7 +112,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) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=feed&id=$feed->fid\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["content"] = import_feed_block($feed) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=feed&id=$feed->fid\" title=\"". t("View this feed's recent news.") ."\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["info"] = "$feed->title feed";
|
||||
|
||||
$i++;
|
||||
|
@ -137,7 +137,7 @@ function import_refresh($feed) {
|
|||
}
|
||||
|
||||
/*
|
||||
** Grab the headlines:
|
||||
** Grab the news items:
|
||||
*/
|
||||
|
||||
if ($fp = @fopen($feed["url"], "r")) {
|
||||
|
@ -514,10 +514,10 @@ function import_admin() {
|
|||
function import_page_info() {
|
||||
global $theme;
|
||||
|
||||
$links[] = "<a href=\"module.php?mod=import\">". t("latest news") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feeds\">". t("news by source") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=bundles\">". t("news by topic") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=sources\">". t("news sources") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import\" title=\"". t("Read the latest news from syndicated websites.") ."\">". t("latest news") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feeds\" title=\"". t("View the latest headlines sorted by source.") ."\">". t("news by source") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=bundles\" title=\"". t("View the latest headlines sorted by topic.") ."\">". t("news by topic") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=sources\" title=\"". t("View a list of all the websites we syndicate from.") ."\">". t("news sources") ."</a>";
|
||||
|
||||
return "<div align=\"center\">". $theme->links($links) ."</div>";
|
||||
}
|
||||
|
@ -529,12 +529,13 @@ function import_page_last() {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("Read more syndicated news from this feed.") ."\">". t("feed") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("View more information about this feed.") ."\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
}
|
||||
|
||||
if ($item->description) {
|
||||
$output .= "<tr><td colspan=\"2\"><div style=\"margin-left: 20px;\">". check_output($item->description, 1) ."</div><br /></td></tr>";
|
||||
}
|
||||
|
@ -562,7 +563,7 @@ function import_page_feed($fid) {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"$item->link\">". t("visit") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
|
@ -596,13 +597,14 @@ function import_page_bundle($bid) {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("Read more syndicated news from this feed.") ."\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"$item->link\">". t("visit") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("View more information about this feed.") ."\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
}
|
||||
|
||||
if ($item->description) {
|
||||
$output .= "<tr><td colspan=\"2\"><div style=\"margin-left: 20px;\">". check_output($item->description, 1) ."</div><br /></td></tr>";
|
||||
}
|
||||
|
@ -628,7 +630,7 @@ function import_page_sources() {
|
|||
$output .= "<div style=\"margin-left: 20px;\">". check_output($feed->description, 1) ."</div><br />";
|
||||
}
|
||||
|
||||
$output .= "<a href=\"module.php?mod=import&op=fd\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a><br />\n";
|
||||
$output .= "<a href=\"module.php?mod=import&op=fd\" title=\"". t("View the list of syndicated websites in XML format.") ."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a><br />\n";
|
||||
|
||||
$theme->header();
|
||||
$theme->box(t("News feeds"), import_page_info());
|
||||
|
|
|
@ -29,7 +29,7 @@ function import_link($type) {
|
|||
}
|
||||
|
||||
if ($type == "page" && user_access("access news feeds")) {
|
||||
$links[] = "<a href=\"module.php?mod=import\">". t("news feeds") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import\" title=\"". t("Read the latest news from syndicated websites.") ."\">". t("news feeds") ."</a>";
|
||||
}
|
||||
|
||||
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 .= "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\"><img src=\"". $theme->image("blog.gif") ."\" border=\"0\" width=\"12\" height=\"16\" alt=\"". t("Blog this item") ."\" /></a> ";
|
||||
$output .= "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\"><img src=\"". $theme->image("blog.gif") ."\" border=\"0\" width=\"12\" height=\"16\" alt=\"". t("Blog this item") ."\" /></a> ";
|
||||
}
|
||||
|
||||
$output .= "<a href=\"". check_output($item->link) ."\" target=\"new\">". check_output($item->title) ."</a>";
|
||||
|
@ -97,7 +97,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) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=bundle&id=$bundle->bid\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["content"] = import_bundle_block($bundle->attributes) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=bundle&id=$bundle->bid\" title=\"". t("View this bundle's recent news.") ."\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["info"] = "$bundle->title bundle";
|
||||
|
||||
$i++;
|
||||
|
@ -112,7 +112,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) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=feed&id=$feed->fid\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["content"] = import_feed_block($feed) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=feed&id=$feed->fid\" title=\"". t("View this feed's recent news.") ."\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["info"] = "$feed->title feed";
|
||||
|
||||
$i++;
|
||||
|
@ -137,7 +137,7 @@ function import_refresh($feed) {
|
|||
}
|
||||
|
||||
/*
|
||||
** Grab the headlines:
|
||||
** Grab the news items:
|
||||
*/
|
||||
|
||||
if ($fp = @fopen($feed["url"], "r")) {
|
||||
|
@ -514,10 +514,10 @@ function import_admin() {
|
|||
function import_page_info() {
|
||||
global $theme;
|
||||
|
||||
$links[] = "<a href=\"module.php?mod=import\">". t("latest news") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feeds\">". t("news by source") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=bundles\">". t("news by topic") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=sources\">". t("news sources") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import\" title=\"". t("Read the latest news from syndicated websites.") ."\">". t("latest news") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feeds\" title=\"". t("View the latest headlines sorted by source.") ."\">". t("news by source") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=bundles\" title=\"". t("View the latest headlines sorted by topic.") ."\">". t("news by topic") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=sources\" title=\"". t("View a list of all the websites we syndicate from.") ."\">". t("news sources") ."</a>";
|
||||
|
||||
return "<div align=\"center\">". $theme->links($links) ."</div>";
|
||||
}
|
||||
|
@ -529,12 +529,13 @@ function import_page_last() {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("Read more syndicated news from this feed.") ."\">". t("feed") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("View more information about this feed.") ."\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
}
|
||||
|
||||
if ($item->description) {
|
||||
$output .= "<tr><td colspan=\"2\"><div style=\"margin-left: 20px;\">". check_output($item->description, 1) ."</div><br /></td></tr>";
|
||||
}
|
||||
|
@ -562,7 +563,7 @@ function import_page_feed($fid) {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"$item->link\">". t("visit") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
|
@ -596,13 +597,14 @@ function import_page_bundle($bid) {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("Read more syndicated news from this feed.") ."\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"$item->link\">". t("visit") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("View more information about this feed.") ."\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
}
|
||||
|
||||
if ($item->description) {
|
||||
$output .= "<tr><td colspan=\"2\"><div style=\"margin-left: 20px;\">". check_output($item->description, 1) ."</div><br /></td></tr>";
|
||||
}
|
||||
|
@ -628,7 +630,7 @@ function import_page_sources() {
|
|||
$output .= "<div style=\"margin-left: 20px;\">". check_output($feed->description, 1) ."</div><br />";
|
||||
}
|
||||
|
||||
$output .= "<a href=\"module.php?mod=import&op=fd\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a><br />\n";
|
||||
$output .= "<a href=\"module.php?mod=import&op=fd\" title=\"". t("View the list of syndicated websites in XML format.") ."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a><br />\n";
|
||||
|
||||
$theme->header();
|
||||
$theme->box(t("News feeds"), import_page_info());
|
||||
|
|
|
@ -9,11 +9,10 @@ function blog_conf_options() {
|
|||
|
||||
}
|
||||
|
||||
|
||||
function blog_node($field) {
|
||||
global $user;
|
||||
|
||||
$info["name"] = t("personal blog");
|
||||
$info["name"] = t("personal blog entry");
|
||||
$info["description"] = t("A blog is your personal diary or journal. It is made up of individual entries that are time stamped and are typically arranged by the day, as normal a diary. Blogs often contain links to things you've seen, or on which you agree/disagree. Since a Blog is personal, you and only you have full control on what you publish. The most interesting blogs, or those blogs that fit the site's topic might get promoted to the front page.");
|
||||
|
||||
return $info[$field];
|
||||
|
@ -168,19 +167,19 @@ function blog_page_user($uid = 0, $date = 0) {
|
|||
|
||||
if ($date != date("dny", $blog->created)) {
|
||||
$date = date("dny", $blog->created);
|
||||
$output .= "<tr><td colspan=\"2\"><b><a href=\"module.php?mod=blog&id=$blog->uid&date=". mktime(23, 59, 59, date("n", $blog->created), date("d", $blog->created), date("Y", $blog->created)) ."\">". format_date($blog->created, custom, "d M Y") .":</a></b></td></tr>";
|
||||
$output .= "<tr><td colspan=\"2\"><b><a href=\"module.php?mod=blog&id=$blog->uid&date=". mktime(23, 59, 59, date("n", $blog->created), date("d", $blog->created), date("Y", $blog->created)) ."\" title=\"". t("Permanent link to this blog entry.") ."\">". format_date($blog->created, custom, "d M Y") .":</a></b></td></tr>";
|
||||
}
|
||||
|
||||
if ($user->uid && $user->uid == $uid) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$blog->nid\">". t("edit") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$blog->nid\" title=\"". t("Make changes to your blog entry.") ."\">". t("edit") ."</a>";
|
||||
}
|
||||
|
||||
if ($user->uid) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&nid=$blog->nid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&nid=$blog->nid\" title=\"". t("Comment on this blog entry in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
}
|
||||
|
||||
if ($blog->comment) {
|
||||
$links[] = "<a href=\"node.php?id=$blog->nid\">". format_plural(comment_num_all($blog->nid), t("comment"), t("comments")) ."</a>";
|
||||
$links[] = "<a href=\"node.php?id=$blog->nid\" title=\"". t("View this posting and all of its comments.") ."\">". format_plural(comment_num_all($blog->nid), t("comment"), t("comments")) ."</a>";
|
||||
}
|
||||
|
||||
$output .= "<tr><td><div style=\"margin-left: 20px;\"><b>". check_output($blog->title) ."</b></div></td><td align=\"right\">". $theme->links($links) ."</td></tr>";
|
||||
|
@ -189,7 +188,7 @@ function blog_page_user($uid = 0, $date = 0) {
|
|||
}
|
||||
|
||||
$output .= "</table>";
|
||||
$output .= "<a href=\"module.php?mod=blog&op=feed&id=$account->uid\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a>\n";
|
||||
$output .= "<a href=\"module.php?mod=blog&op=feed&id=$account->uid\" title=\"". t("View the XML version of this page.") ."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a>\n";
|
||||
|
||||
$theme->box(sprintf(t("%s's blog"), $account->name), $output, "main");
|
||||
}
|
||||
|
@ -206,18 +205,18 @@ function blog_page_last() {
|
|||
|
||||
$links = array();
|
||||
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$blog->uid\">". sprintf("%s's blog", $blog->name) ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$blog->uid\" title=\"". sprintf(t("Read %s's latest blog entries."), $blog->name) ."\">". sprintf("%s's blog", $blog->name) ."</a>";
|
||||
|
||||
if ($blog->uid == $user->uid) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$blog->nid\">". t("edit") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$blog->nid\" title=\"". t("Edit this blog entry.") ."\">". t("edit") ."</a>";
|
||||
}
|
||||
|
||||
if ($user->uid) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&nid=$blog->nid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&nid=$blog->nid\" title=\"". t("Comment on this blog entry in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
}
|
||||
|
||||
if ($blog->comment) {
|
||||
$links[] = "<a href=\"node.php?id=$blog->nid\">". format_plural(comment_num_all($blog->nid), t("comment"), t("comments")) ."</a>";
|
||||
$links[] = "<a href=\"node.php?id=$blog->nid\" title=\"". t("Read the posted comments or add a new comment.") ."\">". format_plural(comment_num_all($blog->nid), t("comment"), t("comments")) ."</a>";
|
||||
}
|
||||
|
||||
$output .= "<tr><td><b>". check_output($blog->title) ."</b></td><td align=\"right\">". $theme->links($links) ."</td></tr>";
|
||||
|
@ -226,7 +225,7 @@ function blog_page_last() {
|
|||
}
|
||||
|
||||
$output .= "</table>";
|
||||
$output .= "<a href=\"module.php?mod=blog&op=feed\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a>\n";
|
||||
$output .= "<a href=\"module.php?mod=blog&op=feed\" title=\"". t("View the XML version of this page.") ."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a>\n";
|
||||
|
||||
$theme->box(t("User blogs"), $output, "main");
|
||||
}
|
||||
|
@ -312,27 +311,26 @@ function blog_link($type, $node = 0) {
|
|||
global $user;
|
||||
|
||||
if ($type == "page" && user_access("access content")) {
|
||||
$links[] = "<a href=\"module.php?mod=blog\">". t("user blogs") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog\" title=\"". t("View the latest blog entries in chronological order.") ."\">". t("user blogs") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "menu") {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog\">". t("add blog entry") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$user->uid\">". t("view your blog") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog\" title=\"". t("Post a new entry to your personal blog.") ."\">". t("add blog entry") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$user->uid\" title=\"". t("View your latest blog entries in chronological order.") ."\">". t("view your blog") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "node" && $node->type == "blog") {
|
||||
if (blog_access("update", $node)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\">". t("update this blog") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\" title=\"". t("Update this blog entry.") ."\">". t("update this blog") ."</a>";
|
||||
}
|
||||
else {
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$node->uid\">". strtr(t("%a's blog"), array("%a" => $node->name)) ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$node->uid\" title=\"". sprintf(t("Read %s's latest blog entries."), $node->name) ."\">". strtr(t("%a's blog"), array("%a" => $node->name)) ."</a>";
|
||||
}
|
||||
}
|
||||
|
||||
return $links ? $links : array();
|
||||
}
|
||||
|
||||
|
||||
function blog_block() {
|
||||
global $user;
|
||||
|
||||
|
@ -342,7 +340,7 @@ function blog_block() {
|
|||
$output .= "<a href=\"node.php?id=$node->nid\">". check_output($node->title) ."</a><br />\n";
|
||||
}
|
||||
|
||||
$output .= "<br /><div align=\"right\"><a href=\"module.php?mod=blog\">". t("more") ."</a></div>";
|
||||
$output .= "<br /><div align=\"right\"><a href=\"module.php?mod=blog\" title=\"". t("View the latest blog entries in chronological order.") ."\">". t("more") ."</a></div>";
|
||||
|
||||
$block[0]["subject"] = t("User blogs");
|
||||
$block[0]["content"] = $output;
|
||||
|
|
|
@ -9,11 +9,10 @@ function blog_conf_options() {
|
|||
|
||||
}
|
||||
|
||||
|
||||
function blog_node($field) {
|
||||
global $user;
|
||||
|
||||
$info["name"] = t("personal blog");
|
||||
$info["name"] = t("personal blog entry");
|
||||
$info["description"] = t("A blog is your personal diary or journal. It is made up of individual entries that are time stamped and are typically arranged by the day, as normal a diary. Blogs often contain links to things you've seen, or on which you agree/disagree. Since a Blog is personal, you and only you have full control on what you publish. The most interesting blogs, or those blogs that fit the site's topic might get promoted to the front page.");
|
||||
|
||||
return $info[$field];
|
||||
|
@ -168,19 +167,19 @@ function blog_page_user($uid = 0, $date = 0) {
|
|||
|
||||
if ($date != date("dny", $blog->created)) {
|
||||
$date = date("dny", $blog->created);
|
||||
$output .= "<tr><td colspan=\"2\"><b><a href=\"module.php?mod=blog&id=$blog->uid&date=". mktime(23, 59, 59, date("n", $blog->created), date("d", $blog->created), date("Y", $blog->created)) ."\">". format_date($blog->created, custom, "d M Y") .":</a></b></td></tr>";
|
||||
$output .= "<tr><td colspan=\"2\"><b><a href=\"module.php?mod=blog&id=$blog->uid&date=". mktime(23, 59, 59, date("n", $blog->created), date("d", $blog->created), date("Y", $blog->created)) ."\" title=\"". t("Permanent link to this blog entry.") ."\">". format_date($blog->created, custom, "d M Y") .":</a></b></td></tr>";
|
||||
}
|
||||
|
||||
if ($user->uid && $user->uid == $uid) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$blog->nid\">". t("edit") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$blog->nid\" title=\"". t("Make changes to your blog entry.") ."\">". t("edit") ."</a>";
|
||||
}
|
||||
|
||||
if ($user->uid) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&nid=$blog->nid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&nid=$blog->nid\" title=\"". t("Comment on this blog entry in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
}
|
||||
|
||||
if ($blog->comment) {
|
||||
$links[] = "<a href=\"node.php?id=$blog->nid\">". format_plural(comment_num_all($blog->nid), t("comment"), t("comments")) ."</a>";
|
||||
$links[] = "<a href=\"node.php?id=$blog->nid\" title=\"". t("View this posting and all of its comments.") ."\">". format_plural(comment_num_all($blog->nid), t("comment"), t("comments")) ."</a>";
|
||||
}
|
||||
|
||||
$output .= "<tr><td><div style=\"margin-left: 20px;\"><b>". check_output($blog->title) ."</b></div></td><td align=\"right\">". $theme->links($links) ."</td></tr>";
|
||||
|
@ -189,7 +188,7 @@ function blog_page_user($uid = 0, $date = 0) {
|
|||
}
|
||||
|
||||
$output .= "</table>";
|
||||
$output .= "<a href=\"module.php?mod=blog&op=feed&id=$account->uid\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a>\n";
|
||||
$output .= "<a href=\"module.php?mod=blog&op=feed&id=$account->uid\" title=\"". t("View the XML version of this page.") ."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a>\n";
|
||||
|
||||
$theme->box(sprintf(t("%s's blog"), $account->name), $output, "main");
|
||||
}
|
||||
|
@ -206,18 +205,18 @@ function blog_page_last() {
|
|||
|
||||
$links = array();
|
||||
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$blog->uid\">". sprintf("%s's blog", $blog->name) ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$blog->uid\" title=\"". sprintf(t("Read %s's latest blog entries."), $blog->name) ."\">". sprintf("%s's blog", $blog->name) ."</a>";
|
||||
|
||||
if ($blog->uid == $user->uid) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$blog->nid\">". t("edit") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$blog->nid\" title=\"". t("Edit this blog entry.") ."\">". t("edit") ."</a>";
|
||||
}
|
||||
|
||||
if ($user->uid) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&nid=$blog->nid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&nid=$blog->nid\" title=\"". t("Comment on this blog entry in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
}
|
||||
|
||||
if ($blog->comment) {
|
||||
$links[] = "<a href=\"node.php?id=$blog->nid\">". format_plural(comment_num_all($blog->nid), t("comment"), t("comments")) ."</a>";
|
||||
$links[] = "<a href=\"node.php?id=$blog->nid\" title=\"". t("Read the posted comments or add a new comment.") ."\">". format_plural(comment_num_all($blog->nid), t("comment"), t("comments")) ."</a>";
|
||||
}
|
||||
|
||||
$output .= "<tr><td><b>". check_output($blog->title) ."</b></td><td align=\"right\">". $theme->links($links) ."</td></tr>";
|
||||
|
@ -226,7 +225,7 @@ function blog_page_last() {
|
|||
}
|
||||
|
||||
$output .= "</table>";
|
||||
$output .= "<a href=\"module.php?mod=blog&op=feed\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a>\n";
|
||||
$output .= "<a href=\"module.php?mod=blog&op=feed\" title=\"". t("View the XML version of this page.") ."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a>\n";
|
||||
|
||||
$theme->box(t("User blogs"), $output, "main");
|
||||
}
|
||||
|
@ -312,27 +311,26 @@ function blog_link($type, $node = 0) {
|
|||
global $user;
|
||||
|
||||
if ($type == "page" && user_access("access content")) {
|
||||
$links[] = "<a href=\"module.php?mod=blog\">". t("user blogs") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog\" title=\"". t("View the latest blog entries in chronological order.") ."\">". t("user blogs") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "menu") {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog\">". t("add blog entry") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$user->uid\">". t("view your blog") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog\" title=\"". t("Post a new entry to your personal blog.") ."\">". t("add blog entry") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$user->uid\" title=\"". t("View your latest blog entries in chronological order.") ."\">". t("view your blog") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "node" && $node->type == "blog") {
|
||||
if (blog_access("update", $node)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\">". t("update this blog") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\" title=\"". t("Update this blog entry.") ."\">". t("update this blog") ."</a>";
|
||||
}
|
||||
else {
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$node->uid\">". strtr(t("%a's blog"), array("%a" => $node->name)) ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=blog&op=view&id=$node->uid\" title=\"". sprintf(t("Read %s's latest blog entries."), $node->name) ."\">". strtr(t("%a's blog"), array("%a" => $node->name)) ."</a>";
|
||||
}
|
||||
}
|
||||
|
||||
return $links ? $links : array();
|
||||
}
|
||||
|
||||
|
||||
function blog_block() {
|
||||
global $user;
|
||||
|
||||
|
@ -342,7 +340,7 @@ function blog_block() {
|
|||
$output .= "<a href=\"node.php?id=$node->nid\">". check_output($node->title) ."</a><br />\n";
|
||||
}
|
||||
|
||||
$output .= "<br /><div align=\"right\"><a href=\"module.php?mod=blog\">". t("more") ."</a></div>";
|
||||
$output .= "<br /><div align=\"right\"><a href=\"module.php?mod=blog\" title=\"". t("View the latest blog entries in chronological order.") ."\">". t("more") ."</a></div>";
|
||||
|
||||
$block[0]["subject"] = t("User blogs");
|
||||
$block[0]["content"] = $output;
|
||||
|
|
|
@ -95,7 +95,7 @@ function book_save($op, $node) {
|
|||
|
||||
function book_link($type, $node = 0, $main = 0) {
|
||||
if ($type == "page" && user_access("access content")) {
|
||||
$links[] = "<a href=\"module.php?mod=book\">". t("collaborative book") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=book\" title=\"". t("Read and contribute to our collaborative books.") ."\">". t("collaborative book") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "admin" && user_access("administer nodes")) {
|
||||
|
@ -103,7 +103,7 @@ function book_link($type, $node = 0, $main = 0) {
|
|||
}
|
||||
|
||||
if ($type == "node" && $node->type == "book" && book_access("update", $node)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\">". t("update this book page") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\" title=\"". t("Suggest an update for this book page.") ."\">". t("update this book page") ."</a>";
|
||||
}
|
||||
|
||||
return $links ? $links : array();
|
||||
|
@ -401,8 +401,8 @@ function book_view($node, $main = 0) {
|
|||
}
|
||||
|
||||
$output .= " <tr><td colspan=\"3\"><hr /></td></tr>";
|
||||
$output .= " <tr><td align=\"left\" width=\"33%\">". ($prev ? "<a href=\"node.php?id=$prev->nid\">". t("previous") ."</a>" : t("previous")) ."</td><td align=\"center\" width=\"34%\"><a href=\"module.php?mod=book\">index</a></td><td align=\"right\" width=\"33%\">". ($next ? "<a href=\"node.php?id=$next->nid\">". t("next") ."</a>" : t("next")) ."</td></tr>";
|
||||
$output .= " <tr><td align=\"left\" width=\"33%\">". ($prev ? "<small>". check_output($prev->title) ."</small>" : " ") ."</td><td align=\"center\" width=\"34%\">". ($node->parent ? "<a href=\"node.php?id=$node->parent\">". t("up") ."</a>" : t("up")) ."</td><td align=\"right\" width=\"33%\">". ($next ? "<small>". check_output($next->title) ."</small>" : " ") ."</td></tr>";
|
||||
$output .= " <tr><td align=\"left\" width=\"33%\">". ($prev ? "<a href=\"node.php?id=$prev->nid\" title=\"". t("View the previous page in this book.") ."\">". t("previous") ."</a>" : t("previous")) ."</td><td align=\"center\" width=\"34%\"><a href=\"module.php?mod=book\" title=\"". t("View this book's table of contents.") ."\">index</a></td><td align=\"right\" width=\"33%\">". ($next ? "<a href=\"node.php?id=$next->nid\" title=\"". t("View the next page in this book.") ."\">". t("next") ."</a>" : t("next")) ."</td></tr>";
|
||||
$output .= " <tr><td align=\"left\" width=\"33%\">". ($prev ? "<small>". check_output($prev->title) ."</small>" : " ") ."</td><td align=\"center\" width=\"34%\">". ($node->parent ? "<a href=\"node.php?id=$node->parent\" title=\"". t("View the parent section.") ."\">". t("up") ."</a>" : t("up")) ."</td><td align=\"right\" width=\"33%\">". ($next ? "<small>". check_output($next->title) ."</small>" : " ") ."</td></tr>";
|
||||
$output .= " <tr><td colspan=\"3\"><hr /></td></tr>";
|
||||
$output .= " <tr><td colspan=\"3\" align=\"right\"><div style=\"margin: 10 10 10 10;\">". $theme->links(link_node($node, $main)) ."</div></td></tr>";
|
||||
$output .= "</table>";
|
||||
|
|
|
@ -95,7 +95,7 @@ function book_save($op, $node) {
|
|||
|
||||
function book_link($type, $node = 0, $main = 0) {
|
||||
if ($type == "page" && user_access("access content")) {
|
||||
$links[] = "<a href=\"module.php?mod=book\">". t("collaborative book") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=book\" title=\"". t("Read and contribute to our collaborative books.") ."\">". t("collaborative book") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "admin" && user_access("administer nodes")) {
|
||||
|
@ -103,7 +103,7 @@ function book_link($type, $node = 0, $main = 0) {
|
|||
}
|
||||
|
||||
if ($type == "node" && $node->type == "book" && book_access("update", $node)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\">". t("update this book page") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=edit&id=$node->nid\" title=\"". t("Suggest an update for this book page.") ."\">". t("update this book page") ."</a>";
|
||||
}
|
||||
|
||||
return $links ? $links : array();
|
||||
|
@ -401,8 +401,8 @@ function book_view($node, $main = 0) {
|
|||
}
|
||||
|
||||
$output .= " <tr><td colspan=\"3\"><hr /></td></tr>";
|
||||
$output .= " <tr><td align=\"left\" width=\"33%\">". ($prev ? "<a href=\"node.php?id=$prev->nid\">". t("previous") ."</a>" : t("previous")) ."</td><td align=\"center\" width=\"34%\"><a href=\"module.php?mod=book\">index</a></td><td align=\"right\" width=\"33%\">". ($next ? "<a href=\"node.php?id=$next->nid\">". t("next") ."</a>" : t("next")) ."</td></tr>";
|
||||
$output .= " <tr><td align=\"left\" width=\"33%\">". ($prev ? "<small>". check_output($prev->title) ."</small>" : " ") ."</td><td align=\"center\" width=\"34%\">". ($node->parent ? "<a href=\"node.php?id=$node->parent\">". t("up") ."</a>" : t("up")) ."</td><td align=\"right\" width=\"33%\">". ($next ? "<small>". check_output($next->title) ."</small>" : " ") ."</td></tr>";
|
||||
$output .= " <tr><td align=\"left\" width=\"33%\">". ($prev ? "<a href=\"node.php?id=$prev->nid\" title=\"". t("View the previous page in this book.") ."\">". t("previous") ."</a>" : t("previous")) ."</td><td align=\"center\" width=\"34%\"><a href=\"module.php?mod=book\" title=\"". t("View this book's table of contents.") ."\">index</a></td><td align=\"right\" width=\"33%\">". ($next ? "<a href=\"node.php?id=$next->nid\" title=\"". t("View the next page in this book.") ."\">". t("next") ."</a>" : t("next")) ."</td></tr>";
|
||||
$output .= " <tr><td align=\"left\" width=\"33%\">". ($prev ? "<small>". check_output($prev->title) ."</small>" : " ") ."</td><td align=\"center\" width=\"34%\">". ($node->parent ? "<a href=\"node.php?id=$node->parent\" title=\"". t("View the parent section.") ."\">". t("up") ."</a>" : t("up")) ."</td><td align=\"right\" width=\"33%\">". ($next ? "<small>". check_output($next->title) ."</small>" : " ") ."</td></tr>";
|
||||
$output .= " <tr><td colspan=\"3\"><hr /></td></tr>";
|
||||
$output .= " <tr><td colspan=\"3\" align=\"right\"><div style=\"margin: 10 10 10 10;\">". $theme->links(link_node($node, $main)) ."</div></td></tr>";
|
||||
$output .= "</table>";
|
||||
|
|
|
@ -58,7 +58,7 @@ function comment_tag_new($nid) {
|
|||
function comment_is_new($comment) {
|
||||
global $user;
|
||||
static $date;
|
||||
|
||||
|
||||
if (!$date) {
|
||||
if ($user->uid) {
|
||||
$history = db_fetch_object(db_query("SELECT timestamp FROM history WHERE uid = '$user->uid' AND nid = '$comment->nid'"));
|
||||
|
@ -357,15 +357,15 @@ function comment_links($comment, $return = 1) {
|
|||
}
|
||||
|
||||
if (user_access("administer comments")) {
|
||||
$links[] = "<a href=\"admin.php?mod=comment&op=edit&id=$comment->cid\"><font color=\"$theme->type\">". t("administer") ."</font></a>";
|
||||
$links[] = "<a href=\"admin.php?mod=comment&op=edit&id=$comment->cid\" title=\"". t("Administer this comment.") ."\"><font color=\"$theme->type\">". t("administer") ."</font></a>";
|
||||
}
|
||||
|
||||
if (user_access("post comments")) {
|
||||
if (comment_access("edit", $comment)) {
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=edit&id=$comment->cid\"><font color=\"$theme->type\">". t("edit your comment") ."</font></a>";
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=edit&id=$comment->cid\"><font color=\"$theme->type\" title=\"". t("Make changes to your comment.") ."\">". t("edit your comment") ."</font></a>";
|
||||
}
|
||||
else {
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=reply&id=$comment->nid&pid=$comment->cid\"><font color=\"$theme->type\">". t("reply to this comment") ."</font></a>";
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=reply&id=$comment->nid&pid=$comment->cid\" title=\"". t("Reply to this comment.") ."\"><font color=\"$theme->type\">". t("reply to this comment") ."</font></a>";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -551,7 +551,7 @@ function comment_link($type, $node = 0, $main = 0) {
|
|||
$all = comment_num_all($node->nid);
|
||||
$new = comment_num_new($node->nid);
|
||||
|
||||
$links[] = "<a href=\"node.php?id=$node->nid#comment\">". format_plural($all, "comment", "comments") . ($new ? ", $new ". t("new") : "") ."</a>";
|
||||
$links[] = "<a href=\"node.php?id=$node->nid#comment\" title=\"". t("View this posting and all of its comments.") ."\">". format_plural($all, "comment", "comments") . ($new ? ", $new ". t("new") : "") ."</a>";
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -561,7 +561,7 @@ function comment_link($type, $node = 0, $main = 0) {
|
|||
*/
|
||||
|
||||
if (user_access("post comments")) {
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=reply&id=$node->nid#comment\">". t("add new comment") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=reply&id=$node->nid#comment\" title=\"". t("Share your thoughts and opinions related to this posting.") ."\">". t("add new comment") ."</a>";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -58,7 +58,7 @@ function comment_tag_new($nid) {
|
|||
function comment_is_new($comment) {
|
||||
global $user;
|
||||
static $date;
|
||||
|
||||
|
||||
if (!$date) {
|
||||
if ($user->uid) {
|
||||
$history = db_fetch_object(db_query("SELECT timestamp FROM history WHERE uid = '$user->uid' AND nid = '$comment->nid'"));
|
||||
|
@ -357,15 +357,15 @@ function comment_links($comment, $return = 1) {
|
|||
}
|
||||
|
||||
if (user_access("administer comments")) {
|
||||
$links[] = "<a href=\"admin.php?mod=comment&op=edit&id=$comment->cid\"><font color=\"$theme->type\">". t("administer") ."</font></a>";
|
||||
$links[] = "<a href=\"admin.php?mod=comment&op=edit&id=$comment->cid\" title=\"". t("Administer this comment.") ."\"><font color=\"$theme->type\">". t("administer") ."</font></a>";
|
||||
}
|
||||
|
||||
if (user_access("post comments")) {
|
||||
if (comment_access("edit", $comment)) {
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=edit&id=$comment->cid\"><font color=\"$theme->type\">". t("edit your comment") ."</font></a>";
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=edit&id=$comment->cid\"><font color=\"$theme->type\" title=\"". t("Make changes to your comment.") ."\">". t("edit your comment") ."</font></a>";
|
||||
}
|
||||
else {
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=reply&id=$comment->nid&pid=$comment->cid\"><font color=\"$theme->type\">". t("reply to this comment") ."</font></a>";
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=reply&id=$comment->nid&pid=$comment->cid\" title=\"". t("Reply to this comment.") ."\"><font color=\"$theme->type\">". t("reply to this comment") ."</font></a>";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -551,7 +551,7 @@ function comment_link($type, $node = 0, $main = 0) {
|
|||
$all = comment_num_all($node->nid);
|
||||
$new = comment_num_new($node->nid);
|
||||
|
||||
$links[] = "<a href=\"node.php?id=$node->nid#comment\">". format_plural($all, "comment", "comments") . ($new ? ", $new ". t("new") : "") ."</a>";
|
||||
$links[] = "<a href=\"node.php?id=$node->nid#comment\" title=\"". t("View this posting and all of its comments.") ."\">". format_plural($all, "comment", "comments") . ($new ? ", $new ". t("new") : "") ."</a>";
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -561,7 +561,7 @@ function comment_link($type, $node = 0, $main = 0) {
|
|||
*/
|
||||
|
||||
if (user_access("post comments")) {
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=reply&id=$node->nid#comment\">". t("add new comment") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=comment&op=reply&id=$node->nid#comment\" title=\"". t("Share your thoughts and opinions related to this posting.") ."\">". t("add new comment") ."</a>";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@ function import_link($type) {
|
|||
}
|
||||
|
||||
if ($type == "page" && user_access("access news feeds")) {
|
||||
$links[] = "<a href=\"module.php?mod=import\">". t("news feeds") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import\" title=\"". t("Read the latest news from syndicated websites.") ."\">". t("news feeds") ."</a>";
|
||||
}
|
||||
|
||||
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 .= "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\"><img src=\"". $theme->image("blog.gif") ."\" border=\"0\" width=\"12\" height=\"16\" alt=\"". t("Blog this item") ."\" /></a> ";
|
||||
$output .= "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\"><img src=\"". $theme->image("blog.gif") ."\" border=\"0\" width=\"12\" height=\"16\" alt=\"". t("Blog this item") ."\" /></a> ";
|
||||
}
|
||||
|
||||
$output .= "<a href=\"". check_output($item->link) ."\" target=\"new\">". check_output($item->title) ."</a>";
|
||||
|
@ -97,7 +97,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) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=bundle&id=$bundle->bid\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["content"] = import_bundle_block($bundle->attributes) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=bundle&id=$bundle->bid\" title=\"". t("View this bundle's recent news.") ."\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["info"] = "$bundle->title bundle";
|
||||
|
||||
$i++;
|
||||
|
@ -112,7 +112,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) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=feed&id=$feed->fid\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["content"] = import_feed_block($feed) ."<p><div align=\"right\"><a href=\"module.php?mod=import&op=feed&id=$feed->fid\" title=\"". t("View this feed's recent news.") ."\">". t("more") ."</a></div></p>";
|
||||
$block[$i]["info"] = "$feed->title feed";
|
||||
|
||||
$i++;
|
||||
|
@ -137,7 +137,7 @@ function import_refresh($feed) {
|
|||
}
|
||||
|
||||
/*
|
||||
** Grab the headlines:
|
||||
** Grab the news items:
|
||||
*/
|
||||
|
||||
if ($fp = @fopen($feed["url"], "r")) {
|
||||
|
@ -514,10 +514,10 @@ function import_admin() {
|
|||
function import_page_info() {
|
||||
global $theme;
|
||||
|
||||
$links[] = "<a href=\"module.php?mod=import\">". t("latest news") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feeds\">". t("news by source") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=bundles\">". t("news by topic") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=sources\">". t("news sources") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import\" title=\"". t("Read the latest news from syndicated websites.") ."\">". t("latest news") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feeds\" title=\"". t("View the latest headlines sorted by source.") ."\">". t("news by source") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=bundles\" title=\"". t("View the latest headlines sorted by topic.") ."\">". t("news by topic") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=sources\" title=\"". t("View a list of all the websites we syndicate from.") ."\">". t("news sources") ."</a>";
|
||||
|
||||
return "<div align=\"center\">". $theme->links($links) ."</div>";
|
||||
}
|
||||
|
@ -529,12 +529,13 @@ function import_page_last() {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("Read more syndicated news from this feed.") ."\">". t("feed") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("View more information about this feed.") ."\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
}
|
||||
|
||||
if ($item->description) {
|
||||
$output .= "<tr><td colspan=\"2\"><div style=\"margin-left: 20px;\">". check_output($item->description, 1) ."</div><br /></td></tr>";
|
||||
}
|
||||
|
@ -562,7 +563,7 @@ function import_page_feed($fid) {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"$item->link\">". t("visit") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
|
@ -596,13 +597,14 @@ function import_page_bundle($bid) {
|
|||
|
||||
$output .= "<table border=\"0\" cellpadding=\"4\" cellspacing=\"2\">";
|
||||
while ($item = db_fetch_object($result)) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add&type=blog&iid=$item->iid\" title=\"". t("Comment on this news item in your personal blog.") ."\">". t("blog it") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("Read more syndicated news from this feed.") ."\">". t("feed") ."</a>";
|
||||
$links[] = "<a href=\"$item->link\">". t("visit") ."</a>";
|
||||
|
||||
if ($item->link) {
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
$output .= "<tr><td>". format_url($item->link, $item->title) ." · <a href=\"module.php?mod=import&op=feed&id=$item->fid\" title=\"". t("View more information about this feed.") ."\">$item->ftitle</a></td><td align=\"right\" nowrap=\"nowrap\" valign=\"top\">". $theme->links($links) ."</td></tr>\n";
|
||||
}
|
||||
|
||||
if ($item->description) {
|
||||
$output .= "<tr><td colspan=\"2\"><div style=\"margin-left: 20px;\">". check_output($item->description, 1) ."</div><br /></td></tr>";
|
||||
}
|
||||
|
@ -628,7 +630,7 @@ function import_page_sources() {
|
|||
$output .= "<div style=\"margin-left: 20px;\">". check_output($feed->description, 1) ."</div><br />";
|
||||
}
|
||||
|
||||
$output .= "<a href=\"module.php?mod=import&op=fd\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a><br />\n";
|
||||
$output .= "<a href=\"module.php?mod=import&op=fd\" title=\"". t("View the list of syndicated websites in XML format.") ."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" align=\"right\" border=\"0\" /></a><br />\n";
|
||||
|
||||
$theme->header();
|
||||
$theme->box(t("News feeds"), import_page_info());
|
||||
|
|
|
@ -358,7 +358,7 @@ function node_link($type, $node = 0, $main = 0) {
|
|||
}
|
||||
|
||||
if ($type == "page" && user_access("post content")) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add\">submit</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add\" title=\"". t("Submit a contribution.") ."\">". t("submit") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "node") {
|
||||
|
@ -367,11 +367,11 @@ function node_link($type, $node = 0, $main = 0) {
|
|||
}
|
||||
|
||||
if ($main == 1 && $node->teaser != $node->body) {
|
||||
$links[] = "<a href=\"node.php?id=$node->nid\">". t("read more") ."</a>";
|
||||
$links[] = "<a href=\"node.php?id=$node->nid\" title=\"". t("Read the rest of this posting.") ."\">". t("read more") ."</a>";
|
||||
}
|
||||
|
||||
if (user_access("administer nodes")) {
|
||||
$links[] = "<a href=\"admin.php?mod=node&op=edit&id=$node->nid\">". t("administer") ."</a>";
|
||||
$links[] = "<a href=\"admin.php?mod=node&op=edit&id=$node->nid\" title=\"". t("Administer this node.") ."\">". t("administer") ."</a>";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -644,7 +644,7 @@ function node_block() {
|
|||
global $theme;
|
||||
|
||||
$block[0][subject] = t("Syndicate");
|
||||
$block[0][content] = "<div align=\"center\"><a href=\"module.php?mod=node&op=feed\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" border=\"0\" alt=\"XML\" /></a></div>\n";
|
||||
$block[0][content] = "<div align=\"center\"><a href=\"module.php?mod=node&op=feed\" title=\"". t("Read the XML version of this page.")."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" border=\"0\" alt=\"XML\" /></a></div>\n";
|
||||
$block[0][info] = "Syndicate";
|
||||
|
||||
return $block;
|
||||
|
@ -879,7 +879,7 @@ function node_add($type) {
|
|||
foreach (module_list() as $name) {
|
||||
if (module_hook($name, "node") && node_access("create", array("type" => $name))) {
|
||||
$output .= "<li>";
|
||||
$output .= " <a href=\"module.php?mod=node&op=add&type=$name\">". module_invoke($name, "node", "name") ."</a>";
|
||||
$output .= " <a href=\"module.php?mod=node&op=add&type=$name\" title=\"". sprintf(t("Add a new %s."), module_invoke($name, "node", "name")) ."\">". module_invoke($name, "node", "name") ."</a>";
|
||||
$output .= " <div style=\"margin-left: 20px;\">". module_invoke($name, "node", "description") ."</div>";
|
||||
$output .= "</li>";
|
||||
}
|
||||
|
|
|
@ -358,7 +358,7 @@ function node_link($type, $node = 0, $main = 0) {
|
|||
}
|
||||
|
||||
if ($type == "page" && user_access("post content")) {
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add\">submit</a>";
|
||||
$links[] = "<a href=\"module.php?mod=node&op=add\" title=\"". t("Submit a contribution.") ."\">". t("submit") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "node") {
|
||||
|
@ -367,11 +367,11 @@ function node_link($type, $node = 0, $main = 0) {
|
|||
}
|
||||
|
||||
if ($main == 1 && $node->teaser != $node->body) {
|
||||
$links[] = "<a href=\"node.php?id=$node->nid\">". t("read more") ."</a>";
|
||||
$links[] = "<a href=\"node.php?id=$node->nid\" title=\"". t("Read the rest of this posting.") ."\">". t("read more") ."</a>";
|
||||
}
|
||||
|
||||
if (user_access("administer nodes")) {
|
||||
$links[] = "<a href=\"admin.php?mod=node&op=edit&id=$node->nid\">". t("administer") ."</a>";
|
||||
$links[] = "<a href=\"admin.php?mod=node&op=edit&id=$node->nid\" title=\"". t("Administer this node.") ."\">". t("administer") ."</a>";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -644,7 +644,7 @@ function node_block() {
|
|||
global $theme;
|
||||
|
||||
$block[0][subject] = t("Syndicate");
|
||||
$block[0][content] = "<div align=\"center\"><a href=\"module.php?mod=node&op=feed\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" border=\"0\" alt=\"XML\" /></a></div>\n";
|
||||
$block[0][content] = "<div align=\"center\"><a href=\"module.php?mod=node&op=feed\" title=\"". t("Read the XML version of this page.")."\"><img src=\"". $theme->image("xml.gif") ."\" width=\"36\" height=\"14\" border=\"0\" alt=\"XML\" /></a></div>\n";
|
||||
$block[0][info] = "Syndicate";
|
||||
|
||||
return $block;
|
||||
|
@ -879,7 +879,7 @@ function node_add($type) {
|
|||
foreach (module_list() as $name) {
|
||||
if (module_hook($name, "node") && node_access("create", array("type" => $name))) {
|
||||
$output .= "<li>";
|
||||
$output .= " <a href=\"module.php?mod=node&op=add&type=$name\">". module_invoke($name, "node", "name") ."</a>";
|
||||
$output .= " <a href=\"module.php?mod=node&op=add&type=$name\" title=\"". sprintf(t("Add a new %s."), module_invoke($name, "node", "name")) ."\">". module_invoke($name, "node", "name") ."</a>";
|
||||
$output .= " <div style=\"margin-left: 20px;\">". module_invoke($name, "node", "description") ."</div>";
|
||||
$output .= "</li>";
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ function queue_perm() {
|
|||
|
||||
function queue_link($type) {
|
||||
if ($type == "menu" && user_access("access submission queue")) {
|
||||
$links[] = "<a href=\"module.php?mod=queue\">". t("submission queue") ."</a> (<font color=\"red\">". queue_count() ."</font>)";
|
||||
$links[] = "<a href=\"module.php?mod=queue\" title=\"". t("Moderate the content in the submission queue.") ."\">". t("submission queue") ."</a> (<font color=\"red\">". queue_count() ."</font>)";
|
||||
}
|
||||
|
||||
return $links ? $links : array();
|
||||
|
|
|
@ -414,12 +414,12 @@ function user_search($keys) {
|
|||
|
||||
function user_link($type) {
|
||||
if ($type == "page") {
|
||||
$links[] = "<a href=\"module.php?mod=user\">". t("user account") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=user\" title=\"". t("Create a user account, e-mail a new password or edit your account settings.") ."\">". t("user account") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "menu") {
|
||||
$links[] = "<a href=\"module.php?mod=user&op=edit\">". t("account settings") ."</a>";
|
||||
$links[] = "<br /><a href=\"module.php?mod=user&op=logout\">". t("logout") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=user&op=edit\" title=\"". t("View and edit your account information.") ."\">". t("account settings") ."</a>";
|
||||
$links[] = "<br /><a href=\"module.php?mod=user&op=logout\" title=\"". t("Logout.") ."\">". t("logout") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "admin" && user_access("administer users")) {
|
||||
|
|
|
@ -414,12 +414,12 @@ function user_search($keys) {
|
|||
|
||||
function user_link($type) {
|
||||
if ($type == "page") {
|
||||
$links[] = "<a href=\"module.php?mod=user\">". t("user account") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=user\" title=\"". t("Create a user account, e-mail a new password or edit your account settings.") ."\">". t("user account") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "menu") {
|
||||
$links[] = "<a href=\"module.php?mod=user&op=edit\">". t("account settings") ."</a>";
|
||||
$links[] = "<br /><a href=\"module.php?mod=user&op=logout\">". t("logout") ."</a>";
|
||||
$links[] = "<a href=\"module.php?mod=user&op=edit\" title=\"". t("View and edit your account information.") ."\">". t("account settings") ."</a>";
|
||||
$links[] = "<br /><a href=\"module.php?mod=user&op=logout\" title=\"". t("Logout.") ."\">". t("logout") ."</a>";
|
||||
}
|
||||
|
||||
if ($type == "admin" && user_access("administer users")) {
|
||||
|
|
Loading…
Reference in New Issue