Regex: Get First Param
My Regex:
#\<param name\=\"src\"+.+\"\s\/\>#
The problem is that stops at the second />
but I want just the first <param>
.
<para开发者_运维问答m name="example" src="hello.swf" />
<param name="stuff2" />
So how should I get just the first param?
Probably something like this...
#param name="([a-zA-Z0-9]+)" src="(.*?)"#is
Your result should be in $match[2]
精彩评论