开发者

How to match html-comment with preg_match_all (PHP)?

I have this HTML-document:

<!--SETTINGS 
title: This is the title
keywords: dummy, title, longer keyword, another
description: This is the description of the page
 -->

dit is de home dit is de homedit is de homedit is de homedit is de home
dit is de home
dit is de home
dit is de home
dit is de homedit is de homedit is de homedit is de home
dit is de homedit is de homedit is de home

Now, I'd like to match the comment at the beginning. I think my regex-pattern looks like this:

<!--SETTINGS开发者_如何转开发([\s\S])*-->

When I test it in: http://regexr.com?2ucae , everything seems to work like it should. When I put it in PHP, I get an error: Fout 101 (net::ERR_CONNECTION_RESET): Connection lost.

What am I doing wrong?


The error has nothing to do with your regex-pattern

Check your computer for malware and do some research about ERR_CONNECTION_RESET

Example: http://www.google.com/support/forum/p/Chrome/thread?tid=476f762a0f84017f&hl=en

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