⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 fckplugin.js

📁 提供给高等院校的教师用来申报国家级精品课程之用。
💻 JS
字号:
/*
 * Media Plugin for FCKeditor 2.5 SVN
 * Copyright (C) 2007 Riceball LEE (riceballl@hotmail.com)
 *
 * == BEGIN LICENSE ==
 *
 * Licensed under the terms of any of the following licenses at your
 * choice:
 *
 *  - GNU General Public License Version 2 or later (the "GPL")
 *    http://www.gnu.org/licenses/gpl.html
 *
 *  - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
 *    http://www.gnu.org/licenses/lgpl.html
 *
 *  - Mozilla Public License Version 1.1 or later (the "MPL")
 *    http://www.mozilla.org/MPL/MPL-1.1.html
 *
 * == END LICENSE ==
 *
 * Plugin to insert "Iframe" in the editor.
 */

// Register the related command.
FCKCommands.RegisterCommand( 'Iframe', new FCKDialogCommand( 'Iframe', FCKLang.DlgIframeTitle, FCKPlugins.Items['Iframe'].Path + 'fck_iframe.html', 450, 280 ) ) ;

// Create the "Media" toolbar button.
var oMediaItem = new FCKToolbarButton( 'Iframe', FCKLang.MediaBtn,  FCKLang.DlgIframeBtnTooltip) ;
oMediaItem.IconPath = FCKPlugins.Items['Iframe'].Path + 'iframe.gif' ;

FCKToolbarItems.RegisterItem( 'Iframe', oMediaItem ) ;

var FCKPlaceholders = new Object() ;

FCKPlaceholders.SetupIframe = function(url, width, height, marginwidth, marginheight, scrolling, border)
{
	var div = FCK.InsertElement( 'div' ) ;
	var myJsVal = "";
	myJsVal+="<iframe border=\""+ border +"\" frameborder=\"0\" framespacing=\"0\" width=\""+ width +"\"  height=\""+ height +"\" marginheight=\""+ marginwidth +"\" marginwidth=\""+ marginheight +"\" scrolling=\""+ scrolling +"\" src=\""+ url +"\" vspale=\"0\" name=\"content\" id=\"content\"><\/iframe>";
	//<iframe border="0" frameborder="0" framespacing="0" height="358" marginheight="0" marginwidth="0" noResize scrolling="auto" src="$it["link"]$" width="100%" vspale="0" name="content" id="content"></iframe>
	div.innerHTML = myJsVal ;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -