Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/280.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php Indefinity google搜索页面的正则表达式_Php_Regex - Fatal编程技术网

Php Indefinity google搜索页面的正则表达式

Php Indefinity google搜索页面的正则表达式,php,regex,Php,Regex,我想用正则表达式来识别url是google搜索主页还是搜索结果页面 您可以使用以下内容: (https?:\/\/www\.google\.(?:(?:com)|(?:co\.in)).*#q=.+) 谷歌搜索结果的url 因为在谷歌中,搜索的单词会出现在q之后= 说明: 你为此做了什么。?

我想用正则表达式来识别url是google搜索主页还是搜索结果页面

您可以使用以下内容:

(https?:\/\/www\.google\.(?:(?:com)|(?:co\.in)).*#q=.+)
谷歌搜索结果的url

因为在谷歌中,搜索的单词会出现在q之后=

说明:


你为此做了什么。?