PageRenderTime 51ms CodeModel.GetById 17ms RepoModel.GetById 1ms app.codeStats 0ms

/wp-content/plugins/seo-ultimate/modules/titles/titles.php

https://github.com/sharpmachine/wakeupmedia.com
PHP | 489 lines | 404 code | 66 blank | 19 comment | 41 complexity | e95a2ab18771ded85f2d7d79dbb79aaf MD5 | raw file
  1. <?php
  2. /**
  3. * Title Tag Rewriter Module
  4. *
  5. * @since 0.1
  6. */
  7. if (class_exists('SU_Module')) {
  8. function su_titles_export_filter($all_settings) {
  9. unset($all_settings['titles']['taxonomy_titles']);
  10. return $all_settings;
  11. }
  12. add_filter('su_settings_export_array', 'su_titles_export_filter');
  13. class SU_Titles extends SU_Module {
  14. function get_module_title() { return __('Title Tag Rewriter', 'seo-ultimate'); }
  15. function init() {
  16. switch ($this->get_setting('rewrite_method', 'ob')) {
  17. case 'filter':
  18. add_filter('wp_title', array(&$this, 'get_title'));
  19. break;
  20. case 'ob':
  21. default:
  22. add_action('template_redirect', array(&$this, 'before_header'), 0);
  23. add_action('wp_head', array(&$this, 'after_header'), 1000);
  24. break;
  25. }
  26. add_filter('su_postmeta_help', array(&$this, 'postmeta_help'), 10);
  27. }
  28. function get_admin_page_tabs() {
  29. return array_merge(
  30. array(
  31. array('title' => __('Default Formats', 'seo-ultimate'), 'id' => 'su-default-formats', 'callback' => 'formats_tab')
  32. , array('title' => __('Settings', 'seo-ultimate'), 'id' => 'su-settings', 'callback' => 'settings_tab')
  33. )
  34. , $this->get_meta_edit_tabs(array(
  35. 'type' => 'textbox'
  36. , 'name' => 'title'
  37. , 'term_settings_key' => 'taxonomy_titles'
  38. , 'label' => __('Title Tag', 'seo-ultimate')
  39. ))
  40. );
  41. }
  42. function formats_tab() {
  43. echo "<table class='form-table'>\n";
  44. $this->textboxes($this->get_supported_settings(), $this->get_default_settings());
  45. echo "</table>";
  46. }
  47. function settings_tab() {
  48. $this->admin_form_table_start();
  49. $this->checkbox('terms_ucwords', __('Convert lowercase category/tag names to title case when used in title tags.', 'seo-ultimate'), __('Title Tag Variables', 'seo-ultimate'));
  50. $this->radiobuttons('rewrite_method', array(
  51. 'ob' => __('Use output buffering &mdash; no configuration required, but slower (default)', 'seo-ultimate')
  52. , 'filter' => __('Use filtering &mdash; faster, but configuration required (see the &#8220;Settings Tab&#8221 section of the &#8220;Help&#8221; dropdown for details)', 'seo-ultimate')
  53. ), __('Rewrite Method', 'seo-ultimate'));
  54. $this->admin_form_table_end();
  55. }
  56. function get_default_settings() {
  57. //We internationalize even non-text formats (like "{post} | {blog}") to allow RTL languages to switch the order of the variables
  58. return array(
  59. 'title_home' => __('{blog}', 'seo-ultimate')
  60. , 'title_single' => __('{post} | {blog}', 'seo-ultimate')
  61. , 'title_page' => __('{page} | {blog}', 'seo-ultimate')
  62. , 'title_category' => __('{category} | {blog}', 'seo-ultimate')
  63. , 'title_tag' => __('{tag} | {blog}', 'seo-ultimate')
  64. , 'title_day' => __('Archives for {month} {day}, {year} | {blog}', 'seo-ultimate')
  65. , 'title_month' => __('Archives for {month} {year} | {blog}', 'seo-ultimate')
  66. , 'title_year' => __('Archives for {year} | {blog}', 'seo-ultimate')
  67. , 'title_author' => __('Posts by {author} | {blog}', 'seo-ultimate')
  68. , 'title_search' => __('Search Results for {query} | {blog}', 'seo-ultimate')
  69. , 'title_404' => __('404 Not Found | {blog}', 'seo-ultimate')
  70. , 'title_paged' => __('{title} - Page {num}', 'seo-ultimate')
  71. , 'terms_ucwords' => true
  72. , 'rewrite_method' => 'ob'
  73. );
  74. }
  75. function get_supported_settings() {
  76. return array(
  77. 'title_home' => __('Blog Homepage Title', 'seo-ultimate')
  78. , 'title_single' => __('Post Title Format', 'seo-ultimate')
  79. , 'title_page' => __('Page Title Format', 'seo-ultimate')
  80. , 'title_category' => __('Category Title Format', 'seo-ultimate')
  81. , 'title_tag' => __('Tag Title Format', 'seo-ultimate')
  82. , 'title_day' => __('Day Archive Title Format', 'seo-ultimate')
  83. , 'title_month' => __('Month Archive Title Format', 'seo-ultimate')
  84. , 'title_year' => __('Year Archive Title Format', 'seo-ultimate')
  85. , 'title_author' => __('Author Archive Title Format', 'seo-ultimate')
  86. , 'title_search' => __('Search Title Format', 'seo-ultimate')
  87. , 'title_404' => __('404 Title Format', 'seo-ultimate')
  88. , 'title_paged' => __('Pagination Title Format', 'seo-ultimate')
  89. );
  90. }
  91. function get_title_format() {
  92. if ($key = $this->get_current_page_type())
  93. return $this->get_setting("title_$key");
  94. return false;
  95. }
  96. function get_current_page_type() {
  97. $pagetypes = $this->get_supported_settings();
  98. unset($pagetypes['title_paged']);
  99. foreach ($pagetypes as $key => $title) {
  100. $key = str_replace('title_', '', $key);
  101. if (call_user_func("is_$key")) return $key;
  102. }
  103. return false;
  104. }
  105. function should_rewrite_title() {
  106. return (!is_admin() && !is_feed());
  107. }
  108. function before_header() {
  109. if ($this->should_rewrite_title()) ob_start(array(&$this, 'change_title_tag'));
  110. }
  111. function after_header() {
  112. if ($this->should_rewrite_title()) {
  113. $handlers = ob_list_handlers();
  114. if (count($handlers) > 0 && strcasecmp($handlers[count($handlers)-1], 'SU_Titles::change_title_tag') == 0)
  115. ob_end_flush();
  116. else
  117. su_debug_log(__FILE__, __CLASS__, __FUNCTION__, __LINE__, "Other ob_list_handlers found:\n".print_r($handlers, true));
  118. }
  119. }
  120. function change_title_tag($head) {
  121. $title = $this->get_title();
  122. if (!$title) return $head;
  123. //Replace the old title with the new and return
  124. return eregi_replace('<title>[^<]*</title>', '<title>'.$title.'</title>', $head);
  125. }
  126. function get_title() {
  127. global $wp_query, $wp_locale;
  128. //Custom post/page title?
  129. if ($post_title = $this->get_postmeta('title'))
  130. return htmlspecialchars($this->get_title_paged($post_title));
  131. //Custom taxonomy title?
  132. if (is_category() || is_tag() || is_tax()) {
  133. $tax_titles = $this->get_setting('taxonomy_titles');
  134. if ($tax_title = $tax_titles[$wp_query->get_queried_object_id()])
  135. return htmlspecialchars($this->get_title_paged($tax_title));
  136. }
  137. //Get format
  138. if (!$this->should_rewrite_title()) return '';
  139. if (!($format = $this->get_title_format())) return '';
  140. //Load post/page titles
  141. $post_id = 0;
  142. $post_title = '';
  143. $parent_title = '';
  144. if (is_singular()) {
  145. $post = $wp_query->get_queried_object();
  146. $post_title = strip_tags( apply_filters( 'single_post_title', $post->post_title ) );
  147. $post_id = $post->ID;
  148. if ($parent = $post->post_parent) {
  149. $parent = &get_post($parent);
  150. $parent_title = strip_tags( apply_filters( 'single_post_title', $parent->post_title ) );
  151. }
  152. }
  153. //Load date-based archive titles
  154. if ($m = get_query_var('m')) {
  155. $year = substr($m, 0, 4);
  156. $monthnum = intval(substr($m, 4, 2));
  157. $daynum = intval(substr($m, 6, 2));
  158. } else {
  159. $year = get_query_var('year');
  160. $monthnum = get_query_var('monthnum');
  161. $daynum = get_query_var('day');
  162. }
  163. $month = $wp_locale->get_month($monthnum);
  164. $monthnum = zeroise($monthnum, 2);
  165. $day = date('jS', mktime(12,0,0,$monthnum,$daynum,$year));
  166. $daynum = zeroise($daynum, 2);
  167. //Load category titles
  168. $cat_title = $cat_titles = $cat_desc = '';
  169. if (is_category()) {
  170. $cat_title = single_cat_title('', false);
  171. $cat_desc = category_description();
  172. } elseif (count($categories = get_the_category())) {
  173. $cat_titles = su_lang_implode($categories, 'name');
  174. usort($categories, '_usort_terms_by_ID');
  175. $cat_title = $categories[0]->name;
  176. $cat_desc = category_description($categories[0]->term_id);
  177. }
  178. if (strlen($cat_title) && $this->get_setting('terms_ucwords', true))
  179. $cat_title = sustr::tclcwords($cat_title);
  180. //Load tag titles
  181. $tag_title = $tag_desc = '';
  182. if (is_tag()) {
  183. $tag_title = single_tag_title('', false);
  184. $tag_desc = tag_description();
  185. if ($this->get_setting('terms_ucwords', true))
  186. $tag_title = sustr::tclcwords($tag_title);
  187. }
  188. //Load author titles
  189. if (is_author()) {
  190. $author_obj = $wp_query->get_queried_object();
  191. } elseif (is_singular()) {
  192. global $authordata;
  193. $author_obj = $authordata;
  194. } else {
  195. $author_obj = null;
  196. }
  197. if ($author_obj)
  198. $author = array(
  199. 'username' => $author_obj->user_login
  200. , 'name' => $author_obj->display_name
  201. , 'firstname' => get_the_author_meta('first_name', $author_obj->ID)
  202. , 'lastname' => get_the_author_meta('last_name', $author_obj->ID)
  203. , 'nickname' => get_the_author_meta('nickname', $author_obj->ID)
  204. );
  205. else
  206. $author = array(
  207. 'username' => ''
  208. , 'name' => ''
  209. , 'firstname' => ''
  210. , 'lastname' => ''
  211. , 'nickname' => ''
  212. );
  213. $variables = array(
  214. '{blog}' => get_bloginfo('name')
  215. , '{tagline}' => get_bloginfo('description')
  216. , '{post}' => $post_title
  217. , '{page}' => $post_title
  218. , '{page_parent}' => $parent_title
  219. , '{category}' => $cat_title
  220. , '{categories}' => $cat_titles
  221. , '{category_description}' => $cat_desc
  222. , '{tag}' => $tag_title
  223. , '{tag_description}' => $tag_desc
  224. , '{tags}' => su_lang_implode(get_the_tags($post_id), 'name', true)
  225. , '{daynum}' => $daynum
  226. , '{day}' => $day
  227. , '{monthnum}' => $monthnum
  228. , '{month}' => $month
  229. , '{year}' => $year
  230. , '{author}' => $author['name']
  231. , '{author_name}' => $author['name']
  232. , '{author_username}' => $author['username']
  233. , '{author_firstname}' => $author['firstname']
  234. , '{author_lastname}' => $author['lastname']
  235. , '{author_nickname}' => $author['nickname']
  236. , '{query}' => su_esc_attr(get_search_query())
  237. , '{ucquery}' => su_esc_attr(ucwords(get_search_query()))
  238. , '{url_words}' => $this->get_url_words($_SERVER['REQUEST_URI'])
  239. );
  240. $title = str_replace(array_keys($variables), array_values($variables), htmlspecialchars($format));
  241. return $this->get_title_paged($title);
  242. }
  243. function get_title_paged($title) {
  244. global $wp_query, $numpages;
  245. if (is_paged() || get_query_var('page')) {
  246. if (is_paged()) {
  247. $num = absint(get_query_var('paged'));
  248. $max = absint($wp_query->max_num_pages);
  249. } else {
  250. $num = absint(get_query_var('page'));
  251. if (is_singular()) {
  252. $post = $wp_query->get_queried_object();
  253. $max = count(explode('<!--nextpage-->', $post->post_content));
  254. } else
  255. $max = '';
  256. }
  257. return str_replace(
  258. array('{title}', '{num}', '{max}'),
  259. array( $title, $num, $max ),
  260. $this->get_setting('title_paged'));
  261. } else
  262. return $title;
  263. }
  264. function get_url_words($url) {
  265. //Remove any extensions (.html, .php, etc)
  266. $url = preg_replace('|\\.[a-zA-Z]{1,4}$|', ' ', $url);
  267. //Turn slashes to >>
  268. $url = str_replace('/', ' &raquo; ', $url);
  269. //Remove word separators
  270. $url = str_replace(array('.', '/', '-'), ' ', $url);
  271. //Capitalize the first letter of every word
  272. $url = explode(' ', $url);
  273. $url = array_map('trim', $url);
  274. $url = array_map('ucwords', $url);
  275. $url = implode(' ', $url);
  276. $url = trim($url);
  277. return $url;
  278. }
  279. function postmeta_fields($fields) {
  280. $id = "_su_title";
  281. $value = su_esc_attr($this->get_postmeta('title'));
  282. $fields['serp'][10]['title'] =
  283. "<tr class='su textbox' valign='top'>\n<th scope='row' class='su'><label for='$id'>".__('Title Tag:', 'seo-ultimate')."</label></th>\n"
  284. . "<td class='su'><input name='$id' id='$id' type='text' value='$value' class='regular-text' tabindex='2'"
  285. . " onkeyup=\"javascript:document.getElementById('su_title_charcount').innerHTML = document.getElementById('_su_title').value.length\" />"
  286. . "<br />".sprintf(__('You&#8217;ve entered %s characters. Most search engines use up to 70.', 'seo-ultimate'), "<strong id='su_title_charcount'>".strlen($value)."</strong>")
  287. . "</td>\n</tr>\n"
  288. ;
  289. return $fields;
  290. }
  291. function postmeta_help($help) {
  292. $help[] = __('<strong>Title Tag</strong> &mdash; The exact contents of the &lt;title&gt; tag. The title appears in visitors&#8217; title bars and in search engine result titles. If this box is left blank, then the <a href="admin.php?page=su-titles" target="_blank">default post/page titles</a> are used.', 'seo-ultimate');
  293. return $help;
  294. }
  295. function add_help_tabs($screen) {
  296. $screen->add_help_tab(array(
  297. 'id' => 'su-titles-overview'
  298. , 'title' => __('Overview', 'seo-ultimate')
  299. , 'content' => __("
  300. <ul>
  301. <li><strong>What it does:</strong> Title Tag Rewriter helps you customize the contents of your website&#8217;s <code>&lt;title&gt;</code> tags. The tag contents are displayed in web browser title bars and in search engine result pages.</li>
  302. <li><strong>Why it helps:</strong> Proper title rewriting ensures that the keywords in your post/Page titles have greater prominence for search engine spiders and users. This is an important foundation for WordPress SEO.</li>
  303. <li><strong>How to use it:</strong> Title Tag Rewriter enables recommended settings automatically, so you shouldn&#8217;t need to change anything. If you do wish to edit the rewriting formats, you can do so using the textboxes below (the &#8220;Formats & Variables&#8221; help tab includes additional information on this). You also have the option of overriding the <code>&lt;title&gt;</code> tag of an individual post/page/category/tag/etc. using the appropriate tabs below, or by using the &#8220;Title Tag&#8221; textbox that Title Tag Rewriter adds to the post/page editors.</li>
  304. </ul>
  305. ", 'seo-ultimate')));
  306. $screen->add_help_tab(array(
  307. 'id' => 'su-titles-vars'
  308. , 'title' => __('Default Formats Tab', 'seo-ultimate')
  309. , 'content' => __("
  310. <p>Various variables, surrounded in {curly brackets}, are provided for use in the title formats. All settings support the {blog} variable, which is replaced with the name of the blog, and the {tagline} variable, which is replaced with the blog tagline as set under <a href='options-general.php'>Settings &rArr; General</a>.</p>
  311. <p>Here&#8217;s information on each of the settings and its supported variables:</p>
  312. <ul>
  313. <li><strong>Blog Homepage Title</strong> &mdash; Displays on the main blog posts page.</li>
  314. <li>
  315. <p><strong>Post Title Format</strong> &mdash; Displays on single-post pages. Supports these variables:</p>
  316. <ul>
  317. <li>{post} &mdash; The post&#8217;s title.</li>
  318. <li>{category} &mdash; The title of the post category with the lowest ID number.</li>
  319. <li>{categories} &mdash; A natural-language list of the post&#8217;s categories (e.g. &#8220;Category A, Category B, and Category C&#8221;).</li>
  320. <li>{tags} &mdash; A natural-language list of the post's tags (e.g. &#8220;Tag A, Tag B, and Tag C&#8221;).</li>
  321. <li>{author} &mdash; The Display Name of the post's author.</li>
  322. <li>{author_username}, {author_firstname}, {author_lastname}, {author_nickname} &mdash; The username, first name, last name, and nickname of the post&#8217;s author, respectively, as set in his or her profile.</li>
  323. </ul>
  324. </li>
  325. <li>
  326. <p><strong>Page Title Format</strong> &mdash; Displays on WordPress Pages. Supports these variables:
  327. <ul>
  328. <li>{page} &mdash; The page&#8217;s title.</li>
  329. <li>{page_parent} &mdash; The title of the page&#8217;s parent page.</li>
  330. <li>{author} &mdash; The Display Name of the page&#8217;s author.</li>
  331. <li>{author_username}, {author_firstname}, {author_lastname}, {author_nickname} &mdash; The username, first name, last name, and nickname of the page&#8217;s author, respectively, as set in his or her profile.</li>
  332. </ul>
  333. </li>
  334. <li><strong>Category Title Format</strong> &mdash; Displays on category archives. The {category} variable is replaced with the name of the category, and {category_description} is replaced with its description.</li>
  335. <li><strong>Tag Title Format</strong> &mdash; Displays on tag archives. The {tag} variable is replaced with the name of the tag, and {tag_description} is replaced with its description.</li>
  336. <li>
  337. <p><strong>Day Archive Title Format</strong> &mdash; Displays on day archives. Supports these variables:</p>
  338. <ul>
  339. <li>{day} &mdash; The day number, with ordinal suffix, e.g. 23rd</li>
  340. <li>{daynum} &mdash; The two-digit day number, e.g. 23</li>
  341. <li>{month} &mdash; The name of the month, e.g. April</li>
  342. <li>{monthnum} &mdash; The two-digit number of the month, e.g. 04</li>
  343. <li>{year} &mdash; The year, e.g. 2009</li>
  344. </ul>
  345. </li>
  346. <li><strong>Month Archive Title Format</strong> &mdash; Displays on month archives. Supports {month}, {monthnum}, and {year}.</li>
  347. <li><strong>Year Archive Title Format</strong> &mdash; Displays on year archives. Supports the {year} variable.</li>
  348. <li><strong>Author Archive Title Format</strong> &mdash; Displays on author archives. Supports the same author variables as the Post Title Format box, i.e. {author}, {author_username}, {author_firstname}, {author_lastname}, and {author_nickname}.</li>
  349. <li><strong>Search Title Format</strong> &mdash; Displays on the result pages for WordPress&#8217;s blog search function. The {query} variable is replaced with the search query as-is. The {ucwords} variable returns the search query with the first letter of each word capitalized.</li>
  350. <li>
  351. <p><strong>404 Title Format</strong> &mdash; Displays whenever a URL doesn&#8217;t go anywhere. Supports this variable:</p>
  352. <ul>
  353. <li>{url_words} &mdash; The words used in the error-generating URL. The first letter of each word will be capitalized.</li>
  354. </ul>
  355. </li>
  356. <li>
  357. <p><strong>Pagination Title Format</strong> &mdash; Displays whenever the visitor is on a subpage (page 2, page 3, etc.) of the homepage or of an archive. Supports these variables:</p>
  358. <ul>
  359. <li>{title} &mdash; The title that would normally be displayed on page 1</li>
  360. <li>{num} &mdash; The current page number (2, 3, etc.)</li>
  361. <li>{max} &mdash; The total number of subpages available. Would usually be used like this: Page {num} of {max}</li>
  362. </ul>
  363. </li>
  364. </ul>
  365. ", 'seo-ultimate')));
  366. $screen->add_help_tab(array(
  367. 'id' => 'su-titles-settings'
  368. , 'title' => __('Settings Tab', 'seo-ultimate')
  369. , 'content' => __("
  370. <p>Here&#8217;s documentation for the options on the &#8220;Settings&#8221; tab.</p>
  371. <ul>
  372. <li>
  373. <p><strong>Rewrite Method</strong> &mdash; This setting controls the method by which Title Tag Rewriter edits your site&#8217;s <code>&lt;title&gt;</code> tags.</p>
  374. <ul>
  375. <li><strong>Use output buffering</strong> &mdash; This is the &#8220;traditional&#8221; method that most SEO plugins use.
  376. With this method, SEO Ultimate will intercept your site&#8217;s <code>&lt;head&gt;</code> tag section as it&#8217;s being outputted,
  377. locate the <code>&lt;title&gt;</code> tag, edit its value, and then output the edited <code>&lt;head&gt;</code> data.
  378. The good thing about this method is that you don&#8217;t have to edit your theme in any way, as SEO Ultimate will overwrite
  379. whatever your theme puts in your <code>&lt;title&gt;</code> tag. The bad thing is that this output interception takes a few extra
  380. milliseconds to complete. If you are concerned about performance, are comfortable editing your theme&#8217;s header.php file,
  381. and will remember to edit the header.php file of any new themes you activate, you may want to try the filtering rewrite method.</li>
  382. <li>
  383. <p><strong>Use filtering</strong> &mdash; With this method, SEO Ultimate will register itself with WordPress and will replace
  384. WordPress&#8217;s <code>&lt;title&gt;</code> tag output with its own. This method can only edit the text that WordPress itself
  385. generates for the <code>&lt;title&gt;</code> tag; the filtering method can&#8217;t edit anything extra your theme may add.
  386. For this reason, you need to edit your theme to make sure it&#8217;s only pulling <code>&lt;title&gt;</code> tag data from WordPress
  387. and is not adding anything else.</p>
  388. <p>Here&#8217;s how to set up filtering:</p>
  389. <ol>
  390. <li>Go to <a href='theme-editor.php'>Appearance &rArr; Editor</a> (if you get a permissions error, you may be on a WordPress multi-site environment and may not be able to use the filtering rewrite method)</li>
  391. <li>Click &#8220;Header (header.php)&#8221;</li>
  392. <li>Look for the <code>&lt;title&gt;</code> start tag and the <code>&lt;/title&gt;</code> end tag</li>
  393. <li>Edit the text in between those tags so that it looks like this: <code>&lt;title&gt;&lt;?php wp_title(''); ?&gt;&lt;/title&gt;</code></li>
  394. <li>Click &#8220;Update File&#8221;</li>
  395. <li>Return to the &#8220;Settings&#8221; tab of Title Tag Rewriter, select &#8220;Use filtering,&#8221; and click &#8220;Save Changes&#8221;</li>
  396. </ol>
  397. </li>
  398. </ul>
  399. </li>
  400. </ul>
  401. ", 'seo-ultimate')));
  402. $screen->add_help_tab(array(
  403. 'id' => 'su-titles-faq'
  404. , 'title' => __('FAQ', 'seo-ultimate')
  405. , 'content' => __("
  406. <ul>
  407. <li><strong>Does the Title Tag Rewriter edit my post/page titles?</strong><br />No. The Title Tag Rewriter edits the <code>&lt;title&gt;</code> tags of your site, not your post/page titles.</li>
  408. <li><strong>Will rewriting the title tags of my posts change their permalinks/URLs?</strong><br />No.</li>
  409. <li><strong>What&#8217;s the difference between the &#8220;title&#8221; and the &#8220;title tag&#8221; of a post/page?</strong><br />The &#8220;title&#8221; is the title of your post or page that&#8217;s used in your site&#8217;s theme, in your site&#8217;s admin, in your site&#8217;s RSS feeds, and in your site&#8217;s <code>&lt;title&gt;</code> tags. A <code>&lt;title&gt;</code> tag is the title of a specific webpage, and it appears in your browser&#8217;s title bar and in search result listings. Title Tag Rewriter lets you edit your post&#8217;s <code>&lt;title&gt;</code> tags without editing their actual titles. This means you can edit a post&#8217;s title as it appears in search results, but not as it appears on your site.</li>
  410. </ul>
  411. ", 'seo-ultimate')));
  412. $screen->add_help_tab(array(
  413. 'id' => 'su-titles-troubleshooting'
  414. , 'title' => __('Troubleshooting', 'seo-ultimate')
  415. , 'content' => __("
  416. <ul>
  417. <li><strong>Why isn&#8217;t Title Tag Rewriter changing my <code>&lt;title&gt;</code> tags?</strong><br />Try disabling other SEO plugins, as they may be conflicting with SEO Ultimate. If you&#8217;re using the default &#8220;output buffering&#8221; rewrite method, check to make sure your theme is <a href='http://johnlamansky.com/wordpress/theme-plugin-hooks/' target='_blank'>plugin-friendly</a>. If you're using the &#8220;filtering&#8221; rewrite method, check your theme&#8217;s <code>header.php</code> file and make sure the <code>&lt;title&gt;</code> tag looks like this: <code>&lt;title&gt;&lt;?php wp_title(''); ?&gt;&lt;/title&gt;</code>.</li>
  418. </ul>
  419. ", 'seo-ultimate')));
  420. }
  421. }
  422. }
  423. ?>