private static function _generate_tags() { $tags = tag::get_tags(); $robotstxt = ""; foreach ($tags as $key => $var) { if (strlen($var["tag_for_url"]) > 0) { $robotstxt .= "Allow: /" . _("quotes") . "/" . _("tags") . "/" . $var["tag_for_url"] . "\n"; } } $tags_index = tag::get_tag_index(); foreach ($tags_index as $key => $var) { $robotstxt .= "Disallow: /" . _("quotes") . "/" . _("tags") . "/" . $var . "/\n"; } return $robotstxt; }
function _generate_tags() { global $config_q; $out = ""; $ca = new tag(); $tags = tag::get_tags(); foreach ($tags as $key => $var) { $out .= "<url>" . "\n"; $out .= " <loc>" . $config_q["baseurl"] . "/" . _("quotes") . "/" . _("tags") . "/" . $var["tag_for_url"] . "</loc>\n"; $out .= " <priority>0.80</priority>\n"; $out .= " <lastmod>" . date("Y-m-d\\T07:28:24+00:00", time()) . "</lastmod>\n"; $out .= " <changefreq>daily</changefreq>\n"; $out .= "</url>\n"; } return $out; }
static function item_index_data($item) { return join(" ", tag::get_tags($item)); }
*/ case "quotes-tags": $smarty_q->assign("h1", "Quotations by " . _("tags")); $smarty_q->assign("fake_h1", "Quotations by " . _("tags")); break; case "quotes-tags-%tag_index%": $context["h1"] = ""; $context["fake_h1"] = _("Tag category") . ": " . utf8_strtoupper($a_path[2]); if($a_path[2]=="-") { $quotes_temp = quote::get_quotes(array( "tag" => "" )); $context["quotes"] = $quotes_temp; } else { $context["taglist"] = tag::get_tags(array( "char" => $a_path[2], )); } break; case "quotes-tags-%tag%": $context["robots_index"] = true; $context["h1"] = str_replace("_", " ", $a_path[2]) . " - " . _("quotes"); $context["fake_h1"] = _("Tag category") . ": " . str_replace("_", " ",$a_path[2]); $context["description"] = str_replace("_", " ", $a_path[2]) . " - " . _("quotations"); $context["title"] = str_replace("_", " ", $a_path[2]) . " - " . _("quotes"); $quotes_temp = quote::get_quotes(array( "start" => (navi::get_current_page()-1)*$config_q["quotes_on_page"], "length" => $config_q["quotes_on_page"], "order_by" => "created_time asc", "tag" => $a_path[2], ));
static function photo_edit_form($photo, $form) { $tag_value = implode('; ', tag::get_tags($photo)); $form->edit_photo->input("tags")->label(t("Tags ( seperate by , or ; )"))->value($tag_value); }