Searching in raw XML doesn't work.

Bug #45121 reported by Chris Ball on 2006-05-16
Affects Status Importance Assigned to Milestone
Mozilla Firefox
firefox (Ubuntu)
firefox-3.0 (Ubuntu)

Bug Description

Binary package hint: firefox

Steps to reproduce:

1. Go to
2. C-f gettext
3. You see "Phrase not found", even though the phrase is on the page.

If you "view source", the search then works. It works without "view source" in Fedora Rawhide's firefox. I'm using Dapper's 1.5.dfsg+; the version that works in Fedora also reports its version as

Phil Bull (philbull) wrote :

Thanks for the report.

I can confirm this with the same package version as the reporter. Pressing Ctrl + F and immediately typing 'gettext' highlights a result, but the find bar behaves as though there are no results ('Phrase not found'). The behaviour is observed where the string is between two tags, e.g:

<packagereq type="mandatory">gettext</packagereq>

Here, 'mandatory' is found correctly and 'gettext' is highlighted but not displayed as found.

Changed in firefox:
status: Unconfirmed → Confirmed
Chris Ball (chris-ubuntu) wrote :

It looks like we're seeing different behaviour, then; as well as "phrase not found", I don't see "gettext" highlighted, and the screen doesn't scroll to where "gettext" is on the page -- ie. I'm seeing no difference in behaviour than if the string really wasn't there at all.

Note that 'gettext' is highlighted, but apparently nothing has been found.

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv: Gecko/20060111 Firefox/
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.2; es-ES; rv: Gecko/20060508 Firefox/

When searching in XML content, I only get results in tag names and attributes are found

Reproducible: Always

Steps to Reproduce:
1.Open an URL with XML content in the browser
2.Press Ctrl+F
3.Find some text

Actual Results:
Finds only tag and attribute names.

In this xml fragment:

<mytag b="hello">hi</mytag>

I can find "mytag", "hello" but no "hi"

Expected Results:
Find any kind of content, including text nodes.

Searching in the view source does work

This is wfm with:
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20060728 Firefox/

I can see bug 263049, though.

I can confirm this behavior at

1. Go to
2. C-f gettext
3. You see "Phrase not found", even though the phrase is on the page.

Firefox 2.0

David Farning (dfarning) wrote :

This issue is open upstream.


Changed in firefox:
status: Unknown → Unconfirmed
Alexander Sack (asac) wrote :

upstream bug needs to be confirmed.

Changed in firefox:
assignee: nobody → mozillateam
David Farning (dfarning) on 2007-02-24
Changed in firefox:
assignee: mozillateam → mozilla-bugs

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/2007051502 Firefox/

This WFM. Using the URL in comment #2, I can never get Firefox to the point where it allows you to search tags but not the content between the tags. In fact, I can only reproduce, in certain situations, the opposite behavior (see bug 285594).

Reporter, can you verify whether you still see this specific problem in the latest release of Firefox when using a clean profile?

WFM with
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1) Gecko/20061010 Firefox/2.0
Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20070713 Firefox/

No response for five weeks, WFMs → resolving WORKSFORME.

Feel free to reopen in case it still happens with the latest Firefox and clean profile.

Changed in firefox:
status: New → Invalid
John Vivirito (gnomefreak) wrote :

Is this still a problem for anyone with latest firefox version in ubuntu (version for your version of ubuntu)

Chris Ball (chris-ubuntu) wrote :

Seems fixed in gutsy. This bug could be closed.

Latest versions of Firefox ( have improved the behavior, and finds also text.

But still it doesn't work fully. It searches well, but it searches from the last valid position, even for new search text.

Steps to reproduce:

1) Open this URL:
2) Find "Jane". It is found ok
3) Click with the mouse a few lines later
4) Find "John", it isn't found, because in step we have set the current position to a line after where the match is located.

I think that the current position shouldn't be taken into account for new searches.

Changed in firefox:
status: Invalid → New

David, that's a separate bug (though probably a duplicate). Can you file a new bug report for your comment 6? The bug you filed in comment 0 here has been fixed or is at least working for you now.

Changed in firefox:
status: New → Invalid
Alexander Sack (asac) wrote :

mozilla bug-resport claims that this is fixed (to some degree). Can you confirm that this is the case?

Changed in firefox:
status: Confirmed → In Progress
Alexander Sack (asac) on 2008-10-31
Changed in firefox:
assignee: mozilla-bugs → nobody
status: In Progress → Triaged
Changed in firefox-3.0:
importance: Undecided → Low
status: New → Triaged

 We are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comments. Please reopen it if you can give us the missing information, and don't hesitate to submit bug reports in the future. To reopen the bug report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in firefox-3.0:
status: Triaged → Invalid
Changed in firefox:
status: Triaged → Invalid
Changed in firefox:
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.