diff options
author | Guy Pyrzak <guy.pyrzak@gmail.com> | 2010-10-03 22:47:02 +0200 |
---|---|---|
committer | Guy Pyrzak <guy.pyrzak@gmail.com> | 2010-10-03 22:47:02 +0200 |
commit | 24640408aca3e552342276cd45361438f5c82d0a (patch) | |
tree | 44cb4b368f191c7c339cfa77c83267100bd8d3f6 /template | |
parent | 71320dae661a8ca351128d917c894b0f8318eaf3 (diff) | |
download | bugzilla-24640408aca3e552342276cd45361438f5c82d0a.tar.gz bugzilla-24640408aca3e552342276cd45361438f5c82d0a.tar.xz |
577720: Use history.replaceState() so that the URL after processing a bug isn't process_bug.cgi, post_bug.cgi, or attachment.cgi
r=mkanat, a=mkanat
https://bugzilla.mozilla.org/show_bug.cgi?id=577720
Diffstat (limited to 'template')
-rw-r--r-- | template/en/default/bug/show-header.html.tmpl | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/template/en/default/bug/show-header.html.tmpl b/template/en/default/bug/show-header.html.tmpl index a17c3201a..9619422ef 100644 --- a/template/en/default/bug/show-header.html.tmpl +++ b/template/en/default/bug/show-header.html.tmpl @@ -32,10 +32,22 @@ [% subheader = filtered_desc %] [% filtered_timestamp = bug.delta_ts FILTER time %] [% title = "$terms.Bug $bug.bug_id – $filtered_desc" %] +[% unfiltered_title = "$terms.Bug $bug.bug_id – $bug.short_desc" %] [% header = "$terms.Bug $bug.bug_id" %] [% header_addl_info = "Last modified: $filtered_timestamp" %] [% yui = ['autocomplete', 'calendar'] %] [% javascript_urls = [ "js/util.js", "js/field.js" ] %] +[% IF ! Bugzilla.cgi.url.match("show_bug.cgi") && bug.defined %] + [% javascript = BLOCK %] + if( history && history.replaceState ) { + history.replaceState( null, + "[% unfiltered_title FILTER js %]", + "show_bug.cgi?id=[% bug.bug_id FILTER js %]" ); + document.title = "[% unfiltered_title FILTER js %]"; + } + [% javascript FILTER none %] + [% END %] +[% END %] [% style_urls = [ "skins/standard/show_bug.css" ] %] [% doc_section = "bug_page.html" %] [% bodyclasses = ['bz_bug', |