上一篇文章 :: 下一篇文章 |
發表人 |
內容 |
cjs 一級
註冊時間: 2002-04-11 文章: 26 來自: 中華民國
|
發表於: 星期四 六月 12, 2003 4:40 pm 文章標題: 能否請尊龍大大教一下如何利用webeditor? |
|
|
很高興在新版的mailD中看到htmlarea
我曾上htmlarea的網站下載3.0版來使用
很可惜英文能力不佳的我,看不懂要如何加代換到
我的留言版的<textarea>上,請您教一教我好嗎?謝謝! |
|
回頂端 |
|
|
jasoncash 十段
註冊時間: 2002-08-15 文章: 231 來自: 中華民國
|
發表於: 星期四 六月 12, 2003 6:32 pm 文章標題: |
|
|
基本上它檔案內就有範例了. 只是紅字的地方要改
(或者說,紅字部份是我自己加的)
<html><head><title>htmlArea Example</title>
<style type="text/css"><!--
body, td { font-family: arial; font-size: x-small; }
a { color: #0000BB; text-decoration: none; }
a:hover { color: #FF0000; text-decoration: underline; }
.headline { font-family: arial black, arial; font-size: 28px; letter-spacing: -1px; }
.headline2{ font-family: verdana, arial; font-size: 12px; }
.subhead { font-family: arial, arial; font-size: 18px; font-weight: bold; font-style: italic; }
.backtotop { font-family: arial, arial; font-size: xx-small; }
.code { background-color: #EEEEEE; font-family: Courier New; font-size: x-small;
margin: 5px 0px 5px 0px; padding: 5px;
border: black 1px dotted;
}
font { font-family: arial black, arial; font-size: 28px; letter-spacing: -1px; }
--></style>
<script language="Javascript1.2"><!-- // load htmlarea
_editor_url = ""; // URL to htmlarea files
var win_ie_ver = parseFloat(navigator.appVersion.split("MSIE")[1]);
if (navigator.userAgent.indexOf(''Mac'') >= 0) { win_ie_ver = 0; }
if (navigator.userAgent.indexOf(''Windows CE'') >= 0) { win_ie_ver = 0; }
if (navigator.userAgent.indexOf(''Opera'') >= 0) { win_ie_ver = 0; }
if (win_ie_ver >= 5.5) {
document.write(''<scr'' + ''ipt src="'' +_editor_url+ ''editor.js"'');
document.write('' language="Javascript1.2"></scr'' + ''ipt>'');
} else { document.write(''<scr''+''ipt>function editor_generate() { return false; }</scr''+''ipt>''); }
// --></script>
</head>
<body bgcolor="#EEEEEE" >
<a name="top"></a>
<div align="center">
<table border="0" width="100%" style="border-collapse: collapse" bordercolor="#111111" cellpadding="0" cellspacing="0">
<form method="POST" action="note_edit.asp" target="_top">
<tr>
<td width="100%">
主旨:<input type="text" name="note_title" value="">
<textarea name="note_note" style="width:100%; height:200" rows="1" cols="20">
</textarea>
</td>
</tr>
<tr>
<td align="center">
<input type="hidden" name="mode" value="add">
<input type="hidden" name="doit" value="yes">
<input type="submit" value="修改存檔">
</td>
</tr>
<script language="javascript1.2">
var config = new Object(); // create new config object
config.width = "90%";
config.height = "200px";
config.bodyStyle = ''background-color: white; font-family: "Verdana"; font-size: x-small;'';
config.debug = 0;
// NOTE: You can remove any of these blocks and use the default config!
config.toolbar = [
[''fontname''],
[''fontsize''],
[''fontstyle''],
[''linebreak''],
[''bold'',''italic'',''underline'',''separator''],
// [''strikethrough'',''subscript'',''superscript'',''separator''],
[''justifyleft'',''justifycenter'',''justifyright'',''separator''],
[''OrderedList'',''UnOrderedList'',''Outdent'',''Indent'',''separator''],
[''forecolor'',''backcolor'',''separator''],
[''HorizontalRule'',''Createlink'',''InsertImage'',''htmlmode'',''separator''],
[''about'',''help'',''popupeditor''],
];
config.fontnames = {
"Arial": "arial, helvetica, sans-serif",
"Courier New": "courier new, courier, mono",
"Georgia": "Georgia, Times New Roman, Times, Serif",
"Tahoma": "Tahoma, Arial, Helvetica, sans-serif",
"Times New Roman": "times new roman, times, serif",
"Verdana": "Verdana, Arial, Helvetica, sans-serif",
"impact": "impact",
"WingDings": "WingDings"
};
config.fontsizes = {
"1 (8 pt)": "1",
"2 (10 pt)": "2",
"3 (12 pt)": "3",
"4 (14 pt)": "4",
"5 (18 pt)": "5",
"6 (24 pt)": "6",
"7 (36 pt)": "7"
};
//config.stylesheet = "http://www.domain.com/sample.css";
config.fontstyles = [ // make sure classNames are defined in the page the content is being display as well in or they won''t work!
{ name: "headline", className: "headline", classStyle: "font-family: arial black, arial; font-size: 28px; letter-spacing: -2px;" },
{ name: "arial red", className: "headline2", classStyle: "font-family: arial black, arial; font-size: 12px; letter-spacing: -2px; color:red" },
{ name: "verdana blue", className: "headline4", classStyle: "font-family: verdana; font-size: 18px; letter-spacing: -2px; color:blue" }
// leave classStyle blank if it''s defined in config.stylesheet (above), like this:
// { name: "verdana blue", className: "headline4", classStyle: "" }
];
editor_generate(''note_note'',config);
</script>
</form>
</table>
</div>
</body></html> _________________ Jason
網站 http://www.jasoninfo.com.tw/
論壇 http://www.jasoninfo.org/snitz/ |
|
回頂端 |
|
|
cjs 一級
註冊時間: 2002-04-11 文章: 26 來自: 中華民國
|
發表於: 星期五 六月 13, 2003 5:56 am 文章標題: |
|
|
jasoncash:
謝謝您這麼快就幫助我! |
|
回頂端 |
|
|
winxp2600 帝王
註冊時間: 2003-03-14 文章: 366 來自: 台灣 , 中華民國
|
發表於: 星期五 六月 13, 2003 3:52 pm 文章標題: |
|
|
jasoncash好久不見
您有辦法把3.0套到MILD嗎
謝啦 _________________ 我的論壇~http://netd.idv.tw |
|
回頂端 |
|
|
jasoncash 十段
註冊時間: 2002-08-15 文章: 231 來自: 中華民國
|
|
回頂端 |
|
|
cjs 一級
註冊時間: 2002-04-11 文章: 26 來自: 中華民國
|
發表於: 星期六 六月 14, 2003 2:07 pm 文章標題: |
|
|
成功了!
<head>
<meta http-equiv="Content-Type" content="text/html; charset=big5">
<script language="Javascript1.2"><!-- // load htmlarea
_editor_url = "/webeditor/"; // URL to htmlarea files
var win_ie_ver = parseFloat(navigator.appVersion.split("MSIE")[1]);
if (navigator.userAgent.indexOf(''Mac'') >= 0) { win_ie_ver = 0; }
if (navigator.userAgent.indexOf(''Windows CE'') >= 0) { win_ie_ver = 0; }
if (navigator.userAgent.indexOf(''Opera'') >= 0) { win_ie_ver = 0; }
if (win_ie_ver >= 5.5) {
document.write(''<scr'' + ''ipt src="'' +_editor_url+ ''editor.js"'');
document.write('' language="Javascript1.2"></scr'' + ''ipt>'');
} else { document.write(''<scr''+''ipt>function editor_generate() { return false; }</scr''+''ipt>''); }
// --></script>
</head>
:
:
<textarea name="Body" style="width:800; height:150">
</textarea>
<script language="JavaScript1.2" defer>
editor_generate(''Body'');
</script>
只要改以上位置就可以了!但奇怪的是同樣的方法不適用於3.0版
我try了大半天就是試不出來!不知道有那位大大能分享心得呢?謝謝! |
|
回頂端 |
|
|
|
|
您 無法 在這個版面發表文章 您 無法 在這個版面回覆文章 您 無法 在這個版面編輯文章 您 無法 在這個版面刪除文章 您 無法 在這個版面進行投票
|
Powered by phpBB © 2001-2007 phpBB Group
|