问题描述
在侧Silverlight页面,我想重定向到另一个aspx页面在同一个网站,并使用POST方法来发送一些额外的头信息。任何想法如何实现这一点?所有样品AP preciated。 : - )
In side a Silverlight Page, I want to redirect to another aspx page in the same web site and using POST method to send some additional header information. Any ideas how to implement this? Any samples are appreciated. :-)
我使用VSTS2008 +净3.5 + Silverlight的2.0 + C#。
I am using VSTS2008 + .Net 3.5 + Silverlight 2.0 + C#.
在此先感谢,乔治
推荐答案
我的建议是将有能见度=隐藏按钮在页面上,然后使用JavaScript来检索和。点击()它。因此,你可以做一个职位都没有这个人经历的工作:的
My suggestion would be to have a Visibility=hidden Button on the page, and then use javascript to retrieve it and .Click() it. Thus you get to do a post without all the work that this guy went through:http://mentaljetsam.wordpress.com/2008/06/02/using-javascript-to-post-data-between-pages/
特别是考虑到这是一个熊工艺通过JavaScript一个POST-to-ASP.NET,因为ASP.NET需要像视图状态等烦人的事情。
Especially considering it's a bear to craft a POST-to-ASP.NET through javascript, as ASP.NET requires pesky things like viewstate etc.
这篇关于重定向到Silverlight的另一页的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!