Using regular expressions to find and replace code.

Hi! Semi-newbie coder here.
I'm trying to strip out code from multiple pages, I've tried regular expressions but I'm struggling to understand them. I also need to do it across a LOT of pages, so I need an automated way of doing it.
The best way I can explain is with an analogy:
I want to delete any string of characters that start with c, ends with t and includes anything inbetween, so it would pick up "cat, cut, chat, coconut, can do it" whatever appears in the middle of those.
Except, instead of c and t, I want it to find strings of code starting with <div class="advert" and ending with Vote<br> while picking up everything in between, (including spaces, code, comments, etc.). Then, deletes that whole string including the starting and ending.Is there a regular expression I could use in dreamweaver that could do this? Is there a way to do this at all?

Let me begin by saying I'm a complete idiot with DW's Reg Ex.   I use Search Specific Tag whenever possible.  See screenshot below.
Try this on your Current Document to see if it works. Then make a back-up copy of site before attempting it on Entire Local Site as you cannot "Undo" this process.
Good luck,
Nancy O.

Similar Messages

  • How to use Microsoft Word's Find and Replace with HTML tags?

    Hello to all!
    I'm trying to figure out how to use the find and replace function in Word to replace html tags. I'd like to be able to change something like this:
    <span class="B01-K-ITAL">random text</span>
    To something like this:
    <em>random text</em>
    I want to replace the open and close tags without changing or interfering with the text between the tags. I'm pretty sure I should use wildcards, but I can't figure out how to use them properly.
    Anyone able to lend a hand?

    Here is my latest regular expression with Perl.   I think it matches the spirit of the request in the original post.
    Note, this isn't as easy as you think.  You need to code up the complete set of html rules in you implementation. You need to allow for a certain amount of mal-formed html.
    perl -0660pe 's^<[sS][pP][aA][nN]\s+class="B01-K-ITAL"\s*>(.*?)</[sS][pP][aA][nN]>^<em>$1</em>^gs' i.html >|o.html
    input text
     <html> <head>...</head> <body>I'd like to be able to change something like this: <span class="B01-K-ITAL">#1 one line</span> I want to replace the open and close tags without changing or interfering with the text between the tags. I'm pretty sure I should use wildcards, but I can't figure out how to use them properly. <p>note, this isn't as easy as you think.  You need to code up the complete set of html rules in you implementation. You need to allow for a certain amount of mal-formed html.</p> <span class="B01-K-ITAL">#2 don't be greedy</span> <span class="B01-K-ITAL">$3 multiline text</span> <span class="B01-K-ITAL">#4 multiline tag. I believe html allow a carriage return in white space of tags</span> <span class="B01-K-ITAL">#5 split after the class tag. optional white space</span> <sPan class="B01-K-ITAL">#6 mixed case tag</Span> <p>no text #7</p><span class="B01-K-ITAL"></span> <!-- Apparently, this is valid     http://www.positioniseverything.net/articles/cc-plus.html --> <!--[if IE]> <div id="IEroot"> <![endif]--> <p id="IE">This browser is IE.</p> <p id="notIE">This browser is not IE.</p><!--[if IE]> </div> <![endif]--></body> </html>
    output text
     <html> <head>...</head> <body>I'd like to be able to change something like this: <em>#1 one line</em> I want to replace the open and close tags without changing or interfering with the text between the tags. I'm pretty sure I should use wildcards, but I can't figure out how to use them properly. <p>note, this isn't as easy as you think.  You need to code up the complete set of html rules in you implementation. You need to allow for a certain amount of mal-formed html.</p> <em>#2 don't be greedy</em> <em>$3 multiline text</em> <em>#4 multiline tag. I believe html allow a carriage return in white space of tags</em> <em>#5 split after the class tag. optional white space</em> <em>#6 mixed case tag</em> <p>no text #7</p><em></em> <!-- Apparently, this is valid     http://www.positioniseverything.net/articles/cc-plus.html --> <!--[if IE]> <div id="IEroot"> <![endif]--> <p id="IE">This browser is IE.</p> <p id="notIE">This browser is not IE.</p><!--[if IE]> </div> <![endif]--></body> </html>

  • Unable To Use Regular Expression To Find Function Names

    Hi,
    I am trying to create a regular expression to find function and procedure names without the static designation and the parameter list.  Sample source document:
    static function test
    static function test(i,j)
    function test
    function test(i,j)
    static procedure test
    static procedure test(i,j)
    procedure test
    procedure test(i,j)
    For each of the above samples, I would like only the word "test" to be found.
    Thanks

    I suggest starting with this expression:
    ^\s*(static\s+)?(function|procedure)\s+(?<NAME>\w+)
    Programmatically, the name can be extracted from the group called “NAME”.
    The expression can be improved.

  • Using Regular Expressions to Find Quoted Text

    I have run into a couple problems with the following code.
    1) Slash-Star and Slash-Slash commented text must be ignored.
    2) It does not detect backslashed quotes, or if that backslash is backslashed.
    Can this be accomplished with Regular Expressions, or should I implement this using if/indexOf logic?
    Thank You in advance,
    Brian
        * Finds position of next quoted string in a line
        * of source code.
        * If no strings exist, then a Pointer position of
        * (0,0) is returned.
        * @param startPos position to start search from
        * @param argText  the line of text to search
        * @returns next string position
       public Pointer getQuotedStringPosition(int startPos, String aString) {
          String argText = new String( aString );
          Pattern p = Pattern.compile("[\"][^\"]+[\"]");
          Matcher m = p.matcher( argText.substring(startPos); );
          if( m.find() )
             return new Pointer( m.start() + startPos, m.end() + startPos );
          else
             return new Pointer( 0, 0 ); // indicates nothing was found
       }

    YATArchivist was right about the regular expressions.
    I think I've got it but somebody test it if you want. Let me know what you find.
    I've included a barebones Position class as well...
    import java.util.regex.*;
    import java.io.*;
    import java.util.*;
      @author Joshua A. Logan, Jr.
    public class RegexTest
       private static final String SLASH_SLASH = "(//.*)";
       private static final String SLASH_STAR =
                               "(/\\*(?:[^\\*]|(?:\\*(?!/)))+(\\*/)?)";
       private static final Pattern COMMENT_PATTERN =
                         Pattern.compile( SLASH_SLASH + "|" + SLASH_STAR );
       private static final Pattern QUOTED_STRING_PATTERN =
                      Pattern.compile( "\"  ( (?:(\\\\.) | [^\\\"])*+  )     \"",
                                       Pattern.COMMENTS );
       // Breaking the above regular expression down, you'd have:
       //   "  ( (?: (\\ .)  |  [^\\ "]  ) *+ )   "
       //   ^          ^     ^     ^       ^      ^
       //   |          |     |     |       |      |
       //   1          2     3     4       5      6
       // which matches:
       // 1) The starting quote...
       // Followed by something that is either:
       // 2) some escaped sequence ( e.g. _\n_  or even _\"_ ),
       // 3)                ...or...
       // 4) a character that is neither a _\_ nor a _"_ .
       // 5) Keep searching this as much as possible, w/o giving up
       //                    any found text at the end.
       //        Note: the text found would be in group(1)
       // 6) Finally, find the ending quote!!
       public static Position [] getQuotedStringPosition( final String text )
          Matcher cm = COMMENT_PATTERN.matcher( text ),
                  qm = QUOTED_STRING_PATTERN.matcher( text );
          final int len = text.length();
          int startPos = 0;
          List positions = new ArrayList();
          while ( startPos < len )
             if ( cm.find(startPos) )
                int commStart = cm.start(),
                    commEnd   = cm.end();
                // are we starting @ a comment?
                if ( commStart == startPos )
                   startPos = commEnd;
                else if ( qm.find(startPos) )
                   // Search for unescaped strings in here.
                   int stringStart = qm.start(1),
                       stringEnd   = qm.end(1);
                   // Is the quote start after comment start?
                   if ( stringStart > commStart )
                      startPos = commEnd; // restart search after comment end...
                   else if ( (stringEnd > commEnd) ||
                             (stringEnd < commStart) )
                      // In this case, the "comment" is actually part of
                      // the quoted string. We found a match.
                      positions.add( new Position(text, qm.group(1),
                                                  stringStart,
                                                  stringEnd) );
                      int quoteEnd = qm.end();
                      startPos = quoteEnd;
                   else
                      throw new IllegalStateException( "illegal case" );
                else
                   startPos = commEnd;
             else
                // no comments were found. Search for unescaped strings.
                int quoteEnd = len;
                if ( qm.find( startPos ) ) {
                   quoteEnd = qm.end();
                   positions.add( new Position(text,
                                               qm.group(1),
                                               qm.start(1),
                                               qm.end(1)) );
                startPos = quoteEnd;
          return positions.isEmpty() ? Position.EMPTY_ARRAY
                                     : (Position[])positions.toArray(
                                              Position.EMPTY_ARRAY);
       public static void main( String [] args )
          try
             BufferedReader br = new BufferedReader(
                      new InputStreamReader(System.in) );
             String input = null;
             final String prompt = "\nText (q to quit): ";
             System.out.print( prompt );
             while ( (input = br.readLine()) != null )
                if ( input.equals("q") ) return;
                Position [] matches = getQuotedStringPosition( input );
                // What does it do?
                for ( int i = 0, max = matches.length; i < max; i++ )
                   System.out.println( "-->" + matches[i] );
                System.out.print( prompt );
          catch ( Exception e )
             System.out.println ( "Exception caught: " + e.getMessage () );
    class Position
       public Position( String target,
                        String match,
                        int start,
                        int end )
          this.target = target;
          this.match = match;
          this.start = start;
          this.end = end;
       public String toString()
          return "match==" + match + ",{" + start + "," + end + "}";
       final String target;
       final int start;
       final int end;
       final String match;
       public static final Position [] EMPTY_ARRAY = { };
    }

  • How to use regular expression to find string

    hi,
    who know how to get all digits from the string "Alerts 4520 ( 227550 )  (  98 Available  )" by regular expression, thanks
    br, Andrew

    Liu,
    You can use RegEx as   
    d+
    Whether you are using CL_ABAP_REGEX class then
    report  zars.
    data: regex   type ref to cl_abap_regex,
          matcher type ref to cl_abap_matcher,
          match   type c length 1.
    create object regex exporting pattern = 'd+'
                                  ignore_case = ''.
    matcher = regex->create_matcher( text = 'Test123tes456' ).
    match = matcher->match( ).
    write match
    You can find more details regarding REGEX and POSIX examples here
    http://www.regular-expressions.info/tutorial.html

  • Find/Replace Using Regular Expressions

    Can someone help me with this...I am using Regular expressions to
    FIND:
    http.*lid=([^&"]*)[^"]*
    REPLACE:
    $set(\1,ID_id,code)$
    So that in the following it will change this:
    a href="http://www.test.com/shc/s/home_10153_12605?lid=Search" rilt="Search"
    To this:
    a href="$set(Search,ID_id,code)$" rilt="Search
    Those expressions  work in Notepad++ but when i use dreamweaver it just replaces the http... with "$set(\1,ID_id,code)$" and doesnt reference the "search"
    Any help?
    Thanks

    Let me begin by saying I'm a complete idiot with DW's Reg Ex.   I use Search Specific Tag whenever possible.  See screenshot below.
    Try this on your Current Document to see if it works. Then make a back-up copy of site before attempting it on Entire Local Site as you cannot "Undo" this process.
    Good luck,
    Nancy O.

  • [Forum FAQ] How to find and replace text strings in the shapes in Excel using Windows PowerShell

    Windows PowerShell is a powerful command tool and we can use it for management and operations. In this article we introduce the detailed steps to use Windows PowerShell to find and replace test string in the
    shapes in Excel Object.
    Since the Excel.Application
    is available for representing the entire Microsoft Excel application, we can invoke the relevant Properties and Methods to help us to
    interact with Excel document.
    The figure below is an excel file:
    Figure 1.
    You can use the PowerShell script below to list the text in the shapes and replace the text string to “text”:
    $text = “text1”,”text2”,”text3”,”text3”
    $Excel 
    = New-Object -ComObject Excel.Application
    $Excel.visible = $true
    $Workbook 
    = $Excel.workbooks.open("d:\shape.xlsx")      
    #Open the excel file
    $Worksheet 
    = $Workbook.Worksheets.Item("shapes")       
    #Open the worksheet named "shapes"
    $shape = $Worksheet.Shapes      
    # Get all the shapes
    $i=0      
    # This number is used to replace the text in sequence as the variable “$text”
    Foreach ($sh in $shape){
    $sh.TextFrame.Characters().text  
    # Get the textbox in the shape
    $sh.TextFrame.Characters().text = 
    $text[$i++]       
    #Change the value of the textbox in the shape one by one
    $WorkBook.Save()              
    #Save workbook in excel
    $WorkBook.Close()             
    #Close workbook in excel
    [void]$excel.quit()           
    #Quit Excel
    Before invoking the methods and properties, we can use the cmdlet “Get-Member” to list the available methods.
    Besides, we can also find the documents about these methods and properties in MSDN:
    Workbook.Worksheets Property (Excel):
    http://msdn.microsoft.com/en-us/library/office/ff835542(v=office.15).aspx
    Worksheet.Shapes Property:
    http://msdn.microsoft.com/en-us/library/office/ff821817(v=office.15).aspx
    Shape.TextFrame Property:
    http://msdn.microsoft.com/en-us/library/office/ff839162(v=office.15).aspx
    TextFrame.Characters Method (Excel):
    http://msdn.microsoft.com/en-us/library/office/ff195027(v=office.15).aspx
    Characters.Text Property (Excel):
    http://msdn.microsoft.com/en-us/library/office/ff838596(v=office.15).aspx
    After running the script above, we can see the changes in the figure below:
    Figure 2.
    Please click to vote if the post helps you. This can be beneficial to other community members reading the thread.

    Thank you for the information, but does this thread really need to be stuck to the top of the forum?
    If there must be a sticky, I'd rather see a link to a page on the wiki that has links to all of these ForumFAQ posts.
    EDIT: I see this is no longer stuck to the top of the forum, thank you.
    Don't retire TechNet! -
    (Don't give up yet - 13,085+ strong and growing)

  • Rename Layers: Find and Replace style renaming

    In Illustrator, you can use the following to find and replace layer names:
    var doc = app.activeDocument; 
    // name indexed object 
    var layernames = { 
    'Bob':'Bob Front'
    // loop through all layers 
    for (var i = 0; i < doc.layers.length; i++) 
    //Set up Variable to access layer name 
    var currentLayer = app.activeDocument.layers[i]; 
    if (layernames[currentLayer.name]) 
      currentLayer.name = layernames[currentLayer.name]; 
    In this script "Bob" will become "Bob Front". Is there something similar for Photoshop. Looking at the Photoshop scripting guide, this script should work as the active App document and layers methods exist in Photoshop.

    c.pfaffenbichler wrote:
    What are
    var layernames = {
    'Bob':'Bob Front'
    and
    if (layernames[currentLayer.name])
    supposed to do? Is that even JavaScript? …
    Hi c.pfaffenbichler, yes, this is pure Javascript.
    Try this little example:
    var layernames = {'Bob':'Bob Behind'};
    alert(layernames['Bob']);
    // a variant
    layernames['Bob'] = 'Bob in the middle';
    alert("a variant:  " + layernames['Bob']);
    // another variant
    layernames.Bob = 'Bob Front';
    alert("another variant:  " + layernames.Bob);
    @big_smile,
    your posted script works with photoshop (if you have only artlayers and one or more layers named with Bob)
    var doc = app.activeDocument;
    // name indexed object
    var layernames = {'Bob':'Bob Front'};
    // loop through all layers
    for (var i = 0; i < doc.layers.length; i++) {
        //Set up Variable to access layer name
        var currentLayer = app.activeDocument.layers[i];
        if (layernames[currentLayer.name]) {
            currentLayer.name = layernames[currentLayer.name];
    All you have to do is to loop trough all artlayers (and layersets), but here is Javascript a slowly variant. Use ActionManager code instead. You will find many examples here in forum.
    Have fun

  • Find and Replace Across Multiple Sites

    Hi,
    Just wondering if anyone knows a way or a piece of software
    that enables you
    to Find and Replace code, text etc across multiple sites?
    I am using DWMX2004 and I can do it on a per site basis but
    not multiple
    sites at once.
    Any idea's???
    Thanks
    Darrell....

    Alan wrote:
    > IF these dreamweaver sites are all in a common folder,
    like
    > sites:siteA and sites:siteB and so on- You could make a
    new dw site that
    > has the common root folder "sites" as it's Local folder.
    Find and Replace
    > sitewide while in that site would effect all the files
    within the defined
    > folder.
    You don't have to define a site, Blue, just select a folder
    to search.
    Mick
    >
    > also, other text editors have good find and replace
    features.
    >
    > back up, back up, and then make another back up copy.
    >
    > If working with links in this "super site" definition-
    be aware of the
    > possible problems of defining a site where the root
    isn't the real root.
    >
    >
    >>Just wondering if anyone knows a way or a piece of
    software that enables you
    >>to Find and Replace code, text etc across multiple
    sites?
    >
    >
    >

  • Find and Replace across multiple topics

    I haven't used RoboHTML in a few years and am getting back to using it again. this is a fairly simple question, but the Help for RoboHelp doesn't seem to provide an answer.
      How do you do a simple find and replace across multiple topics?  I want to search for a text string and replace it with another text string.

    Hi,
    Have you tried to use the "Multiple File Find and Replace" option present in RoboHelp. You may access this option from Edit->Find and Replace in Files.
    Before trying to find the files, please ensure that the where field in the dialog points to the correct location of your project.
    Thanks

  • Regular Expressions find and replace

    Hi ,
    I have a question on using Regular Expressions in Java(java.util.regex).
    Problem Description:
    I have a string (say for example strHTML) which contains the whole HTML code of a webpage. I want to be able to search for all the image source tags and check whether they are absolute urls to the image source(for eg. <img src="www.google.com/images/logo.gif" >) or relative(for eg. <img src="../images/logo.gif" >).
    If they are realtive urls to the image path, then I wish to replace them with their absolute urls throughout the webpage(in this case inside string strHTML).
    I have to do it inside a servlet and hence have to use java.
    I tried . This is the code. It doesn't match and replace and goes inside an infinite loop i.e probably the pattern matches everything.
    //Change all images to actual http addresses FOR example change src="../images/logo.gif" to src="http://www.google.com/../images/logo.gif"
              String ddurl="http://www.google.com/";
    String strHTML=" < img src=\"../images/logo.gif\" alt=\"Google logo\">";
    Pattern p = Pattern.compile ("(?i)src[\\s]*=[\\s]*[\"\']([./]*.*)[\"\']");
    Matcher m = p.matcher (strHTML);
    while(m.find())
    m.replaceAll(ddurl+m.group(1));
    what is wrong in this?
    Thanks,
    Rajiv

    Right, here's the full monte (whatever that means):import java.util.regex.*;
    public class Test1
      public static void main(String[] args)
        String domain = "http://www.google.com/";
        String strHTML =
          " < img src=\"images/logo.gif\" alt=\"Google logo\">\n" +
          " <img alt=\"Google logo\" src=images/logo.gif >\n" +
          " <IMG SRC=\"/images/logo.gif\" alt=\"Google logo\">\n" +
          " <img alt=\"Google logo\" src=../images/logo.gif>\n" +
          " <img src=http://www.yahoo.com/images/logo.gif alt=\"Yahoo logo\">";
        String regex =
          "(<\\s*img.+?src\\s*=\\s*)   # Capture preliminaries in $1.  \n" +
          "(?:                         # First look for URL in quotes. \n" +
          "   ([\"\'])                 #   Capture open quote in $2.   \n" +
          "   (?!http:)                #   If it isn't absolute...     \n" +
          "   /?(.+?)                  #    ...capture URL in $3       \n" +
          "   \\2                      #   Match the closing quote     \n" +
          " |                          # Look for non-quoted URL.      \n" +
          "   (?!http:)                #   If it isn't absolute...     \n" +
          "   /?([^\\s>]+)             #    ...capture URL in $4       \n" +
        Pattern p = Pattern.compile(regex, Pattern.CASE_INSENSITIVE | Pattern.COMMENTS);
        Matcher m = p.matcher(strHTML);
        StringBuffer sbuf = new StringBuffer();
        while (m.find())
          String relURL = m.group(3) != null ? m.group(3) : m.group(4);
          m.appendReplacement(sbuf, "$1\"" + domain + relURL + "\"");
        m.appendTail(sbuf);
        System.out.println(sbuf.toString());
    }First off, observe that I'm using free-spacing (or "COMMENTS") mode to make the regex easier to read--all the whitespace and comments will be ignored by the Pattern compiler. I also used the CASE_INSENSITIVE flag instead of an embedded (?i), just to remove some clutter. By the way, your second (?i) was redundant; the first one would remain in effect until "turned off" with a (?-i). Another way to localize a flag's effect by using it within a non-capturing group, e.g., (?i:img).
    As jaylogan said, the best way to filter out absolute URL's is by using a negative lookahead, and that's what I've done here. The problem of optional quotes I addressed by trying to match first with quotes, then without. The all-in-one approach might work with URL's, since they can't (AFAIK) contain whitespace anyway, but the alternation method can be used to match any attribute/value pair. It's also, I feel, easier to understand and maintain. Unfortunately, it also means that you can't use replaceAll(), since you have to determine which alternative matched before doing the replacement, but the long version is still pretty simple (especially when you can just copy it from the javadoc for the appendReplacement() method, as I did).

  • Regular Expression Find and Replace with Wildcards

    Hi!
    For the world of me, I can't figure out the right way to do this.
    I basically have a list of last names, first names. I want the last name to have a different css style than the first name.
    So this is what I have now:
    <b>AAGAARD, TODD, S.</b><br>
    <b>AAMOT, KARI,</b> <br>
    <b>AARON, MARJORIE, C. </b> <br>
    and this is what I need to have:
    <span class="LastName">AAGAARD</span>  <span class="FirstName">, TODD, S. </span> <br />
    <span class="LastName">AAMOT</span> <span class="FirstName">, KARI,</span> <br/>
    <span class="LastName">AARON</span> <span class="FirstName">, MARJORIE, C.</span> <br/>
    Any ideas?
    Thanks!

    Make a backup first.
    In the Find field use:
    <b>(\w+),\s+([^<]+)<\/b>\s*<br>
    In the Replace field use:
    <span class="LastName">$1</span> <span classs="FirstName">$2</span><br />
    Select Use regular expression. Light the blue touch paper, and click Replace All.

  • Find text using regular expression and add highlight annotation

    Hi Friends
                       Is it possible to find text using regular expression and add highlight annotation using plugin

    A plugin can use the PDWordFinder to get a list of the words on a page, and their location. That's all that the API offers for searching. Of course, you can use a regular expression library to work with that word list.

  • Regular Expression + Find and Replace

    Hey there-  I have a question about regExp and the Find and Replace.  Basically I want to search a wildcard between a href tag, how would that look, because the code below does not work.
    countryLink = "<a href=\"http://www.whateve.com\" target=\"_parent\">";
    [code]
    countryLink = "([^"]*)";
    [code]
    Thanks! Any help is appreciated!
    Also, how do i add code blocks to this forum?

    Yes, I meant the <a> tag, but thank you for displaying the href attribute solution as well.  This solved my issue.  Thanks!  Thought I would display what I did with your code incase someone was interested in using this code to convert a javascript string to XML.
    query this:
    countryLink = "<a href=\"http://www.whateve.com\" target=\"_blank\">";
    add this to the Find box:
    countryLink = "<a href=\\"([-\w:/.?=&;]+)\\" target=\\"_parent\\">";
    add this to the Replace box:
    <countryLink>$1</countryLink>
    creates an output of this:
    <countryLink>http://www.whateve.com</countryLink>

  • Find and Replace using Wildcards

    I am following the procedure outlined in Trent’s Blog:
    http://www.trentmueller.com/blog/search-and-replace-wildcard-characters-in-dreamweaver.htm l
    This is fantastic stuff and will really help me.
    I have a few (but only a few) times had success.
    It says to “Use regular expression.”  What does that mean?  What is an “irregular expression?”  I have tried with the box checked and unchecked.  Usually with the box checked it will not Find my string.  I uncheck the box and it sometimes does.
    Example:
    Link to    www.schembs.com/TEST_jds_1.html
    At the moment all the Cases are identical.  I have not uploaded the .css to the site so the right-most formating is not properly displaying.  It does work when the .css is available.
    In the source code I literally copy the line of code:
    <p class="type_X"><u>Joh. Heinrich Sch&ouml;m (1713-1785) <span  class="right-most">1.</span></u></p>
    and paste it into the Find box of F&R.  I then put my cursor above the line and it does not Find it, giving me the “Done.  Not found in current document.” response.  I uncheck the “Use regular expression” box and it will find it.
    THEN,
    I try using a wildcard (with the box checked), Finding:
    <p class="type_X">([^<]*)< p>
    or
    <p class="type_X">[^”]*< p>
    and it will find the misc. lines, e.g. where the text is “Case #1”, but not the lines of interest, with Heinrich’s name.  With the box unchecked it Finds nothing.
    Really would appreciate help.  Thanks.
    jds

    jds zigzag wrote:
    It says to “Use regular expression.”  What does that mean?
    A regular expression is a pattern for matching text. It uses a combination of literal characters and special symbols or sequences of characters (technically called metacharacters or metasequences) to represent such things as the beginning and end of a line or any alphanumeric character. For example, \d represents any number (single digit), \d* represents zero or more numbers in sequence.
    I have written a tutorial series on using regular expressions in Dreamweaver here: http://www.adobe.com/devnet/dreamweaver/articles/regular_expressions_pt1.html.
    I try using a wildcard (with the box checked), Finding: 
    <p class="type_X">([^<]*)< p>
    or
    <p class="type_X">[^”]*< p>
    They're not wildcards, but regular expressions. The first part matches the literal characters <p class="type_X">. The next sections use metacharacters.
    ([^<]*) matches zero or more characters (and as many as possible) that don't include an opening angle bracket (<). The parentheses "capture" the value that's matched so it can be used in a replace sequence.
    [^"]* matches zero or more characters (and as many as possible) that don't include a double quote. There are no parentheses, so the value is not captured for reuse.
    The closing <p> matches those literal characters.
    Regular expressions are not easy, but they're extremely powerful, and a good skill to acquire.

Maybe you are looking for

  • Moving from Exchange 2007 to 2013 (leaving the DNS Server for it's own dedicated server)

    Hello! I am quite new to Exchange and Server management in general. I will do my best to explain my situation. I am looking to move my Exchange server off of our DNS server. When we installed them on the same server, we did not have the funds to buy

  • How to add content source in office 365 ?

    How to add content source in office 365 , where I can add find Manage Content Sources page to click on New Content Source LInk

  • Extracting Purchase order details

    Hai All,            I am workng on a report in which I have to display the purchase order and GRN details for a given Purchase Requisition number. If the PR has 5 line items and PO is made only for 2 line items, then the purchase order details for on

  • May have a virus...help please

    So I pay WoW and pretty much like 5 minutes ago i was hacked...i remember accidently going to a weird website and a pop up came up and i knew it wasnt good so i backed out...anyways, im fairly new to macs and i heard that macs rarely if ever get a a

  • CL_ABAP_TYPEDESCR

    If I create a user defined type with reference to a DDIC object I can obtain the list of fields in the user defined type and the obsolute name which contains the user defined type by calling method describe_by_data of class cl_abap_structdescr at run