Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/regex/18.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

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/joomla/2.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
Regex 简单正则表达式-匹配特定url_Regex_Joomla - Fatal编程技术网

Regex 简单正则表达式-匹配特定url

Regex 简单正则表达式-匹配特定url,regex,joomla,Regex,Joomla,说到正则表达式,我是个笨蛋。我正在使用Joomla和高级模块管理器将模块发布到特定的url 我只想将模块发布到url/tv show,而不是/tv show/anthingthing else/blahblah 我认为这样做的方法是/tv show*,但显然不是这样,因为它仍然在开始时使用/tv show发布到其他URL 我尝试了许多变体,请告诉我哪里出了问题?尝试以下方法 /电视节目$ 美元与字符串的结尾相匹配。太棒了,是的,这很有效:)非常感谢。我在谷歌搜索时确实遇到了这个问题,但假设“字符

说到正则表达式,我是个笨蛋。我正在使用Joomla和高级模块管理器将模块发布到特定的url

我只想将模块发布到url
/tv show
,而不是
/tv show/anthingthing else/blahblah

我认为这样做的方法是
/tv show*
,但显然不是这样,因为它仍然在开始时使用/tv show发布到其他URL

我尝试了许多变体,请告诉我哪里出了问题?

尝试以下方法

/电视节目$

美元与字符串的结尾相匹配。

太棒了,是的,这很有效:)非常感谢。我在谷歌搜索时确实遇到了这个问题,但假设“字符串”是一行代码!,呜呜声。非常感谢:)