29
Сен
Тест подсветки синтаксиса
Тест подсветки синтаксиса:
if (!CUSTOM_TAGS) { $allowedposttags['pre'] = array( 'lang' => array(), 'line' => array(), 'escaped' => array(), 'style' => array(), 'width' => array(), 'extra' => array(), //DLyapin + ); //Allow plugin use in comments $allowedtags['pre'] = array( 'lang' => array(), 'line' => array(), 'escaped' => array(), 'extra' => array(), //DLyapin + ); } include_once("geshi/geshi.php"); if (!defined("WP_CONTENT_URL")) define("WP_CONTENT_URL", get_option("siteurl") . "/wp-content"); if (!defined("WP_PLUGIN_URL")) define("WP_PLUGIN_URL", WP_CONTENT_URL . "/plugins"); function wp_syntax_head() { $css_url = WP_PLUGIN_URL . "/wp-syntax/wp-syntax.css"; if (file_exists(TEMPLATEPATH . "/wp-syntax.css")) { $css_url = get_bloginfo("template_url") . "/wp-syntax.css"; } echo "\n".'<link rel="stylesheet" href="' . $css_url . '" type="text/css" media="screen" />'."\n"; } function wp_syntax_code_trim($code) { // special ltrim b/c leading whitespace matters on 1st line of content $code = preg_replace("/^\s*\n/siU", "", $code); $code = rtrim($code); return $code; }
