亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? fckxhtml.js

?? 尚學堂科技JAVA系列教程之JAVA系列BBS_2007的講解源代碼
?? JS
字號:
?/*
 * FCKeditor - The text editor for Internet - http://www.fckeditor.net
 * Copyright (C) 2003-2007 Frederico Caldeira Knabben
 *
 * == 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 ==
 *
 * Defines the FCKXHtml object, responsible for the XHTML operations.
 */

var FCKXHtml = new Object() ;

FCKXHtml.CurrentJobNum = 0 ;

FCKXHtml.GetXHTML = function( node, includeNode, format )
{
	FCKXHtmlEntities.Initialize() ;
	
	// Set the correct entity to use for empty blocks.
	this._NbspEntity = ( FCKConfig.ProcessHTMLEntities? 'nbsp' : '#160' ) ;

	// Save the current IsDirty state. The XHTML processor may change the
	// original HTML, dirtying it.
	var bIsDirty = FCK.IsDirty() ;

	this._CreateNode = FCKConfig.ForceStrongEm ? FCKXHtml_CreateNode_StrongEm : FCKXHtml_CreateNode_Normal ;

	// Special blocks are blocks of content that remain untouched during the
	// process. It is used for SCRIPTs and STYLEs.
	FCKXHtml.SpecialBlocks = new Array() ;

	// Create the XML DOMDocument object.
	this.XML = FCKTools.CreateXmlObject( 'DOMDocument' ) ;

	// Add a root element that holds all child nodes.
	this.MainNode = this.XML.appendChild( this.XML.createElement( 'xhtml' ) ) ;

	FCKXHtml.CurrentJobNum++ ;

	if ( includeNode )
		this._AppendNode( this.MainNode, node ) ;
	else
		this._AppendChildNodes( this.MainNode, node, false ) ;

	// Get the resulting XHTML as a string.
	var sXHTML = this._GetMainXmlString() ;

	this.XML = null ;

	// Strip the "XHTML" root node.
	sXHTML = sXHTML.substr( 7, sXHTML.length - 15 ).Trim() ;

	// Remove the trailing <br> added by Gecko.
	// REMOVE: Maybe the following is not anymore necessary because a similar
	// check is made on _AppendNode
	if ( FCKBrowserInfo.IsGecko )
		sXHTML = sXHTML.replace( /<br\/>$/, '' ) ;

	// Add a space in the tags with no closing tags, like <br/> -> <br />
	sXHTML = sXHTML.replace( FCKRegexLib.SpaceNoClose, ' />');

	if ( FCKConfig.ForceSimpleAmpersand )
		sXHTML = sXHTML.replace( FCKRegexLib.ForceSimpleAmpersand, '&' ) ;

	if ( format )
		sXHTML = FCKCodeFormatter.Format( sXHTML ) ;

	// Now we put back the SpecialBlocks contents.
	for ( var i = 0 ; i < FCKXHtml.SpecialBlocks.length ; i++ )
	{
		var oRegex = new RegExp( '___FCKsi___' + i ) ;
		sXHTML = sXHTML.replace( oRegex, FCKXHtml.SpecialBlocks[i] ) ;
	}

	// Replace entities marker with the ampersand.
	sXHTML = sXHTML.replace( FCKRegexLib.GeckoEntitiesMarker, '&' ) ;

	// Restore the IsDirty state if it was not dirty.
	if ( !bIsDirty )
		FCK.ResetIsDirty() ;

	return sXHTML ;
}

