Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试使用 PCRE 正则表达式匹配 now-zeit 部署的路由:
"/song/(.*)feed=(?<feedValue>[^&]+)&PzID=(?<itunesIdValue>[^&]+)"
虽然"song/?feed=random&PzID=863"确实有效,但 "song/RANDOMSLUGNAME?feed=random&PzID=863"给出了 404 错误页面。我是正则表达式的新手。如果我做错了什么,谁能告诉我。
"song/?feed=random&PzID=863"
"song/RANDOMSLUGNAME?feed=random&PzID=863"
我能够解决它。这是一个时代问题。查询参数默认转发。所以我只需要做“/song/(.*)”来匹配主网址。