\n"; echo "

".obt_translate("Control panel")."

\n"; echo "

".obt_translate("Logged-in as %1","{$user_identity}")." (".obt_translate("exit").").

\n"; echo "\n"; echo "\n"; }; }; FUNCTION obt_widget_archives(){ echo "
\n"; echo "

".obt_translate("Archives")."

\n"; echo "\n"; echo "
\n"; }; FUNCTION obt_widget_bloggers(){ global $wpdb; flush(); $display_name = (obt_wp_is_2())? "display_name" : "user_nickname"; $post_type = (obt_wp_is_21())? "post_type = 'post' AND " : ""; $now = current_time("mysql",1); IF ($bloggers = $wpdb->get_results("SELECT DISTINCT {$wpdb->users}.ID, user_nicename, {$display_name}, COUNT({$wpdb->posts}.ID) as count FROM {$wpdb->users} LEFT JOIN {$wpdb->posts} ON post_author = {$wpdb->users}.ID WHERE {$post_type}post_status = 'publish' AND post_date_gmt < '$now' GROUP BY post_author ORDER BY {$display_name}")){ echo "
\n"; echo "

".obt_translate("Bloggers")."

\n"; echo "\n"; echo "
\n"; }; }; FUNCTION obt_widget_calendar(){ flush(); IF (obt_use_buffer()){ ob_start(); get_calendar(); $calendar = ob_get_contents(); ob_end_clean(); preg_match("'(.*)<\/caption>'",$calendar,$matches); echo "
\n"; echo "

".obt_translate_month_year($matches[1])."

\n"; $calendar = preg_replace("' summary=\"(.*?)\"'","",$calendar); $calendar = preg_replace("'(.*?)'si","",$calendar); $calendar = preg_replace("'(.*?)'si","",$calendar); $calendar = preg_replace("'M","".substr(obt_translate("Monday"),0,1)."",$calendar); $calendar = str_replace("T","".substr(obt_translate("Tuesday"),0,1)."",$calendar); $calendar = str_replace("W","".substr(obt_translate("Wednesday"),0,1)."",$calendar); $calendar = str_replace("T","".substr(obt_translate("Thursday"),0,1)."",$calendar); $calendar = str_replace("F","".substr(obt_translate("Friday"),0,1)."",$calendar); $calendar = str_replace("S","".substr(obt_translate("Saturday"),0,1)."",$calendar); $calendar = str_replace("S","".substr(obt_translate("Sunday"),0,1)."",$calendar); $calendar = str_replace(array(" id=\"next\""," id=\"prev\""," class=\"pad\""),"",$calendar); WHILE (strpos($calendar,"\n\t\n") !== false) $calendar = str_replace("\n\t\n","\n",$calendar); WHILE (strpos($calendar,"\n\n") !== false) $calendar = str_replace("\n\n","\n",$calendar); WHILE (strpos($calendar,"\t<") !== false) $calendar = str_replace("\t<","<",$calendar); WHILE (strpos($calendar,"\t\t") !== false) $calendar = str_replace("\t\t","\t",$calendar); echo $calendar; echo "\n"; echo "
\n"; }ELSE{ echo "
\n"; echo "

\n"; get_calendar(); echo "\n

\n"; echo "
\n"; }; }; FUNCTION obt_widget_categories(){ echo "
\n"; echo "

".obt_translate("Categories")."

\n"; echo "
\n"; echo "
\n"; }; FUNCTION obt_widget_favorites(){ global $wpdb; flush(); IF ($links = $wpdb->get_results("SELECT link_url,link_name FROM {$wpdb->links} WHERE link_visible = 'Y' ORDER BY link_name")){ echo "
\n"; echo "

".obt_translate("Favorite sites")."

\n"; echo "\n"; echo "
\n"; }; }; FUNCTION obt_widget_latestcomments(){ global $wpdb, $user_ID, $obt_comments_per_page, $obt_comments_order, $obt_can_moderate_comments; echo "
\n"; echo "

".obt_translate("Latest comments")."

\n"; echo "\n"; echo "
\n"; }; FUNCTION obt_widget_latestentries(){ global $wpdb; echo "
\n"; echo "

".((is_home() && !is_paged())? obt_translate("Next posts") : obt_translate("Latest posts"))."

\n"; echo "\n"; echo "
\n"; }; FUNCTION obt_widget_login(){ global $user_ID, $user_login; IF (!strlen($user_ID) && get_option("users_can_register")){ echo "
\n"; echo "

".obt_translate("Log-in")."

\n"; echo "
\n"; echo "


\n"; echo " ".obt_translate("Password")."
\n"; echo "  \n"; echo "\n"; echo "

\n"; echo "
\n"; echo "\n"; echo "
\n"; }; }; FUNCTION obt_widget_pages(){ echo "
\n"; echo "

".obt_translate("Pages")."

\n"; obt_widget_pages_list(); echo "
\n"; }; FUNCTION obt_widget_pages_list(){ echo "