FCKXHtml._AppendAttribute = function( xmlNode, attributeName, attributeValue )
{
	try
	{
		if ( attributeValue == undefined || attributeValue == null )
			attributeValue = '' ;
		else if ( attributeValue.replace )
		{
			if ( FCKConfig.ForceSimpleAmpersand )
				attributeValue = attributeValue.replace( /&/g, '___FCKAmp___' ) ;

			// Entities must be replaced in the attribute values.
			attributeValue = attributeValue.replace( FCKXHtmlEntities.EntitiesRegex, FCKXHtml_GetEntity ) ;
		}

		// Create the attribute.
		var oXmlAtt = this.XML.createAttribute( attributeName ) ;
		oXmlAtt.value = attributeValue ;

		// Set the attribute in the node.
		xmlNode.attributes.setNamedItem( oXmlAtt ) ;
	}
	catch (e)
	{}
}

FCKXHtml._AppendChildNodes = function( xmlNode, htmlNode, isBlockElement )
{
	var oNode = htmlNode.firstChild ;

	while ( oNode )
	{
		this._AppendNode( xmlNode, oNode ) ;
		oNode = oNode.nextSibling ;
	}

	// Trim block elements. This is also needed to avoid Firefox leaving extra
	// BRs at the end of them.
	if ( isBlockElement )
		FCKDomTools.TrimNode( xmlNode, true ) ;

	// If the resulting node is empty.
	if ( xmlNode.childNodes.length == 0 )
	{
		if ( isBlockElement && FCKConfig.FillEmptyBlocks )
		{
			this._AppendEntity( xmlNode, this._NbspEntity ) ;
			return xmlNode ;
		}

		var sNodeName = xmlNode.nodeName ;

		// Some inline elements are required to have something inside (span, strong, etc...).
		if ( FCKListsLib.InlineChildReqElements[ sNodeName ] )
			return null ;

		// We can't use short representation of empty elements that are not marked
		// as empty in th XHTML DTD.
		if ( !FCKListsLib.EmptyElements[ sNodeName ] )
			xmlNode.appendChild( this.XML.createTextNode('') ) ;
	}

	return xmlNode ;
}

FCKXHtml._AppendNode = function( xmlNode, htmlNode )
{
	if ( !htmlNode )
		return false ;

	switch ( htmlNode.nodeType )
	{
		// Element Node.
		case 1 :

			// Here we found an element that is not the real element, but a
			// fake one (like the Flash placeholder image), so we must get the real one.
			if ( htmlNode.getAttribute('_fckfakelement') )
				return FCKXHtml._AppendNode( xmlNode, FCK.GetRealElement( htmlNode ) ) ;

			// Mozilla insert custom nodes in the DOM.
			if ( FCKBrowserInfo.IsGecko && htmlNode.hasAttribute('_moz_editor_bogus_node') )
				return false ;

			// This is for elements that are instrumental to FCKeditor and
			// must be removed from the final HTML.
			if ( htmlNode.getAttribute('_fcktemp') )
				return false ;

			// Get the element name.
			var sNodeName = htmlNode.tagName.toLowerCase()  ;

			if ( FCKBrowserInfo.IsIE )
			{
				// IE doens't include the scope name in the nodeName. So, add the namespace.
				if ( htmlNode.scopeName && htmlNode.scopeName != 'HTML' && htmlNode.scopeName != 'FCK' )
					sNodeName = htmlNode.scopeName.toLowerCase() + ':' + sNodeName ;
			}
			else
			{
				if ( sNodeName.StartsWith( 'fck:' ) )
					sNodeName = sNodeName.Remove( 0,4 ) ;
			}

			// Check if the node name is valid, otherwise ignore this tag.
			// If the nodeName starts with a slash, it is a orphan closing tag.
			// On some strange cases, the nodeName is empty, even if the node exists.
			if ( !FCKRegexLib.ElementName.test( sNodeName ) )
				return false ;

			// Remove the <br> if it is a bogus node.
			if ( sNodeName == 'br' && htmlNode.getAttribute( 'type', 2 ) == '_moz' )
				return false ;

			// The already processed nodes must be marked to avoid then to be duplicated (bad formatted HTML).
			// So here, the "mark" is checked... if the element is Ok, then mark it.
			if ( htmlNode._fckxhtmljob && htmlNode._fckxhtmljob == FCKXHtml.CurrentJobNum )
				return false ;

			var oNode = this._CreateNode( sNodeName ) ;

			// Add all attributes.
			FCKXHtml._AppendAttributes( xmlNode, htmlNode, oNode, sNodeName ) ;

			htmlNode._fckxhtmljob = FCKXHtml.CurrentJobNum ;

			// Tag specific processing.
			var oTagProcessor = FCKXHtml.TagProcessors[ sNodeName ] ;

			if ( oTagProcessor )
				oNode = oTagProcessor( oNode, htmlNode, xmlNode ) ;
			else
				oNode = this._AppendChildNodes( oNode, htmlNode, Boolean( FCKListsLib.NonEmptyBlockElements[ sNodeName ] ) ) ;

			if ( !oNode )
				return false ;

			xmlNode.appendChild( oNode ) ;

			break ;

		// Text Node.
		case 3 :
			return this._AppendTextNode( xmlNode, htmlNode.nodeValue.ReplaceNewLineChars(' ') ) ;

		// Comment
		case 8 :
			// IE catches the <!DOTYPE ... > as a comment, but it has no
			// innerHTML, so we can catch it, and ignore it.
			if ( FCKBrowserInfo.IsIE && !htmlNode.innerHTML )
				break ;

			try { xmlNode.appendChild( this.XML.createComment( htmlNode.nodeValue ) ) ; }
			catch (e) { /* Do nothing... probably this is a wrong format comment. */ }
			break ;

		// Unknown Node type.
		default :
			xmlNode.appendChild( this.XML.createComment( "Element not supported - Type: " + htmlNode.nodeType + " Name: " + htmlNode.nodeName ) ) ;
			break ;
	}
	return true ;
}

