200分寻求代码

[复制链接]
查看11 | 回复0 | 2009-1-30 06:28:38 | 显示全部楼层 |阅读模式
我要寻求一个图文添加代码,如附件中哪种。谢谢了。另外最好说名一下 具体代码应用方法只要如附件中哪样的图文化添加代码程序,别的不要。可别给我一个整站程序,我不要

                                                                                                楼主所以是:eWebSoft在线编辑器可以 www.ewebeditor.net/ 下载免费版。还有详细的说明和实例。楼主看看就明白了。。。                                       
提问者对答案的评价:

                                                                                                <html><head><meta http-equiv="Content-Language" content="zh-cn"><meta http-equiv="Content-Type" content="text/html; charset=gb2312"><meta http-equiv="MSThemeCompatible" content="Yes"><link rel = "Shortcut Icon" href="favicon.ico"><link href="editor/images/css.css" rel="stylesheet" type="text/css"><script language="javascript">if(self!=top){top.location=self.location;}</script><script language="JavaScript"><!--var Format = "Normal";var initHTML = "";var CssFile="";var edit;var RangeType;var CssFile="";var returnValue="";//把iframe中的数据送给表单function posts (theform){        if (theform.title.value==""){        alert("\\"标题\\"不能为空.");        return false;        }        if (theform.sortid.value=="" || theform.sortid.value=="0"){        alert("未选择分类.");        return false;        }        if (document.all||document.getElementById){        for (i=0;i<theform.length;i++){        var tempobj=theform.elements        if(tempobj.type.toLowerCase()=="submit"||tempobj.type.toLowerCase()=="reset")        tempobj.disabled=true        }        }
