EasyUI
Home
Demo
Tutorial
Documentation
Download
Extension
Contact
Forum
EasyUI Forum
May 21, 2024, 06:24:24 AM
Welcome,
Guest
. Please
login
or
register
.
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News
:
Home
Help
Search
Login
Register
EasyUI Forum
>
General Category
>
General Discussion
>
1.4 tab iframe 刷新两次
Pages: [
1
]
« previous
next »
Print
Author
Topic: 1.4 tab iframe 刷新两次 (Read 12728 times)
wh19890605
Newbie
Posts: 11
1.4 tab iframe 刷新两次
«
on:
August 03, 2014, 06:32:25 PM »
换了1.4版本后,tab里面放了iframe以后,会加载两次,请问如何解决呢?
Logged
gifeu
Newbie
Posts: 2
Re: 1.4 tab iframe 刷新两次
«
Reply #1 on:
September 12, 2014, 12:59:29 AM »
我也一样,抄的网上的add tabs例子,用的是content方式(用href方式是好的,可是href方式在ie6下特别慢,单位都是老机器没法子),后来改了一下就好了,具体就是先不设src属性,等tab创建好了用jquery attr()函数来设
//var content = '<iframe scrolling="auto" frameborder="0" src="' + url + '" style="width:100%;height:100%;"></iframe>'; //wrong 错误的写法
var content = '<iframe scrolling="auto" frameborder="0" id="' + title + '" style="width:100%;height:100%;"></iframe>';//right 正确的写法
$('#tabs').tabs('add', {
title: title,
content: content,
closable: true
});
$("#" + title).attr("src",url); //add this line. 增加这栏
«
Last Edit: September 12, 2014, 01:04:22 AM by gifeu
»
Logged
Pages: [
1
]
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General Category
-----------------------------
=> News
=> General Discussion
=> EasyUI for jQuery
=> EasyUI for Angular
=> EasyUI for Vue
=> EasyUI for React
=> Bug Report
Loading...