function FCKXHtml_CreateNode_StrongEm( nodeName )
{
	switch ( nodeName )
	{
		case 'b' :
			nodeName = 'strong' ;
			break ;
		case 'i' :
			nodeName = 'em' ;
			break ;
	}
	return this.XML.createElement( nodeName ) ;
}

function FCKXHtml_CreateNode_Normal( nodeName )
{
	return this.XML.createElement( nodeName ) ;
}

// Append an item to the SpecialBlocks array and returns the tag to be used.
FCKXHtml._AppendSpecialItem = function( item )
{
	return '___FCKsi___' + FCKXHtml.SpecialBlocks.AddItem( item ) ;
}

FCKXHtml._AppendEntity = function( xmlNode, entity )
{
	xmlNode.appendChild( this.XML.createTextNode( '#?-:' + entity + ';' ) ) ;
}

FCKXHtml._AppendTextNode = function( targetNode, textValue )
{
	var bHadText = textValue.length > 0 ;
	if ( bHadText )
		targetNode.appendChild( this.XML.createTextNode( textValue.replace( FCKXHtmlEntities.EntitiesRegex, FCKXHtml_GetEntity ) ) ) ;
	return bHadText ;
}

// Retrieves a entity (internal format) for a given character.
function FCKXHtml_GetEntity( character )
{
	// We cannot simply place the entities in the text, because the XML parser
	// will translate & to &amp;. So we use a temporary marker which is replaced
	// in the end of the processing.
	var sEntity = FCKXHtmlEntities.Entities[ character ] || ( '#' + character.charCodeAt(0) ) ;
	return '#?-:' + sEntity + ';' ;
}

// Remove part of an attribute from a node according to a regExp
FCKXHtml._RemoveAttribute = function( xmlNode, regX, sAttribute )
{
	var oAtt = xmlNode.attributes.getNamedItem( sAttribute ) ;

	if ( oAtt && regX.test( oAtt.nodeValue ) )
	{
		var sValue = oAtt.nodeValue.replace( regX, '' ) ;

		if ( sValue.length == 0 )
			xmlNode.attributes.removeNamedItem( sAttribute ) ;
		else
			oAtt.nodeValue = sValue ;
	}
}

