1. Home
  2. Computing & Technology
  3. Web Design / HTML

How To Using Search and Replace in Expression Web

By Jennifer Kyrnin, About.com

Microsoft Expression Web

Microsoft Expression Web

Image courtesy Microsoft

It's easy to use Microsoft Expression Web to do a search and replace over either the current file, or every file in your Web site. And once you're used to using global search and replace, you'll wonder how you ever lived without it.

Difficulty: Easy
Time Required: 5 minutes

Here's How:

  1. To search in one file:
    Open the file to edit in Expression Web.
  2. Go to "Replace" in the "Edit" menu, or click Ctrl-H/Cmd-H.
  3. Type the words to find in the find box and the words to replace in the replace box.
  4. Make sure "Current Page" is selected, and click "Replace". Keep clicking replace until Expression Web has replaced all the instances on the page.
  5. To search across an entire Web site:
    Open Expression Web and open a pre-defined Web site.
  6. In the folder list, highlight the files you'd like to search through.
  7. Go to "Replace" in the "Edit" menu, or click Ctrl-H/Cmd-H.
  8. Type the words to find in the find box and the words to replace in the replace box.
  9. Make sure "Selected page(s)" is selected if you only want to search some of the pages in your Web, "Open page(s)" if you want to search only the files you've got open for editing, or "All pages" if you want to search all pages. Then click "Replace All".
  10. Expression Web will alert you that you won't be able to undo this operation. Click "Yes".
  11. Expression Web will then show you all the places where your search string was found. The results will be displayed in the Find pane below your site window.

Tips:

  1. In order to avoid matching on items that shouldn't be replaced, create a find string that is very specific. For example, the string "in" would be found inside words ("tin", "insider", etc.). You can include parts of your find phrase inside your replace phrase. For example, if you wanted to replace "in the matter of" with "on the matter of", you should include all the words in your search string and replace string. Just searching for "in" will result in every instance of that word being replaced with "on".
  2. Expression Web allows you to select options to narrow down the search:
    • Match case matches the exact upper case or lower case of the text you type in. "In" will not match "in".
    • Find whole word only will match only the word "in" and not "insider" or "tin".
    • Ignore whitespace differences will match phrases where there's a tab or a carriage return between the words, even if your search phrase had just a space.
    • Regular expressions lets you search with wildcard characters.
    • When you search multiple files you can Find in source code. Expression Web will then look for HTML tags as well as text.
  3. You can double click on the results to see what was changed, and make edits.

What You Need:

  • Microsoft Expression Web
More Web Design / HTML How To's

Explore Web Design / HTML

More from About.com

  1. Home
  2. Computing & Technology
  3. Web Design / HTML
  4. HTML Editors and Software
  5. HTML Editors
  6. Expression Web
  7. Expression Web How Tos
  8. Using Search and Replace in Expression Web - Find and Replace Expression Web

©2008 About.com, a part of The New York Times Company.

All rights reserved.