无论有或没有“www”,Xbap 应用程序行为都会发生变化。

发布于 2024-12-02 09:57:27 字数 940 浏览 3 评论 0原文

我们正在编写并运行一个 xbap 应用程序。我们使用 URL 参数来更改用户登录时应用程序的行为。为此,我们使用 System.Deployment.Application.ApplicationDeployment.CurrentDeployment.ActivationUri.Query 来获取应用程序中的 URL 参数。

有时(这很难重现),根据 URL 中是否使用 www (即 http://myapp.com/app/App.xbap?para1=parahttp://www.myapp.com/app/App.xbap?para1=para)。我们已与我们的托管提供商核实,他们建议使用不带链接的链接 www,从那时起我们就一直这样做。无论如何,在某些情况下,第一个链接会正常工作,而在某些情况下,它会像没有 URL 参数一样工作(即,如果我转到 http://myapp.com/app/App.xbap< /代码>)。 我们注意到,在这些情况下,将 www (转到 http://www.myapp.com/app/App.xbap?para1=para)添加到 URL将导致所需的行为。我们还注意到,在这些情况下,即使没有发布任何更新,ClickOnce 也会下载/更新一些 xbap 应用程序。

任何有关解决此问题的帮助将不胜感激。我们可以改变什么来保证我们的应用程序始终工作,无论 www没有 www

谢谢

We are writing and running a xbap application. We use URL parameters to change the application's behaviour when the user logs in. To do that we use System.Deployment.Application.ApplicationDeployment.CurrentDeployment.ActivationUri.Query to get the URL parameters in the application.

Sometimes (and this is hard to reproduce), we get different behaviours depending on whether or not we use www in the URL (i.e. http://myapp.com/app/App.xbap?para1=para vs. http://www.myapp.com/app/App.xbap?para1=para). We have checked with our hosting provider and they recommend using links without
www, which we've been doing ever since. Regardless, in some cases, the first link will work just fine and some cases it'll work as if there were no URL parameters (i.e. if I went to http://myapp.com/app/App.xbap).
We have noticed that in these cases, adding www (going to http://www.myapp.com/app/App.xbap?para1=para) to the URL will result in the desired behaviour. We have also noticed that in these cases, ClickOnce will download/update some of the xbap application even though no updates were published.

Any help on resolving this issue would be much appreciated. What can we change to guaranty that our application will always work regardless of www vs. no www?

thx

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文