+
+ // Prevent indexing of pages with multiple months of the content, any
+ // websearch robot should get indexed the right one specific page anyway.
+ heading(true/*title*/,($year && $month)/*indexme*/);
+
- $result=db_query("select year,month,month_last,contents from $tb_obsah"
- .($year ? " where year=$year" : "")
- .($month ? " and month=$month" : "")
+ $result=db_query("select year,month,month_last,contents from $tb_obsah where contents is not null"
+ .($year ? " and year=$year" : "")
+ .($month ? " and month=$month" : "")
$article_result=db_query("select name,id from $tb_clanek"
." where year=".$row[ "year"]
. " and month=".$row["month"]
);
while ($article_row=mysql_fetch_array($article_result))
$article_result=db_query("select name,id from $tb_clanek"
." where year=".$row[ "year"]
. " and month=".$row["month"]
);
while ($article_row=mysql_fetch_array($article_result))
- $contents=ereg_replace("$sep_obsah_contents(".quotemeta($article_row["name"]).")$page_obsah_contents",
+ $contents=ereg_replace("$sep_obsah_contents("
+ .quotemeta(ereg_replace("\\|.*\$","",$article_row["name"]))
+ .")([\n$page_obsah_contents])",
mysql_free_result($article_result);
$contents=ereg_replace("http://[^[:space:]$page_obsah_contents$sep_obsah_contents]+",
"<a href=\"\\0\">\\0</a>",$contents);
$contents=ereg_replace("$page_obsah_contents([^$sep_obsah_contents$appendix_obsah_contents]+)",
mysql_free_result($article_result);
$contents=ereg_replace("http://[^[:space:]$page_obsah_contents$sep_obsah_contents]+",
"<a href=\"\\0\">\\0</a>",$contents);
$contents=ereg_replace("$page_obsah_contents([^$sep_obsah_contents$appendix_obsah_contents]+)",
$contents=ereg_replace("\n","<br />\n\t\t",$contents);
$contents=ereg_replace("$sep_obsah_contents([^$sep_obsah_contents$appendix_obsah_contents]*)","\t<li>\\1</li>\n",$contents);
if (1<count($contents_a=split("$appendix_obsah_contents",$contents,2)))
$contents=ereg_replace("\n","<br />\n\t\t",$contents);
$contents=ereg_replace("$sep_obsah_contents([^$sep_obsah_contents$appendix_obsah_contents]*)","\t<li>\\1</li>\n",$contents);
if (1<count($contents_a=split("$appendix_obsah_contents",$contents,2)))