document.form1.pagetext.value = Editor.document.body.innerHTML;        return true;}//从表单中取数据,用于修改文章时function mr(){
Editor.document.body.innerHTML = document.form1.pagetext.value;}//初始化编辑器function initEditor(Model){
Editor.document.designMode=Model;
Editor.document.open();
initHTML = "";
Editor.document.write(initHTML);
Editor.document.close();
mr();
if(CssFile!="")
{
Editor.document.createStyleSheet(CssFile);
}
Editor.document.body.style.fontFamily = "{defaultfont}";
Editor.document.body.style.fontSize ="12px";}function setFocus(){
Editor.focus();}function fixSize(){
document.all.Editor.style.height = Math.max(document.body.clientHeight - document.all.Editor.offsetTop, 0);}//选择对象function selectRange(){
edit = Editor.document.selection.createRange();
RangeType = Editor.document.selection.type;}function execCommand(command,para){
if (Format == "Normal")
{
setFocus();
selectRange();
if ((command == "Undo") || (command == "Redo"))
{
document.execCommand(command);
}
else
{
if (para=="")
{
edit.execCommand(command);
}
else
{
edit.execCommand(command, false, arguments[1]);
}
Editor.focus();
}
if (RangeType != "Control")
{
edit.select();
}
}}//模式function swapModes(Mode){
switch(Mode)
{
case "Normal":
if (Format == "Html")
{
Editor.document.body.innerHTML = Editor.document.body.innerText;
}
else
{
initHTML = Editor.document.body.innerHTML;
initEditor("On");
}
break;
case "Html":
if (Format == "Preview")
{
initHTML = Editor.document.body.innerHTML;
initEditor("On");
}
Editor.document.body.innerText = Editor.document.body.innerHTML;
break;
default:
var strHTML = "";
if(Format == "Html")
{
initHTML = Editor.document.body.innerText;
}
else
{
initHTML = Editor.document.body.innerHTML;
initEditor("Off");
}
break;
}
Editor.focus();
Format=Mode;}//粘标记function pasteMark(Mark){
var strHTML;
if (Mark==\'\')
{
return(0);
}
setFocus();
selectRange();
var t=Mark.split(" ");
strHTML = "<" + Mark + ">" + edit.text + "</" + t[0] + ">";
if (Format == "Normal")
{
edit.pasteHTML(strHTML);
}
else
{
edit.text=strHTML;
Editor.focus();
edit.select();
}}//粘贴htmlfunction pasteHTML(HTML){
setFocus();
selectRange();
if (Format == "Normal")
{
edit.pasteHTML(HTML);
}
else
{
edit.text=HTML;
}
Editor.focus();
edit.select();}//选择时调用不同的cssfunction Check(t,n){
if(n==1)
{
t.className ="Up";
}
else
{
if(n==2)
{
t.className ="Down";
}
else
{
t.className ="None";
}
}}//插入图片function InsertImage(){
selectRange();
if (RangeType == "Control")
{
Editor.document.execCommand("InsertImage",true);
}
else
{
var image =window.showModalDialog("editor/pic.php","","dialogWidth:450px;dialogHeight:280px;status:no;resizable=yes");
if (image != null)
{
pasteHTML (image);
}
}}//检查浏览器版本function CheckOS(){
if((window.navigator.userAgent.indexOf("IE 5") < 1)&&(window.navigator.userAgent.indexOf("IE 6") < 1))
{
alert("请使用Microsoft Internet Explorer 5.0\\n或更高版本的浏览器!");
window.close();
}}//切换模式function SelectFormat(Status){
swapModes(Status);
switch(Status)
{
case "Normal":                        form1.editorstatus.value = "normal"
Html.style.display="none";
Normal.style.display="block";
break;
case "Html":               
form1.editorstatus.value = "html"
Normal.style.display="none";
Html.style.display="block";
break;
default:               
form1.editorstatus.value = "normal"
Normal.style.display="none";
Html.style.display="block";
break;
}
return(false);}//显示帮助function showHelp(){
showModalDialog("editor/help.php","","dialogWidth:500px;dialogHeight:400px;status:no;");}//添加表格function addTable(){
if(Format!="Preview")
{
ReturnValue=window.showModalDialog("editor/table.php","","dialogWidth=330px;dialogHeight=170px;status=0");
if(ReturnValue && ReturnValue!="")
{
pasteHTML(ReturnValue);
}
}}//添加代码function addCode(){        code = "<table width=\\"100%\\" cellspacing=\\"0\\" cellpadding=\\"10\\" bgcolor=\\"#000000\\" border=\\"1\\" bordercolor=\\"#333333\\" style=\\"border-collapse:collapse;\\"><tr><td width=\\"100%\\" bgcolor=#e6e6e6 style=\\"Courier New;font-size: 12px;\\">code:<br></td></tr></table><br>";        pasteHTML(code);}//添加细线function addLine(){        code = "<hr width=\\"100%\\" size=\\"1\\" color=\\"#333333\\">";        pasteHTML(code);}//完成基本功能function doFormat(what,para,Mark){
selectRange ();        if (Format==\'Normal\')        {                execCommand(what,para);        }        else        {                pasteMark(Mark);        }}//下拉选择function doSelectClick(str,el,Mark){        var Index = el.selectedIndex;        if (Index != 0)        {                el.selectedIndex = 0;                if (Format==\'Normal\' && el.id != "OtherFormat")                {                        doFormat(str,el.options[Index].value);                }                else                {                        pasteMark(Mark);                }        }}//颜色表function SelectColor(id){
var c=window.showModalDialog("editor/colorlist.php",id.style.backgroundColor,"dialogWidth=420px;dialogHeight=360px;status=0");
if(c && c!="")
{
id.style.backgroundColor=c;
}}--></script></head><bodytopmargin=0 leftmargin=0 bgcolor=white text=#000000 link=#000000 vlink=#000000 onload="initEditor(\'ON\');"><center><table border=0 cellpadding=4 cellspacing=0 width=770><tr bgcolor=#878787><td class=p1><img src=./images/next.gif><a class=p1 href=\'http://www.sunser.net/newweb\'>首页</a></td><td class=p1 align=right><a class=p1 href=./login.php?sessid=1aad727546c1aa6de2d14109b26caae2 title="Login">登录</a>¦<a class=p1 href=./register_org.php?sessid=1aad727546c1aa6de2d14109b26caae2 title="Sign up">注册</a>¦<a class=p1 href=./user.php?sessid=1aad727546c1aa6de2d14109b26caae2 title="Modify">修改资料</a>¦<a class=p1 href=./help.php?sessid=1aad727546c1aa6de2d14109b26caae2 title="FAQ">获得帮助</a>¦<a class=p1 href=./login.php?sessid=1aad727546c1aa6de2d14109b26caae2&action=logout title="Logout">退出</a></td></tr></table><table cellpadding=0 cellspacing=0 border=0 width=770 height=17><tr>
<td height="17" valign="middle"><img src="images/title.gif" width="250" height="65">
<img src="../trans.gif" width="17" height="10"><font color="#FF0000" size="4"><strong>文章发布系统</strong></font></td></tr></table><table border=0 cellpadding=4 cellspacing=1 style=\'border-collapse:collapse\' bordercolor=#efefef width=770><tr bgcolor=#878787><td align=center><a class=p1 href=./index.php?sessid=1aad727546c1aa6de2d14109b26caae2>首页</a> ¦<a class=p1 href=./index.php?sessid=1aad727546c1aa6de2d14109b26caae2>文章教程</a> ¦<a class=p1 href=./manage/index.php?sessid=1aad727546c1aa6de2d14109b26caae2>后台管理</a></td></tr></table><title>网站名称</title><table border=0 cellpadding=4 cellspacing=1 width=770><tr bgcolor=#878787><td></td></tr><tr bgcolor=#e7e7e7><td>>> <a href=\'http://www.sunser.net/newweb?sessid=1aad727546c1aa6de2d14109b26caae2\'>网站名称</a> > <a href=\'./index.php?sessid=1aad727546c1aa6de2d14109b26caae2\'>文章教程</a> > <a href=\'./postarticle.php?sessid=1aad727546c1aa6de2d14109b26caae2&sortid=\'>发表文章</a> </td></tr></table><table border="0" cellpadding="0" cellspacing="0" height=20><tr><td height=20></td></tr></table><table border=0 cellpadding=4 cellspacing=1 width=794><col width=25%><col width=75%>
<form name=\'form1\' action=\'\' method=\'POST\' onsubmit="return posts(this);" enctype="multipart/form-data">
<input type=hidden name=action value=\'postarticle\'>
<input type=hidden name=sessid value=\'1aad727546c1aa6de2d14109b26caae2\'>
<tr bgcolor=878787 class=p1>
<td colspan=2>发表文章</td>
</tr>
<tr bgcolor=e3e3e3>                                        

                                                                                                http://www.ewebeditor.net/download_go.asp?id=1下载这个,然后按说明使用就行了
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行