我想使用記事本++從css文件中提取圖像URL。 由於所有圖像網址都位於圓括號內,因此我正考慮使用正則表達式來刪除之前(以及之後的所有內容)的所有內容。 這裏是一個文本例如:如何刪除記事本中的圓括號外的所有內容++
text-transform:uppercase;
font-size:17px;
}
.conTxt .btnGiveAccess{
width:532px;
height:145px;
background:url(http://www.website.com/css/images/btn-give-me-access2.jpg) no-repeat center top;
margin:0 auto;
display:block;
}
.conTxt .btnGiveAccess:hover{
background:url(http://www.website.com/css/images/btn-give-me-access2.jpg) no-repeat center -145px;
}
/*#########################################*/
popup window
/*#########################################*/
/*a {
因此,我竟被dlike得到如下:
http://www.website.com/css/images/btn-give-me-access2.jpg
http://www.website.com/css/images/btn-give-me-access2.jpg
我也試過以下的正則表達式之前HTTP刪除一切://
^[^http]*` Also .*((.*)).*
但它沒有工作。有誰可以幫忙嗎?
不完全重複,但可能有所幫助:http://superuser.com/questions/477628/export-all-regular-expression-matches-in-textpad-or-notepad-as-a-list –