// An object that hold tag specific operations.
FCKXHtml.TagProcessors =
{
	img : function( node, htmlNode )
	{
		// The "ALT" attribute is required in XHTML.
		if ( ! node.attributes.getNamedItem( 'alt' ) )
			FCKXHtml._AppendAttribute( node, 'alt', '' ) ;

		var sSavedUrl = htmlNode.getAttribute( '_fcksavedurl' ) ;
		if ( sSavedUrl != null )
			FCKXHtml._AppendAttribute( node, 'src', sSavedUrl ) ;

		return node ;
	},

	a : function( node, htmlNode )
	{
		// Firefox may create empty tags when deleting the selection in some special cases (SF-BUG 1556878).
		if ( htmlNode.innerHTML.Trim().length == 0 && !htmlNode.name )
			return false ;

		var sSavedUrl = htmlNode.getAttribute( '_fcksavedurl' ) ;
		if ( sSavedUrl != null )
			FCKXHtml._AppendAttribute( node, 'href', sSavedUrl ) ;


		// Anchors with content has been marked with an additional class, now we must remove it.
		if ( FCKBrowserInfo.IsIE )
		{
			FCKXHtml._RemoveAttribute( node, FCKRegexLib.FCK_Class, 'class' ) ;

			// Buggy IE, doesn't copy the name of changed anchors.
			if ( htmlNode.name )
				FCKXHtml._AppendAttribute( node, 'name', htmlNode.name ) ;
		}

		node = FCKXHtml._AppendChildNodes( node, htmlNode, false ) ;

		return node ;
	},

	script : function( node, htmlNode )
	{
		// The "TYPE" attribute is required in XHTML.
		if ( ! node.attributes.getNamedItem( 'type' ) )
			FCKXHtml._AppendAttribute( node, 'type', 'text/javascript' ) ;

		node.appendChild( FCKXHtml.XML.createTextNode( FCKXHtml._AppendSpecialItem( htmlNode.text ) ) ) ;

		return node ;
	},

	style : function( node, htmlNode )
	{
		// The "TYPE" attribute is required in XHTML.
		if ( ! node.attributes.getNamedItem( 'type' ) )
			FCKXHtml._AppendAttribute( node, 'type', 'text/css' ) ;

		node.appendChild( FCKXHtml.XML.createTextNode( FCKXHtml._AppendSpecialItem( htmlNode.innerHTML ) ) ) ;

		return node ;
	},

	title : function( node, htmlNode )
	{
		node.appendChild( FCKXHtml.XML.createTextNode( FCK.EditorDocument.title ) ) ;

		return node ;
	},

	table : function( node, htmlNode )
	{
		// There is a trick to show table borders when border=0. We add to the
		// table class the FCK__ShowTableBorders rule. So now we must remove it.

		if ( FCKBrowserInfo.IsIE )
			FCKXHtml._RemoveAttribute( node, FCKRegexLib.FCK_Class, 'class' ) ;

		node = FCKXHtml._AppendChildNodes( node, htmlNode, false ) ;

		return node ;
	},

	// Fix nested <ul> and <ol>.
	ol : function( node, htmlNode, targetNode )
	{
		if ( htmlNode.innerHTML.Trim().length == 0 )
			return false ;

		var ePSibling = targetNode.lastChild ;

		if ( ePSibling && ePSibling.nodeType == 3 )
			ePSibling = ePSibling.previousSibling ;

		if ( ePSibling && ePSibling.nodeName.toUpperCase() == 'LI' )
		{
			htmlNode._fckxhtmljob = null ;
			FCKXHtml._AppendNode( ePSibling, htmlNode ) ;
			return false ;
		}

		node = FCKXHtml._AppendChildNodes( node, htmlNode ) ;

		return node ;
	},

	span : function( node, htmlNode )
	{
		// Firefox may create empty tags when deleting the selection in some special cases (SF-BUG 1084404).
		if ( htmlNode.innerHTML.length == 0 )
			return false ;

		node = FCKXHtml._AppendChildNodes( node, htmlNode, false ) ;

		return node ;
	},

	// IE loses contents of iframes, and Gecko does give it back HtmlEncoded
	// Note: Opera does lose the content and doesn't provide it in the innerHTML string
	iframe : function( node, htmlNode )
	{
		var sHtml = htmlNode.innerHTML ;

		// Gecko does give back the encoded html
		if ( FCKBrowserInfo.IsGecko )
			sHtml = FCKTools.HTMLDecode( sHtml );
		
		// Remove the saved urls here as the data won't be processed as nodes
		sHtml = sHtml.replace( /\s_fcksavedurl="[^"]*"/g, '' ) ;

		node.appendChild( FCKXHtml.XML.createTextNode( FCKXHtml._AppendSpecialItem( sHtml ) ) ) ;

		return node ;
	}
} ;

