Closed Bug 292256 Opened 20 years ago Closed 20 years ago

Search and wildcards

Categories

(addons.mozilla.org Graveyard :: Public Pages, defect)

x86
All
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: Bugzilla-alanjstrBugs, Assigned: Bugzilla-alanjstrBugs)

Details

Attachments

(1 file, 1 obsolete file)

Doing a search for "undo close" should have found the extension named
"undoclosetab".  We should replace the space with a % when doing searches.
Attachment #185999 - Flags: first-review?(cst)
Status: NEW → ASSIGNED
Comment on attachment 185999 [details] [diff] [review]
Use regex to replace whitespace with wildcard

Testing your preg_replace in another file, it fails:

Warning: Unknown modifier '+' in /home/cso01/temp.php on line 4

I'm guessing it fails in this situation too.

The correct format should really be:

preg_replace('/[\s]+/','%',$searchStr)
Attachment #185999 - Flags: first-review?(cst) → first-review-
Attachment #185999 - Attachment is obsolete: true
Attachment #186031 - Flags: first-review?(colin.ogilvie)
Comment on attachment 186031 [details] [diff] [review]
Proper use of preg_replace

Patch works, I can now find the extension mentioned in comment 0...
Attachment #186031 - Flags: first-review?(colin.ogilvie) → first-review+
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Product: addons.mozilla.org → addons.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: