简体   繁体   English

2sxc:根据EntityId更改页面名称和网址

[英]2sxc: Change Page name and Url based on EntityId

I have a page with the url mysite.com/Bio/eid/nnn which displays the Bio of a person with eid=nnn. 我有一个网址为mysite.com/Bio/eid/nnn的页面,其中显示了eid = nnn的人的个人简历。 This works fine. 这很好。

Now, what I would like is for this page to respond to requests such as: mysite.com/Bio/Bob-Smith. 现在,我希望该页面响应诸如mysite.com/Bio/Bob-Smith之类的请求。

where eid=123 is the eid for Bob Smith, for example. 例如,其中eid = 123是Bob Smith的eid。

Is there any way to do this? 有什么办法吗?

Thanks. 谢谢。

Basically you can filter on any field. 基本上,您可以在任何字段上进行过滤。 The main issue will be ensuring that you have a url-safe field, so it's best to use the string-url field for that and auto-generate a key so Bob Smith becomes bob-smith . 主要问题是确保您具有url-safe字段,因此最好使用string-url字段并自动生成密钥,这样Bob Smith会成为bob-smith

Check out the blog-app as an example. 以博客应用为例。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM