正则表达式帮助Google Page Monitor扩展

use*_*880 3 regex monitoring

我正在尝试使用Google Page Monitor扩展程序监控网页的一小部分内容 - https://chrome.google.com/extensions/detail/pemhgklkefakciniebenbfclihhmmfcd

在高级设置下,我可以使用正则表达式或选择器来完成此任务,但需要帮助.在下面的html中,我想监视以下内容,以便更改第4行中的URL或第5行中的文本.感兴趣地接受任何指针.

<div id="rtBtmBox"><div id="sectHead" style="margin-bottom:5px;">
<h3>SLJ's Pick of the Day</h3></div> 
<p align="center">From the&nbsp;March issue</p> 
<p align="center"><a target="_blank" href="http://www.schoollibraryjournal.com/article/CA6723937.html">
<font color="#0000ff"><strong><em>The Summer I Turned Pretty</em></strong><br/>
Run Code Online (Sandbox Code Playgroud)

Max*_*keh 5

太棒了,在StackOverflow的首页上找到关于我自己的扩展的问题.

无论如何,使用选择器更容易.这应该做的工作:#rtBtmBox p:nth-child(3).但是,如果该段落有更多内容,您可能需要不同的内容(如果是这样,请发布或链接整个页面).

可能有效的正则表达式是: <div id="rtBtmBox">[^]*?<a target="_blank" href="([^"]+)"