Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#3522 closed defect (fixed)

Results from cross-project search show escaped html tags

Reported by: kenny Owned by: anonymous
Priority: normal Component: SearchAllPlugin
Severity: normal Keywords: escape characers html
Cc: Trac Release: 0.11


When running the search on all projects, every result which is generated by the plugin looks similar to this:

project1:<span class="closed">#17</span>: task: Some Task (closed: fixed)

The html <span> tags are still visible because they are escaped by Genshi to (from the html-sourcecode):

<dt><a href="/trac/project1/ticket/17" class="searchable">project1: &lt;span class="closed"&gt;#17&lt;/span&gt;: task: Some Task (closed: fixed)</a></dt>

This display can be fixed by removing the literal string conversion from the file and istead using the a "tag" object as return value.

Find attached a diff to show the required modifications.

Attachments (2) (548 bytes) - added by kenny 8 years ago.
Patch for (586 bytes) - added by djs52 8 years ago.
Alternative patch which works with Trac 0.10

Download all attachments as: .zip

Change History (7)

Changed 8 years ago by kenny

Patch for

comment:1 Changed 8 years ago by bobbysmith007

Just wanted to add a note that I applied this patch and it worked for me as well.


Changed 8 years ago by djs52

Alternative patch which works with Trac 0.10

comment:2 Changed 8 years ago by anonymous

  • Owner changed from airadier to anonymous
  • Status changed from new to assigned

comment:3 Changed 8 years ago by airadier

Thanks, does the alternative patch work on both 0.10 and 0.11?

comment:4 Changed 8 years ago by anonymous

  • Resolution set to fixed
  • Status changed from assigned to closed

comment:5 Changed 8 years ago by airadier

(In [5454]) Use Markup to avoid Genshi escaping, closes #3522

Add Comment

Modify Ticket

as closed The owner will remain anonymous.
The resolution will be deleted. Next status will be 'reopened'.

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.