getStringLang(EDIR_LANGUAGE, "title")) { header("Location: ".BLOG_DEFAULT_URL."/index.php"); exit; } } # ---------------------------------------------------------------------------------------------------- # SITE CONTENT # ---------------------------------------------------------------------------------------------------- $contentObj = new Content("", EDIR_LANGUAGE); $sitecontentSection = "Post Results"; $sitecontentinfo = $contentObj->retrieveContentInfoByType($sitecontentSection); if ($sitecontentinfo) { $headertagtitle = $sitecontentinfo["title"]; $headertagdescription = $sitecontentinfo["description"]; $headertagkeywords = $sitecontentinfo["keywords"]; $sitecontent = $sitecontentinfo["content"]; } else { $headertagtitle = ""; $headertagdescription = ""; $headertagkeywords = ""; $sitecontent = ""; } # ---------------------------------------------------------------------------------------------------- # RESULTS # ---------------------------------------------------------------------------------------------------- $search_lock = false; if (BLOG_SCALABILITY_OPTIMIZATION == "on") { if (!$_GET["keyword"] && !$_GET["where"] && !$_GET["category_id"] && !$_GET["id"]) { $_GET["id"] = 0; $search_lock = true; } } unset($searchReturn); $okY = 1; $okM = 1; if ($_GET["archive_year"]){ if (is_numeric($_GET["archive_year"])){ $okY = 1; } else { $okY = 0; } } if ($_GET["archive_month"]){ if (is_numeric($_GET["archive_month"])){ $okM = 1; } else { $okM = 0; } } if ($okY && $okM) { $searchReturn = search_frontBlogSearch($_GET, "blog"); $pageObj = new pageBrowsing($searchReturn["from_tables"], $screen, 10, $searchReturn["order_by"], "Post.title", $letter, $searchReturn["where_clause"], $searchReturn["select_columns"], "Post", $searchReturn["group_by"]); $posts = $pageObj->retrievePage(); $paging_url = BLOG_DEFAULT_URL."/results.php"; $array_search_params = array(); foreach ($_GET as $name => $value){ if ($name != "screen" && $name != "letter"){ if ( $name == "keyword" ) $array_search_params[] = $name."=".urlencode($value); else $array_search_params[] = $name."=".$value; } } $url_search_params = implode("&", $array_search_params); $letters = $pageObj->getString("letters"); foreach ($letters as $each_letter) { if ($each_letter == "#") { $letters_menu .= "".string_strtoupper($each_letter).""; } else { $letters_menu .= "".string_strtoupper($each_letter).""; } } $user = true; # PAGES DROP DOWN ---------------------------------------------------------------------------------------------- setting_get("review_post_enabled", $review_post_enabled); $pagesDropDown = $pageObj->getPagesDropDown($_GET, $paging_url, $screen, system_showText(LANG_PAGING_GOTOPAGE)." ", "this.form.submit();"); $db = db_getDBObject(); $sql = "SELECT count(*) as nunberOfReviews FROM Review WHERE item_type = 'post'"; $result = $db->query($sql); $result = mysql_fetch_assoc($result); $numberOfReviews = $result['nunberOfReviews']; if ($review_post_enabled && $numberOfReviews) $orderBy = array(LANG_PAGING_ORDERBYPAGE_CHARACTERS,LANG_PAGING_ORDERBYPAGE_LASTUPDATE,LANG_PAGING_ORDERBYPAGE_DATECREATED,LANG_PAGING_ORDERBYPAGE_POPULAR,LANG_PAGING_ORDERBYPAGE_RATING); else $orderBy = array(LANG_PAGING_ORDERBYPAGE_CHARACTERS,LANG_PAGING_ORDERBYPAGE_LASTUPDATE,LANG_PAGING_ORDERBYPAGE_DATECREATED,LANG_PAGING_ORDERBYPAGE_POPULAR); $orderbyDropDown = search_getOrderbyDropDown($_GET, $paging_url, $orderBy, system_showText(LANG_PAGING_ORDERBYPAGE)." ", "this.form.submit();"); # -------------------------------------------------------------------------------------------------------------- # ---------------------------------------------------------------------------------------------------- # HEADER # ---------------------------------------------------------------------------------------------------- //$banner_section = "general"; $headertag_title = $headertagtitle; $headertag_description = $headertagdescription; $headertag_keywords = $headertagkeywords; if ($browsebycategory || $category_id) { if ($category_id) { $categoryObjHeaderTag = new BlogCategory($category_id); if ($categoryObjHeaderTag->getStringLang(EDIR_LANGUAGE, "seo_description")) $headertag_description = $categoryObjHeaderTag->getStringLang(EDIR_LANGUAGE, "seo_description"); if ($categoryObjHeaderTag->getStringLang(EDIR_LANGUAGE, "seo_keywords")) $headertag_keywords = $categoryObjHeaderTag->getStringLang(EDIR_LANGUAGE, "seo_keywords"); unset($categoryObjHeaderTag); } } include(EDIRECTORY_ROOT."/layout/header.php"); # ---------------------------------------------------------------------------------------------------- # AUX # ---------------------------------------------------------------------------------------------------- require(EDIRECTORY_ROOT."/frontend/checkregbin.php"); # ---------------------------------------------------------------------------------------------------- # BODY # ---------------------------------------------------------------------------------------------------- if (EDIR_THEME) { include(THEMEFILE_DIR."/".EDIR_THEME."/body/blog_results.php"); } else { include(EDIRECTORY_ROOT."/blog/frontend/body/blog_results.php"); } # ---------------------------------------------------------------------------------------------------- # FOOTER # ---------------------------------------------------------------------------------------------------- $banner_section = "post"; include(EDIRECTORY_ROOT."/layout/footer.php"); }?>