FCKXHtml.TagProcessors.ul = FCKXHtml.TagProcessors.ol ;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
99热精品一区二区| 亚洲国产欧美日韩另类综合 | 337p日本欧洲亚洲大胆色噜噜| 亚洲电影一区二区| 欧日韩精品视频| 视频在线观看91| 777亚洲妇女| 国产原创一区二区| 国产亚洲污的网站| 99re在线视频这里只有精品| 日本一区二区三区高清不卡| 成人av影视在线观看| 免费成人在线视频观看| 国产人成一区二区三区影院| 99久久免费视频.com| 一区二区三区欧美| 91精品国产品国语在线不卡| 国产一区二区三区四区在线观看| 综合久久综合久久| 日韩精品一区二区三区四区 | 激情成人午夜视频| 亚洲欧美精品午睡沙发| 欧美精品在线视频| 国产一区二区免费看| 亚洲一卡二卡三卡四卡无卡久久| 91精品欧美综合在线观看最新| 国产精品18久久久久| 亚洲综合在线视频| 欧美成人伊人久久综合网| 久久久久久久久久久99999| 欧美另类久久久品| 26uuu色噜噜精品一区二区| 国产大陆a不卡| 91福利精品视频| 91视频一区二区三区| 欧美日韩精品电影| 26uuu精品一区二区三区四区在线 26uuu精品一区二区在线观看 | 久久久亚洲综合| 亚洲视频一区在线观看| 蜜臀久久99精品久久久画质超高清| 激情文学综合网| 日本精品一级二级| 久久精品欧美一区二区三区麻豆| 亚洲理论在线观看| 精品一区二区三区在线播放| 91视视频在线直接观看在线看网页在线看| 欧美美女bb生活片| 18欧美乱大交hd1984| 久久精品久久久精品美女| 99久久99久久精品国产片果冻| 欧美成人精品高清在线播放 | 欧美国产日韩一二三区| 麻豆精品国产91久久久久久| 色先锋资源久久综合| 国产欧美中文在线| 美腿丝袜亚洲综合| 91精品久久久久久久91蜜桃| 亚洲欧美一区二区不卡| 成人国产精品免费观看动漫| 精品国产一区二区国模嫣然| 亚洲国产欧美在线人成| 91黄色免费观看| 一区二区高清免费观看影视大全| 国产精品888| 国产偷国产偷亚洲高清人白洁| 香蕉av福利精品导航| 欧美伊人久久久久久午夜久久久久| 国产精品国产a| 色综合欧美在线视频区| 亚洲精品美国一| 欧美怡红院视频| 亚洲成人激情av| 欧美一级日韩免费不卡| 人人精品人人爱| 日韩一级大片在线| 国产一区二区伦理片| 中文字幕av不卡| 一本色道久久综合精品竹菊| 亚洲精品国产无套在线观| 欧美日韩国产片| 激情另类小说区图片区视频区| 国产亚洲一区二区三区| 91在线视频在线| 午夜视频久久久久久| 欧美第一区第二区| 成人精品免费看| 亚洲一区在线视频观看| 欧美一区二区三区四区久久| 精品在线你懂的| 国产精品久久一卡二卡| 精品视频在线视频| 国产福利精品导航| 亚洲综合图片区| 日韩精品综合一本久道在线视频| 国产乱人伦偷精品视频免下载| 亚洲精品少妇30p| 欧美不卡视频一区| 在线影视一区二区三区| 国产高清久久久久| 日本不卡不码高清免费观看| 国产性做久久久久久| 欧美一区二区三区系列电影| eeuss鲁片一区二区三区在线观看| 日本女人一区二区三区| 成人免费高清视频在线观看| 蜜臀91精品一区二区三区| 日韩欧美一二三四区| 日韩女优视频免费观看| 久久久久久麻豆| 国产精品久久久久影院亚瑟| **欧美大码日韩| 久久久国产一区二区三区四区小说| 欧美色精品在线视频| 95精品视频在线| 91在线免费播放| 成人精品一区二区三区四区 | 色屁屁一区二区| 99国产精品久久久久| 美女久久久精品| 麻豆精品视频在线观看视频| 日韩激情在线观看| 免费在线视频一区| 麻豆国产欧美日韩综合精品二区 | 中文字幕一区二区三区四区| 亚洲丝袜另类动漫二区| 一区二区三区蜜桃| 三级久久三级久久久| 国模冰冰炮一区二区| 成人综合日日夜夜| 97久久精品人人做人人爽50路| 色综合视频在线观看| 欧美福利一区二区| 欧美国产日本韩| 亚洲综合久久久久| 三级影片在线观看欧美日韩一区二区 | 久久精品一区蜜桃臀影院| 国产精品色哟哟网站| 视频一区二区不卡| 91在线国产福利| 欧美videos中文字幕| 久久久久久久久久久99999| 91精品国产综合久久精品麻豆| 在线观看免费一区| 国产精品欧美综合在线| 韩国女主播一区二区三区| 91精品国产综合久久精品图片 | 亚洲一区二区三区四区五区中文 | 色妹子一区二区| 国产亚洲短视频| 日本美女视频一区二区| 成人免费视频网站在线观看| 欧美情侣在线播放| 中文字幕在线一区免费| 久久99日本精品| 欧美一级黄色录像| 亚洲一二三级电影| 91精品国产高清一区二区三区| 91丝袜美女网| 中文字幕av一区 二区| 国产精品123| 国产精品不卡一区二区三区| jvid福利写真一区二区三区| 日韩一区二区三区在线观看| 午夜精品成人在线| 欧美主播一区二区三区| 亚洲成人精品一区二区| 91精品在线观看入口| 久久99精品国产麻豆婷婷洗澡| 欧美r级电影在线观看| 美女一区二区视频| 日韩欧美三级在线| 日日嗨av一区二区三区四区| 欧美日韩在线直播| 日韩高清不卡一区| 91麻豆精品国产91| 国产在线不卡视频| 中文字幕一区在线观看视频| 99r国产精品| 亚洲一区二区三区在线看| 欧美性受极品xxxx喷水| 亚洲成av人片在线观看| 日韩欧美一区电影| 国产高清不卡一区| 亚洲精品成人在线| 久久夜色精品国产欧美乱极品| 色婷婷精品久久二区二区蜜臀av| 亚洲高清在线视频| 国产精品天干天干在观线| 欧美精品一卡二卡| 欧美午夜电影在线播放| 91一区二区三区在线观看| 成人午夜在线视频| 国产精品一区在线观看你懂的| 免费在线观看精品| 亚洲va韩国va欧美va精品| 一区二区三区四区蜜桃| 亚洲欧洲日产国码二区| 精品剧情v国产在线观看在线| av电影一区二区| 香蕉成人伊视频在线观看|