Help.Web/editor/scripts/source_html_full.htm

(开头部分) 7KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link href="style/editor.css" rel="stylesheet" type="text/css">
<script>
	var sLangDir=dialogArguments.oUtil.langDir;
	document.write("<scr"+"ipt src='language/"+sLangDir+"/source_html.js'></scr"+"ipt>");
</script>
<script>writeTitle()</script>
<script>
function doCmd(sCmd,sOption)
	{
	var oSel=idSource.document.selection.createRange();
	var sType=idSource.document.selection.type;
	var oTarget=(sType=="None"?idSource.document:oSel);
	oTarget.execCommand(sCmd,false,sOption);
	}
function jsReplace(sText, sFind, sReplace)
	{
	var arrTmp = sText.split(sFind);
	if (arrTmp.length > 1) sText = arrTmp.join(sReplace);
	return sText;
	}
var sBodyHeader;
var sBodyFooter;
var sBodyTag;

function bodyOnLoad()
	{
	var oEditor=dialogArguments.oUtil.oEditor;
	var obj = dialogArguments.oUtil.obj;

	var sHTML="";
	sHTML=oEditor.document.documentElement.outerHTML;
	sHTML=jsReplace(sHTML," contentEditable=true","");
	
	if(obj.docType!="")sHTML=obj.docType+"\n"+sHTML;//restore doctype (if any)

	idSource.document.body.innerText=sHTML;
	idSource.document.body.style.cssText="overflow-x:scroll;overflow-y:scroll;white-space:nowrap";

	idSource.document.body.contentEditable=true;	
	idSource.document.body.clearAttributes;
	idSource.document.body.style.marginTop='4';
	idSource.document.body.style.marginLeft='10';
	idSource.document.body.style.fontFamily='Tahoma';
	idSource.document.body.style.fontSize='11px';
	idSource.document.body.style.color='black';
	idSource.document.body.style.background='white';
	idSource.document.body.onkeydown = new Function("doKeyPress(idSource.event)");
	
	doWrap()
	}
function doKeyPress(evt)
	{
	if (evt.keyCode==13)
		{
		var thisSel = document.selection.createRange();
		thisSel.pasteHTML('<br>');
		evt.cancelBubble = true;
后面还有 175 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。