-pg电子官方网址入口

/******************************************************************************* * kindeditor - wysiwyg html editor for internet * pg电子平台网站 copyright (c) 2006-2011 kindsoft.net * * @author roddy * @site http://www.kindsoft.net/ * @licence http://www.kindsoft.net/license.php *******************************************************************************/ kindeditor.plugin('link', function(k) { var self = this, name = 'link'; self.plugin.link = { edit : function() { var lang = self.lang(name '.'), html = '
' //url '
' '' '
' //type '
' '' '' '
' '
', dialog = self.createdialog({ name : name, width : 450, title : self.lang(name), body : html, yesbtn : { name : self.lang('yes'), click : function(e) { var url = k.trim(urlbox.val()); if (url == 'http://' || k.invalid) { alert(self.lang('invalidurl')); urlbox[0].focus(); return; } self.exec('createlink', url, typebox.val()).hidedialog().focus(); } } }), div = dialog.div, urlbox = k('input[name="url"]', div), typebox = k('select[name="type"]', div); urlbox.val('http://'); typebox[0].options[0] = new option(lang.newwindow, '_blank'); typebox[0].options[1] = new option(lang.selfwindow, ''); self.cmd.selection(); var a = self.plugin.getselectedlink(); if (a) { self.cmd.range.selectnode(a[0]); self.cmd.select(); urlbox.val(a.attr('data-ke-src')); typebox.val(a.attr('target')); } urlbox[0].focus(); urlbox[0].select(); }, 'delete' : function() { self.exec('unlink', null); } }; self.clicktoolbar(name, self.plugin.link.edit); });
网站地图