Bugmonkey script needed: remove 'Fogbugz: ' from HTML <title>s - FogBugz Knowledge Exchange most recent 30 from http://fogbugz.stackexchange.com 2013-05-23T13:49:46Z http://fogbugz.stackexchange.com/feeds/question/2773 http://www.creativecommons.org/licenses/by-nc/2.5/rdf http://fogbugz.stackexchange.com/questions/2773/bugmonkey-script-needed-remove-fogbugz-from-html-titles Bugmonkey script needed: remove 'Fogbugz: ' from HTML <title>s Pavel Radzivilovsky 2010-04-18T07:49:51Z 2010-08-25T16:43:28Z <p>I am new to bugmonkey, so please tell me what's the most proper way to do it?</p> <p>What I want to do, as the title suggests, is to remove the letters "FogBugz: " from titles of wiki and case pages. This is to save space in browser tabs. </p> <p>For example, <code>&lt;title&gt;FogBugz: FMC fault investigation&lt;/title&gt;</code> would become <code>&lt;title&gt;FMC 45 fault investigation&lt;/title&gt;</code></p> <p>Thanks</p> http://fogbugz.stackexchange.com/questions/2773/bugmonkey-script-needed-remove-fogbugz-from-html-titles/2775#2775 Answer by Pavel Radzivilovsky for Bugmonkey script needed: remove 'Fogbugz: ' from HTML <title>s Pavel Radzivilovsky 2010-04-18T17:15:07Z 2010-05-02T17:19:41Z <p>Ok, I solved it</p> <pre><code>// Remove "FogBugz: " from &lt;title&gt; of every page, to be browser-tab-friendly $("title").html($("title").html().substr(8)); </code></pre> http://fogbugz.stackexchange.com/questions/2773/bugmonkey-script-needed-remove-fogbugz-from-html-titles/3259#3259 Answer by Michel de Ruiter for Bugmonkey script needed: remove 'Fogbugz: ' from HTML <title>s Michel de Ruiter 2010-06-07T09:04:04Z 2010-06-10T11:07:01Z <p>Wait, I found the problem with Pavel's code: the title tag cannot contain HTML, so changing the innerHTML is not valid. See for instance <a href="http://code.google.com/p/chromium/issues/detail?id=31534" rel="nofollow" title="Chromium issue 31534">this issue</a>.<br> This code works fine, at least for me:</p> <pre><code>var el = $('title'); el.text(el.text().replace(/FogBugz/i, "")); </code></pre> http://fogbugz.stackexchange.com/questions/2773/bugmonkey-script-needed-remove-fogbugz-from-html-titles/4176#4176 Answer by db for Bugmonkey script needed: remove 'Fogbugz: ' from HTML <title>s db 2010-08-25T16:43:28Z 2010-08-25T16:43:28Z <p>This has been fixed in FogBugz 8 (which is currently in <a href="http://shop.fogcreek.com/beta" rel="nofollow">beta</a>)!</p> <p>The "FogBugz" portion of the page title is now a suffix rather than a prefix.</p>