次のツリー構築タブが動的にあります。タブには、ソースがjsonファイルから取得されたiframeがあります。
<script type="text/javascript">
$(function(){
$('#tree_menu').tree({
animate:true,
onClick: function open1(node){
if ($('#tabs').tabs('exists',node.id)){
$('#tabs').tabs('select', node.id);
} else {
$('#tabs').tabs('add',{
title: node.id,
content: "<iframe id='superframe' frameborder='0' width='100%' scrolling='auto' height='99%' src='" + node.attributes.url + "'><iframe>",
closable:true,
tools:[{
iconCls:'icon-mini-refresh',
handler:function(){
alert('refreshing');
$('#superframe').get(0).contentWindow.location.reload();
}
}]
});
}
}
});
$('#tabs').tabs({
onBeforeClose: function(title){
return confirm('Are you sure you want to close ' + title);
}
});
});
</script>
私が達成したいのはタブアイコンです-ミニリフレッシュをクリックして、その特定のタブにiframeをリロードします。上記のコードでこれを行うことができますが、最初に開いたタブでのみ機能します。2番目から、それはもう機能していません。さわやかではありません....グーグルで見つかったすべての可能なiframeリロードメソッドを試しましたが、成功しませんでした。
これを手伝ってくれませんか。どうもありがとう!