Don't append created iframe to document if it's going to be appended to a dialog - skip redundant http request + small CS improvements

pull/250/head
Aleksander Machniak 10 years ago
parent 58e184b022
commit 63e4989aa5

@ -1138,14 +1138,11 @@ function rcube_mail_ui()
*/
function show_about(elem)
{
var frame = $('<iframe>').attr('id', 'aboutframe')
.attr('src', rcmail.url('settings/about'))
.attr('frameborder', '0')
.appendTo(document.body);
var h = Math.floor($(window).height() * 0.75);
var buttons = {};
var supportln = $('#supportlink');
var frame = $('<iframe>').attr({id: 'aboutframe', src: rcmail.url('settings/about'), frameborder: '0'});
h = Math.floor($(window).height() * 0.75),
buttons = {},
supportln = $('#supportlink');
if (supportln.length && (env.supporturl = supportln.attr('href')))
buttons[supportln.html()] = function(e){ env.supporturl.indexOf('mailto:') < 0 ? window.open(env.supporturl) : location.href = env.supporturl };

Loading…
Cancel
Save