]> Lady’s Gitweb - Gitweb/commit
gitweb: Highlight matched part of project name when searching projects
authorJakub Narebski <redacted>
Mon, 27 Feb 2012 01:55:20 +0000 (02:55 +0100)
committerLady <redacted>
Mon, 6 Apr 2026 04:51:32 +0000 (00:51 -0400)
commit8fb8b3b4b444f368efb7d8ab4fab297372e643dd6f582db0ef8d0a5147fa76e5
treeb96c73e7a8a108333e955052f0c06ec8d3f8cfe58f85352cab96bdfd1f417ef8
parent0e8c2e1d97cde0d2549466c258a5b065b80fd03a68d75a5d176626fb725d3ff3
gitweb: Highlight matched part of project name when searching projects

Use esc_html_match_hl() introduced in previous commit to escape HTML
and mark match, using span element with 'match' class.  Currently only
the 'path' part (i.e. the project name) is highlighted; match might be
on the project description.  Highlighting match in description is left
for next commit.

The code makes use of the fact that defined $search_regexp means that
there was search going on.

Signed-off-by: Jakub Narebski <redacted>
Signed-off-by: Junio C Hamano <redacted>
gitweb.perl
This page took 0.257776 seconds and 4 git commands to generate.