Edgewall Software
Modify

Opened 17 years ago

Closed 17 years ago

Last modified 17 years ago

#7154 closed task (fixed)

Link to custom stylesheet removes IE pre-7 hacks

Reported by: bugs@… Owned by: Jonas Borgström
Priority: normal Milestone: not applicable
Component: web frontend Version: 0.11b2
Severity: normal Keywords: genshi iexplorer iexplorer7 xhtml
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

I added a custom stylesheet to path/to/my/trac/env/templates/site.html as documented on TracInterfaceCustomization#SiteAppearance:

<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:py="http://genshi.edgewall.org/" py:strip="">
  <!-- Custom match templates go here -->
<head py:match="head" py:attrs="select('@*')">
    ${select('*')}
    <link rel="stylesheet" type="text/css"
    href="${href.chrome('site/style.css')}" />
</head>
</html>

I took a look at the resultant HTML output and found that the conditional around the IE pre-7 hacks that had been there before had disappeared (as well as most of the lines between the <head> tags being concatenated).

    <!--[if lt IE 7]>
    <script type="text/javascript" src="/~awl03/cgi-bin/trac.cgi/swish/chrome/common/js/ie_pre7_hacks.js"></script>
    <![endif]-->

becomes

    <script type="text/javascript" src="/~awl03/cgi-bin/trac.cgi/swish/chrome/common/js/ie_pre7_hacks.js"></script>

I don't know if this will cause any problems in IE 7 but I assume the conditional was there for a reason.

Setup details: Ubuntu Linux (Feisty: 7.04), Python 2.5, svn, sqlite

Attachments (0)

Change History (5)

comment:1 by Christian Boos, 17 years ago

Resolution: worksforme
Status: newclosed

Thanks for the report, TracInterfaceCustomization#SiteAppearance has been fixed since some times and the select() should be:

...
<head py:match="head" py:attrs="select('@*')">
    ${select('*|comment()|text()')}
...

otherwise the conditional comment will be skipped, as you've noticed.

comment:2 by Christian Boos, 17 years ago

Milestone: 0.11
Resolution: worksforme
Status: closedreopened
Type: defecttask

(but for the time being, the problem is still present on t.e.o itself, re-opening as a reminder)

comment:3 by Noah Kantrowitz, 17 years ago

Milestone: 0.110.11.1
Owner: set to Jonas Borgström
Status: reopenednew

Jonas or Chris should clear this up. Not a release blocker for 0.11, so moving it to 0.11.1.

comment:4 by Jonas Borgström, 17 years ago

Resolution: fixed
Status: newclosed

site.html fixed on t.e.o

comment:5 by Christian Boos, 17 years ago

Milestone: 0.11.1not applicable

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Jonas Borgström.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Jonas Borgström to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.