如何从子IFrame动态修改父页面中的TreeView? [英] How do I dynamically modify a TreeView in the parent page from a child IFrame?

查看:105
本文介绍了如何从子IFrame动态修改父页面中的TreeView?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在父级或基础级上都有一个TreeView菜单,该菜单承载一个IFrame,在该IFrame中加载了与菜单项相对应的内容页面.理想情况下,我的内容页面之一应该动态地在TreeView菜单的部分中插入其自己的上下文项.

我非常怀疑jQuery几乎是我熟悉的唯一工具,我可以在这里使用它,但是有关从何处着手进行此搜索的任何建议将不胜感激.

I have a TreeView menu on a parent or base base that hosts an IFrame in which content pages corresponding to menu items are loaded. Ideally one of my content pages should dymamically insert its own contextual items into it''s section of the TreeView menu.

I have a strong suspicion that jQuery is pretty much the only tool I am familair with that I will be able to use here, but any suggestions as to where to start with this quest will be most appreciated.

推荐答案



如果树视图菜单是动态的(由数据库或任何存储库构成的菜单),那么在这种情况下,您始终可以从内容页面更新存储库并使用javascript代码重新加载父页面:

window.parent.location.reload(true);



window.parent.location.href =``您要加载的网址'';

您可以使用以下代码在内容页面上的存储库更新后始终调用此脚本:

ClientScript.RegisterStartupScript(GetType(),"refreshParentPage","window.parent.location.href =``您要加载的网址'';",true);

希望这对您有帮助...

请让我知道您是否还需要进一步的细化.

谢谢,

阿迪尔...:))
Hi,

If tree view menu is dynamic(formed the menu from data base or any repository) then in that case you can always update the repository from the content page and reload the parent page using javascript code :

window.parent.location.reload(true);

OR

window.parent.location.href = ''Url you want to load'';

you can always call this script after updating the repository on the content page by using the following code:

ClientScript.RegisterStartupScript(GetType(), "refreshParentPage", "window.parent.location.href = ''Url you want to load'';", true);

Hope this will Help...

Pls let me know if you need any thin further on the same.

Thanx,

Adil...:))


这篇关于如何从子IFrame动态修改父页面中的TreeView?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