What's the regex to return the following
I need the regex that returns the follow开发者_StackOverflow中文版ing from a webpage's code, I'm searching whithin Dreamweaver in the code of the page:
<body>
**** lines of HTML code (anything)***
<div class="pg">
sorry I'm into a situation that only regex is the solution, i'm so new to it.
You could try something like:
<body>[\s\S]*<div> class="pg">
you need [\s\S]
because .
probably won't match \n
(unless Dreamweaver has a checkbox for multiline mode or something)
精彩评论