/*
** ÇÁ·ÎÁ§Æ®¸í: ¾ËµðÅÍ (¾Ë¸¯ + wysiwyg ¿¡µðÅÍ)
**
** ÈÀϸí: alditor.js
** ÀÛ¼ºÀÚ: Alex Suk Hyun Park a.k.a Alik (http://www.alik.info/ | alikong@gmail.com)
** ÀÛ¼ºÀÏ: 2006-08-19
** ÃÖÁ¾ ¼öÁ¤ÀÏ: 2006-11-06
**
**
** ¶óÀ̼¾½º Á¤º¸:
** -------------------------------------------------------------------------
** ¼Ò½º ¼öÁ¤ ¹× ¹èÆ÷ ºÒ°¡
** ÈÀÏÀÇ Á÷Á¢ ¸µÅ© (°³ÀÎ À¯Æ÷) ºÒ°¡
** °³ÀÎÀûÀÎ ¿ëµµ·Î »ç¿ë°¡´ÉÇÏ¸ç »ó¾÷Àû »ç¿ë½Ã »ó±â¸í½ÃµÈ ÀÛ¼ºÀÚ¿¡°Ô ¿¬¶ô ¿ä¸Á.
** ¼Ò½º ¹èÆ÷, ¾÷µ¥ÀÌÆ® ¹× ±â´É Ãß°¡µîÀº ¸ðµÎ http://www.alik.info ¿¡¼ È®ÀÎ ¿ä¸Á.
** °ÇÀÇ»çÇ× ¹× ¼öÁ¤»çÇ× ¶ÇÇÑ http://www.alik.info ·Î ¹®ÀÇ ¿ä¸Á
** ¼Ò½º¸¦ Á¦¿ÜÇÑ ¹öư ¾ÆÀÌÄÜµî ¸ðµç À̹ÌÁöÀÇ ÀúÀÛ±ÇÀº À̹ÌÁö Á¦ÀÛÀÚ¿¡°Ô ÀÖÀ½.
**
**
** ±â´É ¼³¸í:
** -------------------------------------------------------------------------
** HTML ³»ºÎ¿¡ ÀÖ´Â Textarea ¸¦ À§ÁöÀ¨(WYSIWYG) ¿¡µðÅÍ·Î º¯È¯ÇÔ.
** ÇÑ ÆäÀÌÁö³» ´Ù¼öÀÇ Textarea ¸¦ ¼±º°Àû(Textarea ű×ÀÇ ¼Ó¼º¿¡ editable=0 Ãß°¡½Ã º¯È¯µÇÁö ¾ÊÀ½)
** ¶Ç´Â Àüü º¯È¯(±âº» ¼³Á¤) °¡´ÉÇÔ.
**
**
** »ç¿ë¹ý:
** -------------------------------------------------------------------------
** ÀÚ¼¼ÇÑ ¼³¸í, ¼³Á¤¹æ¹ý ¹× »ç¿ë¹ýÀº http://www.alik.info/ ¹æ¹® ¿ä¸Á.
*/
/////////// »ç¿ëÀÚ ¼³Á¤ ½ÃÀÛ ////////////
function alditorConfig () {
/*
this.alditorPath = ¾ËµðÅͰ¡ »ðÀÔµÈ À¥ÆäÀÌÁö¸¦ ±âÁØÀ¸·ÎÇÑ ¾ËµðÅÍ Æú´õ °æ·Î (³¡¿¡ / Çʼö)
·çÆ®·Î ºÎÅÍ Àý´ë°æ·Î¸¦ Ãßõ~ ( ./ °¡ ¾Æ´Ñ / Àº ·çÆ®¸¦ ±âÁØÀ¸·Î ÇÔ, ¾Æ·¡ »ùÇÃÀº ÇöÀç ·çÆ®¿¡ alditor ¿¡ ¾÷·ÎµåµÈ »óȲÀ¸·Î ¼³Á¤)
this.buttonSet = »ç¿ëÇÒ ¹öư¼¼Æ®ÀÇ À̸§ (buttons Æú´õ ¾È¿¡ ¹öưÀ̹ÌÁöµéÀÌ ÀÖ´Â Æú´õÀÇ À̸§)
*/
this.alditorPath = "./alditor/";
this.buttonSet = "alik_nontoxic";
/*
this.uploadLink = ÈÀÏÀ» ¾÷·Îµå ÇÒ¼ö ÀÖ´Â ¼ºñ½ºÁ¦°ø ÆäÀÌÁöÀÇ ÁÖ¼Ò
http://www.imageshack.us/ (¿Ü±¹¼¹ö¶ó »ì¦ ´À¸².)
http://img.npiza.com/
http://image.widesoccer.com/index.html (ºÎȰÇÔ)
µîµî À¥¿¡¼ °Ë»öÇϽñæ... (ȤÀº º»ÀÎÀÇ »çÀÌÆ®¿¡ ȸ¿øÁ¦ ¶Ç´Â ÀÚÀ¯ ¾÷·Îµå ÆäÀÌÁö¸¦ ¸¸µé¾î¼ ¿¬°áÇÒ¼ö ÀÖÀ½ ^^ .... Â÷ÈÄ¿¡ Áö¿øÇսôÙ!)
*/
this.uploadLink = 'http://image.widesoccer.com/index.html';
/*
this.spellcheckLink = ¸ÂÃã¹ý °Ë»ç ¼ºñ½ºÁ¦°ø ÆäÀÌÁöÀÇ ÁÖ¼Ò (Á¾Á¾ º¯ÇÔ..¤Ì.¤Ì, º¯°æ½Ã http://urimal.cs.pusan.ac.kr/ ¿¡¼ 'Çѱ¹¾î ¸ÂÃã¹ý/¹®¹ý°Ë»ç±â' ÁÖ¼Ò¸¦ ã±â ¹Ù¶÷)
this.spellcheckAction = ¸ÂÃã¹ý °Ë»ç¸¦ À§ÇÑ Æû Àü¼Û½Ã¿¡ »ç¿ëµÉ action ÁÖ¼Ò (ÇöÀç À̸§¿¡¼ ¾ÕÀÇ ¾ÆÀÌÇÇÁÖ¼Ò ¸¸ ¹Ù²ð °¡´É¼ºÀÌ ¸¹À½)
*/
this.spellcheckLink = 'http://164.125.36.47/urimal-spellcheck.html';
this.spellcheckAction = 'http://164.125.36.47/WebSpell_ISAPI.dll?Check';
/*
this.runOnLoad = ÆäÀÌÁö ·Îµå½Ã ¿¡µðÅÍ·Î ½ÃÀÛÇÒ±î¿ä?
true : false;
Âü°í: false·Î ÁöÁ¤ÇÒ°æ¿ì ¿¡µðÅÍ È°¼ºÈ ¹öưÀº ¾Æ·¡ ¿¹Á¦¸¦ Âü°í
¿¹Á¦: ¿¡µðÅÍ ON
this.setFocus = ÆäÀÌÁö ·Îµå½Ã Æ÷Ä¿½º¸¦ ¿¡µðÅÍ·Î À̵¿½Ãų±î¿ä? (¿¡µðÅͰ¡ ÇÑÆäÀÌÁö¿¡ ÇѰ³ ÀÌ»óÀÎ »óȲ¿¡¼ true ¶ó¸é ù¹øÂ° ¿¡µðÅÍ·Î Æ÷Ä¿½º°¡ À̵¿µÊ.)
true : false;
this.useSafeFocus = À§ ¼³Á¤¿¡¼ setFocus ¸¦ true ·Î ÇßÀ»½Ã, º» ¼³Á¤µµ true ·Î ÇÑ´Ù¸é ¿¡µðÅͰ¡ ȸéÀÇ ÇÏ´Ü(ÄÚ¸àÆ® ÀÔ·ÂÀÇ °æ¿ì)¿¡ Àִ°æ¿ì´Â Æ÷Ä¿½º¸¦ ÁÖÁö ¾ÊÀ½À¸·Î¼ ºÎÀûÀýÇÑ ½ºÅ©·ÑÀ» ¹æÁöÇÑ´Ù.
true : false;
*/
this.runOnLoad = true;
this.setFocus = false; //////////// °¡º±°Ô
this.useSafeFocus = false;
/*
this.allowStretch = ¿¡µðÅÍ¿µ¿ªÀ» ³»¿ë¿¡ ¸Â°Ô ´Ã¾î³ª°Ô ÇÒ±î¿ä? (½ºÅ©·Ñ¹Ù°¡ ¾È»ý±â´Â´Ù´Â°ÅÁÒ ^^) µå·¹±×³ª À̰ųª µÑÁß¿¡ Çϳª¸¸ ¾²¸é ÁÁÀ»µí...
true : false
*/
this.allowStretch = false;
/*
this.movableToolbar = Åø¹Ù¸¦ µå·¹±×ÇØ¼ »ó/ÇÏ À§Ä¡¸¦ Á¶Á¤ÇÒ¼ö ÀÖ°Ô ÇÒ±î¿ä?
true : false
*/
this.movableToolbar = false; ////////////// °¡º±°Ô
/*
this.allowDrag = ¸®»çÀÌÁî µå·¹±× Çã¿ë¿©ºÎ
true : false
this.dragMode = ¸®»çÀÌÁî µå·¹±× ¹æÇâÁ¦ÇÑ
1 = °¡·Î¸¸ ´Ã¾î³ª´Â ¸ðµå, 2 = ¼¼·Î¸¸ ´Ã¾î³ª´Â ¸ðµå, 3 = ¹æÇâ Á¦ÇÑ ¾ø´Â ÀÚÀ¯¸ðµå
this.minWidth , this.minHeight = ¸®»çÀÌÁî °¡´ÉÇÑ ÃÖ¼Ò ³ÐÀÌ¿Í ³ôÀÌ ÁöÁ¤ (´ÜÀ§ = Çȼ¿)
*/
this.allowDrag = false; /////////////////// °¡º±°Ô
this.dragMode = 2;
this.minWidth = 200;
this.minHeight = 200;
/*
this.useEnterBR = ¿£ÅÍ ÀԷ½à ÀÚµ¿À¸·Î ½¬ÇÁÆ®+¿£ÅÍ (
) Çü½ÄÀ¸·Î º¯È¯ÇØÁÙ±î¿ä? (¹®´Ü¹Ù²ÞÀ» ÁٹٲÞÀ¸·Î ¹Ù²ãÁÖ´Â ±â´É)
true : false
this.useAutoP = À§¿¡ ¼³Á¤ÇÑ useEnterBR ÀÌ true ¶ó¸é ¿£ÅÍ µÎ¹ø ÀԷ½à ÀÚµ¿À¸·Î º¸Åë¿£ÅÍ ÇѹøÀÔ·ÂÀ¸·Î º¯È¯ÇØÁÙ±î¿ä? (ÇѹøÀº ÁÙ¹Ù²Þ µÎ¹øÀº ¹®´Ü¹Ù²Þ)
true : false
*/
this.useEnterBR = true;
this.useAutoP = true;
/*
this.showPath = ¿¡µðÅÍ ÇÏ´ÜÀÇ Å±׼±Åñâ´É Çã¿ë¿©ºÎ
true : false
this.showPathSafeMode = showPath°¡ true À϶§ ³Ê¹« ´À¸°°¨ÀÌ ÀÖ´Ù¸é showPathSafeMode ¸¦ true·Î ÁöÁ¤ÇÏ¸é ¼Óµµ°¡ Á¶±Ý Áõ°¡ÇÑ´Ù
(ű׸ñ·ÏÀÌ º»¹®¿¡ ³»¿ëÀԷ½ÿ¡¼ ¹æÇüŰÀԷ½ðú Ŭ¸¯½Ã·Î ¾÷µ«µÇ°Ô º¯°æµÊ, true ±ÇÀå!)
true : false
*/
this.showPath = true;
this.showPathSafeMode = true;
/*
this.useExtraHTML = ¿¡µðÅÍ ¿ìÃø¿¡ ´Ù¾çÇÑ div »óÀÚ¸ðÀ½ÀÌ ³ª¿É´Ï´Ù.
true : false
this.useExtraHTMLwidth = À§¿¡ ¸í½ÃµÈ div »óÀÚ¸ðÀ½ÀÇ °¡·Î±æÀÌ (´ÜÀ§ = Çȼ¿)
alditor.css ¿¡¼ .extraDiv ÀÇwidth ¿Í µ¿ÀÏÇÏ°Ô ÁöÁ¤ÇØÁà¾ßÇÔ
*/
this.useExtraHTML = false;
this.useExtraHTMLwidth = 120;
/*
this.useExpansion = Åø¹Ù¿¡ ¿©·¯°³ÀÇ ¹öưÁÙÀÌ Àִ°æ¿ì ¹öưÀ¸·Î È®ÀåÇÏ´Â Çü½ÄÀ¸·Î »ç¿ëÇÒ±î¿ä?
true : false
this.minimumRow = È®ÀåÇÏ´Â Çü½ÄÀ» »ç¿ëÇÏ½Å´Ù¸é ±âº»À¸·Î ¸îÁÙÀ» º¸¿©ÁÙ±î¿ä?
true : false
*/
this.useExpansion = false;
this.minimumRow = 1;
/*
this.noSelect = ±Û²Ã°ú ±ÛÀÚÅ©±â ¼³Á¤À» select °¡ ¾Æ´Ñ ·¹À̾î·Î Ç¥½ÃÇÒ±î¿ä?
true : false
this.freeFontSize = ±ÛÀÚÅ©±â ¼³Á¤À» select °¡ ¾Æ´Ñ ·¹À̾î·Î Ç¥½ÃÇÒ¶§ ±âº»¹æ½Ä(Ç¥ÁØ,¾ÈÁ¤ÀûÀÓ,8,10,12,14,18,24,36pt ·Î ¿É¼ÇÀÌ Á¦ÇÑÀûÀÓ) À» ¾µ±î¿ä? ¾Æ´Ô ¿øÇϴµ¥·Î (±ÛÀÚ ¼±ÅÃÈĸ¸ º¯°æ°¡´É, °ü¸®ÀÚ°¡ ¿øÇÏ´Â »çÀÌÁî Ãß°¡ °¡´É) ¹Ù²Ù´Â ¹æ½ÄÀ¸·Î ÇÒ±î¿ä?
true : false
*/
this.noSelect = false;
this.freeFontSize = false;
/*
this.targetBlank = ¿¡µðÅ;ȿ¡ »ðÀÔµÈ ¸ðµç ¸µÅ©µéÀÇ Å¸ÄÏÀ» »õâÀ¸·Î ÁöÁ¤ÇÒ±î¿ä?
true : false
*/
this.targetBlank = true;
/*
this.imgKeepAddress = IE ÀÇ À̹ÌÁö »ðÀԽà »ó´ë°æ·Î°¡ ÀÚµ¿À¸·Î Àý´ë°æ·Î·Î ¹Ù²î´Â°É ¸·À»±î¿ä? (ÃÖÁ¾ Àü¼Û½Ã º¯È¯µÊ)
true : false
*/
this.imgKeepAddress = true;
/*
this.useCopy = ±Û ³¯¸² ¹æÁö¿ë ³»¿ëº¹»ç ±â´ÉÀÇ »ç¿ë¿©ºÎ
true : false
this.useContentCheck = ±Û ³»¿ëÀÇ ±æÀÌ Ã¼Å© ±â´ÉÀÇ »ç¿ë¿©ºÎ
true : false
this.minimumContent = À§ üũ ±â´ÉÀÇ ±âÁØ ±ÛÀÚ¼ö (¸îÀÚ ÀÌ»ó ½á¾ß µî·ÏÀÌ µÇ´Â... ±× ±â´É)
1ºÎÅÍ ~ ¹«ÇÑ´ë (Á¤¼ö)
this.saveRemoteIMG = º»¹®¿¡ »ðÀÔµÈ À̹ÌÁöµéÁß ¿ÜºÎ(´Ù¸¥°èÁ¤)¿¡ À§Ä¡ÇÑ À̹ÌÁöµéÀ» º»ÀÎÀÇ ¼¹ö·Î ÀúÀåÇÒ±î¿ä?
true : false
*/
this.useCopy = false;
this.useContentCheck = false;
this.minimumContent = 10;
this.saveRemoteIMG = false;
/*
this.killError = ¿¡µðÅÍ »ðÀÔÀ¸·Î ÀÎÇØ »ý±â´Â °¢Á¾ ¿¡·¯¸Þ¼¼Áö Ãâ·ÂÀ» ¸·À»±î¿ä? (ºñÃßõ - ¸ðµç ¿¡·¯°¡ ¾Ê³ª¿È...¤Ñ.¤Ñ)
true : false
*/
this.killError = false;
/*
this.noOnsubmit = ÆûÀü¼Û½Ã¿¡ ½ÇÇàµÇ´Â onsubmit Ç׸ñÀ» °Çµå¸®Áö ¾ÊÀ»±î¿ä? true ·Î ¼³Á¤½Ã ³»¿ëº¹»ç¸¦ ºñ·ÔÇÑ °¢Á¾±â´ÉµéÀÌ ÀÛµ¿ÇÏÁö ¾Ê°í ¹Ù·Î Àü¼ÛµÊ.(ÀÏÁ¾ÀÇ ½ÉÇøðµå, ƯÈ÷ form ¾È¿¡¼ »ç¿ëÇÏ´Â textarea °¡ ¾Æ´Ò°æ¿ì true ·Î!)
true : false
*/
this.noOnsubmit = false;
/*
Åø¹Ù¿¡ µé¾î°¡´Â ºó°ø°£ °¡·Î»çÀÌÁî ±âº»°ª ÁöÁ¤ (´ÜÀ§ = Çȼ¿) [firefox ¿¡¼± ½ÇÁ¦ Çȼ¿ÀÌ ¾Æ´Ñ »çÀÌÁî 5 ¸¶´Ù ºóÄÀ» Çϳª¾¿ »ðÀÔ]
*/
this.defaultSpaceWidth = 10;
/*
Åø¹Ù ¹öư Ç׸ñ
1. Á¤ÀÇÇÏ´Â ¼ø¼´ë·Î ¿¡µðÅÍ¿¡ Ç¥½ÃµÊ.
2. ¹öư»çÀÌÀÇ ÀÓÀÇÀû °ø¹éÀº this.toolbarItems.push("space"); ¸¦ Ãß°¡ÇÔÀ¸·Î¼ »ý¼º°¡´É
2-1. space ¸¸ ÀûÀ»°æ¿ì À§¿¡¼ Á¤ÀÇÇÑ defaultSpaceWidth °ø¹éÀÇ »çÀÌÁî·Î ÀÌ¿ëµÇ¸ç,
2-2. °ø¹éº° »çÀÌÁ ÁöÁ¤ÇÏ°í ½ÍÀ»¶© space_40 ó·³ _ ¿Í ÇÔ²² Àû¾îÁÖ¸é ÇØ´ç °ø¹éÀÇ ³ÐÀ̸¦ ÁöÁ¤ÇÒ¼ö ÀÖÀ½ (´ÜÀ§ = Çȼ¿)
3. »õ·Î¿î ¹öưÁÙÀÇ °æ¿ì this.toolbarItems.push("row"); ¸¦ ÁÙ »çÀÌ¿¡ ³Ö¾îÁÖ¸é »ý¼ºµÊ.
4. ÇÊ¿ä¾ø´Â ¹öưÀº //this.toolbarItems.push("underline"); ó·³ //À» ÀÌ¿ëÇÏ¿© ÁÖ¼®Ã³¸® ±ÇÀå.
5. ¼³Á¤Ç׸ñµéÀÌ Àͼ÷ÇØÁö±æ ¹Ù¶ó´Â ¸¶À½¿¡ ÇöÀç µÎÁÙ·Î ¼³Á¤µÇ¾îÀÖÀ½. (ÇÑÁÙ·Î ÁÖ¿í~ Ç¥½ÃÇϱ⠱ÇÀå)
*/
this.toolbarItems = new Array();
this.toolbarItems.push("htmlsource"); //¼Ò½ºÃ¢°ú ¿¡µðÅÍâÀÇ Àüȯ ¹öư
this.toolbarItems.push("image"); // À̹ÌÁö »ðÀÔ
this.toolbarItems.push("space"); //±âº» °ø¹é
this.toolbarItems.push("fontname"); // ±Û²Ã º¯°æ
this.toolbarItems.push("fontsize"); // ±ÛÀÚÅ©±â º¯°æ
this.toolbarItems.push("space"); //±âº» °ø¹é
this.toolbarItems.push("bold"); // ±½°Ô
this.toolbarItems.push("underline"); // ¹ØÁÙ
this.toolbarItems.push("italic"); // ±â¿ïÀ̱â
this.toolbarItems.push("strike"); // Ãë¼Ò¼±
this.toolbarItems.push("space"); //±âº» °ø¹é
this.toolbarItems.push("color"); // ±ÛÀÚ »ö»ó
this.toolbarItems.push("bgcolor"); // ±ÛÀÚ ¹è°æ»ö
this.toolbarItems.push("hilite"); // °Á¶ (³ë¶û¹ÙÅÁ¿¡ °ËÁ¤±Û¾¾)
this.toolbarItems.push("space"); //±âº» °ø¹é
// this.toolbarItems.push("link"); // ¸µÅ©»ðÀÔ
// this.toolbarItems.push("emoticon"); // À̸ðƼÄÜ »ðÀÔ
// this.toolbarItems.push("specialchars"); // Ư¼ö¹®ÀÚ »ðÀÔ
this.toolbarItems.push("space"); //±âº» °ø¹é
// this.toolbarItems.push("row"); // »õ·Î¿î ¹öưÁÙ
// this.toolbarItems.push("unlink"); // ¸µÅ©Ãë¼Ò
this.toolbarItems.push("nohilite"); // °Á¶ Ãë¼Ò ¹× °¢Á¾ ±ÛÀÚÈ¿°ú Á¦°Å
// this.toolbarItems.push("sup"); // À÷ÀÚ
// this.toolbarItems.push("sub"); // ¾Æ·¡Ã·ÀÚ
//this.toolbarItems.push("space_33"); //°ø¹é »çÀÌÁî 33 »ùÇÃ
this.toolbarItems.push("orderedlist"); // ¹øÈ£¸Å±è
this.toolbarItems.push("unorderedlist"); // Á¡¸Å±è
// this.toolbarItems.push("indent"); // µé¿©¾²±â
// this.toolbarItems.push("outdent"); // µé¿©¾²±â Ãë¼Ò
this.toolbarItems.push("left"); // ¿ÞÂʸÂÃã
this.toolbarItems.push("center"); // °¡¿îµ¥¸ÂÃã
this.toolbarItems.push("right"); // ¿À¸¥ÂʸÂÃã
this.toolbarItems.push("space"); //±âº» °ø¹é
// this.toolbarItems.push("abs"); // position:absolute
// this.toolbarItems.push("hr"); // ÁÙ »ðÀÔ
this.toolbarItems.push("simpleDiv"); // ½ÉÇùڽº
this.toolbarItems.push("table"); // Å×À̺í»ðÀÔ
// this.toolbarItems.push("showhide"); // º¸À̱â/°¨Ãß±â
// this.toolbarItems.push("spellcheck"); // ¸ÂÃã¹ý°Ë»ç
// this.toolbarItems.push("preview"); // ¹Ì¸®º¸±â
// ¹öư ³¡
/*
À§¿¡¼ ÁöÁ¤ÇÑ ÆùÆ®º¯°æ ¸Þ´º¿¡ ¿É¼ÇÀ¸·Î µé¾î°¥ ÆùÆ®¸ñ·Ï
Çü½Ä = this.fontOptions.push("execcommand ·Î Àû¿ëµÇ´Â Á¤È®ÇÑ ÆùÆ®À̸§", "»ç¿ëÀÚ¿¡°Ô º¸¿©Áö´Â °ª - ÀÓÀÇÁöÁ¤ °¡´É");
*/
this.fontOptions = new Array();
if (this.noSelect) // ±Û²Ã¼±ÅÃÀ» ·¹À̾î·Î ÇßÀ»°æ¿ì »ç¿ëµÉ Ç׸ñ
{
this.fontOptions.push("±¼¸²", "±¼¸²");
this.fontOptions.push("µ¸¿ò", "µ¸¿ò");
this.fontOptions.push("¹ÙÅÁ", "¹ÙÅÁ");
this.fontOptions.push("±Ã¼", "±Ã¼");
this.fontOptions.push("tahoma", "tahoma");
this.fontOptions.push("verdana", "verdana");
this.fontOptions.push("Courier", "Courier");
}
else // ±Û²Ã¼±ÅÃÀ» select ·Î ÇßÀ»°æ¿ì »ç¿ëµÉ Ç׸ñ
{
this.fontOptions.push("", "±Û²Ã"); //ùÁÙ Á¦°Å ±ÝÁö!
this.fontOptions.push("±¼¸²", "±¼¸²");
this.fontOptions.push("µ¸¿ò", "µ¸¿ò");
this.fontOptions.push("¹ÙÅÁ", "¹ÙÅÁ");
this.fontOptions.push("±Ã¼", "±Ã¼");
}
/*
À§¿¡¼ ÁöÁ¤ÇÑ ±ÛÀÚÅ©±â ¸Þ´º¿¡ ¿É¼ÇÀ¸·Î µé¾î°¥ »çÀÌÁî¸ñ·Ï
Çü½Ä = this.fontOptions.push("½ÇÁ¦·Î Àû¿ëµÇ´Â »çÀÌÁî°ª", "»ç¿ëÀÚ¿¡°Ô º¸¿©Áö´Â °ª - ÀÓÀÇÁöÁ¤ °¡´É");
*/
this.fontSizeOptions = new Array();
if (this.noSelect && this.freeFontSize) // ±ÛÀÚÅ©±â¼±ÅÃÀ» ·¹À̾î·Î ÇÏ¸é¼ Å©±âÀÚÀ¯ÀԷ½ÿ¡ »ç¿ëµÉ Ç׸ñ (pt µµ µÇ°í px µµ µÊ)
{
this.fontSizeOptions.push("7pt", "7pt");
this.fontSizeOptions.push("8pt", "8pt");
this.fontSizeOptions.push("9pt", "9pt");
this.fontSizeOptions.push("10pt", "10pt");
this.fontSizeOptions.push("11pt", "11pt");
this.fontSizeOptions.push("12pt", "12pt");
this.fontSizeOptions.push("14pt", "14pt");
this.fontSizeOptions.push("18pt", "18pt");
this.fontSizeOptions.push("24pt", "24pt");
this.fontSizeOptions.push("36pt", "36pt");
this.fontSizeOptions.push("40pt", "40pt");
}
else // ±ÛÀÚÅ©±â¼±ÅÃÀ» select ·Î ÇßÀ»°æ¿ì »ç¿ëµÉ Ç׸ñ
{
this.fontSizeOptions.push("", "Å©±â"); //ùÁÙ Á¦°Å ±ÝÁö!
this.fontSizeOptions.push("1", "1");
this.fontSizeOptions.push("2", "2");
this.fontSizeOptions.push("3", "3");
this.fontSizeOptions.push("4", "4");
this.fontSizeOptions.push("5", "5");
this.fontSizeOptions.push("6", "6");
this.fontSizeOptions.push("7", "7");
}
if (this.useExtraHTML)
{
this.toolbarItems.push("extraHTML"); // Ãß°¡ Ç׸ñ HTML - ¾Æ·¡ ű׳»¿ë¸¸ ¼öÁ¤ÇϽñæ. »ç¿ë¿©ºÎ´Â À§ÀÇ ¼³Á¤¿¡¼...
this.extraHTML = new Array();
this.extraHTML.push("
");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
this.extraHTML.push("");
}
return true;
}
/////////// ¼³Á¤ ³¡ //////////// ÀÌÇÏ ¼Õµ¨ ÇÊ¿ä ¾øÀ½ ///////
//// Çʼö º¯¼öµé
var is_IE = (window.showModelessDialog) ? true : false;
var config = new alditorConfig();
var editorHeight = new Array();
var _1stRun = false;
////
var styleCss=document.createElement('LINK');
styleCss.rel = 'stylesheet';
styleCss.href = config.alditorPath+'buttons/'+config.buttonSet+'/alditor.css';
var styleCssContent=document.createElement('LINK');
styleCssContent.rel = 'stylesheet';
styleCssContent.href = config.alditorPath+'alditorContent.css';
var jsContent=document.createElement('script');
jsContent.type = 'text/javascript';
jsContent.language = 'javascript';
jsContent.src = config.alditorPath+'alditorContent.js';
document.getElementsByTagName('HEAD')[0].appendChild(styleCss);
document.getElementsByTagName('HEAD')[0].appendChild(styleCssContent);
document.getElementsByTagName('HEAD')[0].appendChild(jsContent);
if (config.runOnLoad)
{
addEvent(window,"load", alditorAll);
}
function alditorAll() {
var txtareas = document.getElementsByTagName("TEXTAREA");
for ( i=0 ; i < txtareas.length ; i++ )
{
if (txtareas[i].offsetHeight > 0 && txtareas[i].style.display.toLowerCase() != 'none' && txtareas[i].style.visibility.toLowerCase() != 'hidden' && !txtareas[i].readOnly && !txtareas[i].disabled)
{
var textarea = txtareas[i];
if (!textarea.id) {
if (document.getElementById(textarea.name) && document.getElementById(textarea.name).nodeName != 'TEXTAREA') {
textarea.id = 'text_' + textarea.name ;
} else {
textarea.id = textarea.name ;
}
}
if ( txtareas.length == 1)
{
new alditor(textarea.id);
} else {
setTimeout("new alditor('" + textarea.id + "')", 10 * (i));
}
}
}
}
function killalditorAll() {
var txtareas = document.getElementsByTagName("TEXTAREA");
for ( i=0 ; i < txtareas.length ; i++ )
{
var txtarea = txtareas[i];
if (txtarea.previousSibling && txtarea.previousSibling.id == txtarea.id + '_alditor')
{
var _table = document.getElementById(txtarea.id + '_table');
txtarea.style.display = 'block';
txtarea.className = txtarea.rel;
txtarea.style.cssText = txtarea.oldstyle;
_table.parentNode.replaceChild(txtarea,_table);
var extradiv = document.getElementById(txtarea.id + "_alditorextraDiv");
extradiv.parentNode.removeChild(extradiv);
}
}
}
function alditorById(textareaID) {
_1stRun = false;
var txtarea = document.getElementById(textareaID);
if (!txtarea || txtarea.nodeName != 'TEXTAREA')
{
txtarea = document.getElementsByTagName('TEXTAREA')[textareaID];
if (document.getElementById(txtarea.name) && document.getElementById(txtarea.name).nodeName != 'TEXTAREA') {
txtarea.id = 'text_' + txtarea.name ;
} else {
txtarea.id = txtarea.name ;
}
} else {
if (!txtarea.id)
{
if (document.getElementById(txtarea.name) && document.getElementById(txtarea.name).nodeName != 'TEXTAREA') {
txtarea.id = 'text_' + txtarea.name ;
} else {
txtarea.id = txtarea.name ;
}
}
}
if (!txtarea.previousSibling || (txtarea.previousSibling && txtarea.previousSibling.className !='alditorIframe'))
{
new alditor(txtarea);
}
return true;
}
function killalditor(txtID) {
var txtarea = document.getElementById(txtID);
if (!txtarea || txtarea.nodeName != "TEXTAREA")
{
txtarea = document.getElementsByTagName('TEXTAREA')[txtID];
}
txtID = txtarea.id;
if (txtarea.previousSibling && txtarea.previousSibling.id == txtarea.id + '_alditor')
{
txtarea.style.display = 'block';
txtarea.className = txtarea.rel;
txtarea.style.cssText = txtarea.oldstyle;
var _table = document.getElementById(txtID + "_table");
_table.parentNode.replaceChild(txtarea,_table);
var extradiv = document.getElementById(txtarea.id + "_alditorextraDiv");
extradiv.parentNode.removeChild(extradiv);
}
}
function getAlditor(textareaID) {
var alditorObj = document.getElementById(textareaID + '_alditor');
if (!alditorObj)
{
alditorObj = document.getElementById('text_' + textareaID + '_alditor');
}
if (alditorObj)
{
return alditorObj;
} else {
return false;
}
}
// ¾ËµðÅÍ ½ÃÀÛ
function alditor(textareaObj) {
if (typeof textareaObj == 'string')
{
textareaObj = document.getElementById(textareaObj);
}
if (textareaObj.nodeName != "TEXTAREA" || navigator.userAgent.indexOf('Mac') != -1 || textareaObj.getAttribute("editable") == 0)
{
return true;
}
if ((textareaObj.offsetHeight > 0) && (!textareaObj.previousSibling || textareaObj.previousSibling.id != textareaObj.id + "_alditor"))
{
var self = this;
var tempWidth = textareaObj.offsetWidth;
var tempHeight = textareaObj.offsetHeight;
this._initHeight = tempHeight;
this._textarea = textareaObj;
this._iframe = document.createElement("IFRAME");
this._textarea.rel = this._textarea.className;
this._textarea.oldstyle = this._textarea.style.cssText;
this._textarea.className = "alditorTextarea";
this._textarea.style.display = "none";
this._iframe.id = this._textarea.id + "_alditor";
this._iframe.frameBorder = 0;
this._iframe.marginWidth = 0;
this._iframe.marginHeight = 0;
this._iframe.className = "alditorIframe";
editorHeight[ this._iframe.id ] = tempHeight;
this._table = document.createElement("table");
this._table.setAttribute("border", "0");
this._table.setAttribute("cellPadding", "0");
this._table.setAttribute("cellSpacing", "0");
this._table.style.width = tempWidth + 'px';
this._table.className = "topTable";
this._table.id = this._textarea.id + "_table";
var topTablebody = document.createElement("tbody");
var current_row1 = document.createElement("tr");
current_row1.setAttribute("valign", "middle");
current_row1.setAttribute("align", "left");
this._toolbarTd = document.createElement("td");
this._toolbarTd.id = this._iframe.id + "toolbarTd";
this._toolbarTd.className = "toolbarTd";
this._toolbarTd.unselectable = 'on';
current_row1.appendChild(this._toolbarTd);
this._toolbarDiv = document.createElement("div");
this._toolbarDiv.id = this._iframe.id + "_toolbarDiv";
this._toolbarDiv.className = "toolbarDiv";
this._toolbarDiv.style.backgroundImage = "url('"+config.alditorPath+"buttons/" + config.buttonSet + "/toolbar_bg.gif')";
if (config.movableToolbar)
{
this._toolbarDiv.onmousedown = function (event) {tb_moveStart(event, self._toolbarDiv, self._iframe);};
this._toolbarDiv.className = "toolbarDiv updown";
}
this._toolbarTd.appendChild(this._toolbarDiv);
var current_row2 = document.createElement("tr");
current_row2.setAttribute("valign", "top");
current_row2.setAttribute("align", "left");
this._alditorTd = document.createElement("td");
this._alditorTd.id = this._iframe.id + "alditorTd";
this._alditorTd.className = "alditorTd";
this._alditorTd.width = tempWidth;
this._alditorTd.height = tempHeight;
this._alditorTd.unselectable = 'on';
current_row2.appendChild(this._alditorTd);
var current_row3 = document.createElement("tr");
current_row3.setAttribute("valign", "bottom");
current_row3.setAttribute("align", "left");
var bottomTd = document.createElement("td");
bottomTd.id = this._iframe.id + "bottomTd";
bottomTd.className = "bottomTd";
bottomTd.unselectable = 'on';
var bottomTable = document.createElement("table");
bottomTable.setAttribute("border", "0");
bottomTable.setAttribute("width", "100%");
bottomTable.setAttribute("cellPadding", "0");
bottomTable.setAttribute("cellSpacing", "2");
bottomTable.style.tableLayout = "fixed";
var bottomTablebody = document.createElement("tbody");
var current_row = document.createElement("tr");
current_row.setAttribute("align", "left");
current_row.setAttribute("valign", "bottom");
this._pathTd = document.createElement("td");
this._pathTd.id = this._iframe.id + "pathTd";
this._pathTd.className = "pathTd";
this._pathTd.innerHTML = (config.showPath)? "Tags:" : " ";
this._pathTd.unselectable = 'on';
var current_cell2 = document.createElement("td");
if (config.allowDrag)
{
current_cell2.onmousedown = function (event) {resizeStart(event, self._table, self._iframe); return true;};
current_cell2.className = "resizeHandle";
}
current_cell2.unselectable = "on";
current_row.appendChild(this._pathTd);
current_row.appendChild(current_cell2);
bottomTablebody.appendChild(current_row);
bottomTable.appendChild(bottomTablebody);
current_row3.appendChild(bottomTd);
topTablebody.appendChild(current_row1);
topTablebody.appendChild(current_row2);
topTablebody.appendChild(current_row3);
this._table.appendChild(topTablebody);
this.alditorToolbar();
this._textarea.parentNode.insertBefore(this._table, this._textarea);
this._alditorTd.appendChild(this._iframe);
this._alditorTd.appendChild(this._textarea);
if (config.allowDrag || config.showPath)
{
bottomTd.appendChild(bottomTable);
}
var tools = this._toolbarTd.getElementsByTagName('*');
for (ti=0;ti< tools.length; ti++)
{
tools[ti].unselectable = 'on';
}
this._textarea.style.width = this._alditorTd.clientWidth + 'px';
this._textarea.style.height = this._alditorTd.clientHeight - 2 + 'px';
this.fillContents(this._textarea.value);
if (config.toolbarItems.inArray('color') || config.toolbarItems.inArray('bgcolor'))
{
makeColorset();
}
if (config.toolbarItems.inArray('table'))
{
makeTableset();
}
if (config.toolbarItems.inArray('hilite'))
{
makeHiliteset();
}
if (config.noSelect)
{
makeFontset();
}
setTimeout(function () { self.setDesignMode(); },10);
expanded = false;
rowCnt = 0;
}
return true;
}
var expanded = false;
var rowCnt = 0;
alditor.prototype.alditorToolbar = function (startNo) {
if (!startNo)
{
startNo = 0
}
var self = this;
var tempi = 0;
this._buttonSet = document.createElement("DIV");
this._buttonSet.className = "buttonSet";
this._buttonSet.unselectable = "on";
if (expanded == true)
{
this._buttonSet.style.display = 'none';
}
for (var i = startNo; i < config.toolbarItems.length; i++)
{
switch (config.toolbarItems[i].split("_")[0])
{
case "htmlsource":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/source.gif", "¼Ò½º º¸±â", "html");
break;
case "image":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/image.gif", "À̹ÌÁö/µ¿¿µ»ó/À½¾Ç/Ç÷¡½Ã »ðÀÔ", "image");
break;
case "fontname":
if (config.noSelect)
{
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/font.gif", "±Û²Ã", "fontname");
} else {
this.createSelect(config.fontOptions, "fontname");
}
break;
case "fontsize":
if (config.noSelect)
{
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/size.gif", "±ÛÀÚÅ©±â", "fontsize");
} else {
this.createSelect(config.fontSizeOptions, "fontsize");
}
break;
case "bold":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/bold.gif", "±½°Ô", "bold");
break;
case "underline":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/underline.gif", "¹ØÁÙ", "underline");
break;
case "italic":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/italic.gif", "±â¿ïÀ̱â", "italic");
break;
case "strike":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/strike.gif", "Ãë¼Ò¼±", "StrikeThrough");
break;
case "color":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/fontcolor.gif", "±ÛÀÚ »ö", "color");
break;
case "bgcolor":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/backcolor.gif", "±ÛÀÚ ¹è°æ»ö", "bgcolor");
break;
case "sup":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/super.gif", "À§Ã·ÀÚ", "Superscript");
break;
case "sub":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/sub.gif", "¾Æ·¡Ã·ÀÚ", "Subscript");
break;
case "link":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/link.gif", "¸µÅ© »ðÀÔ", "link");
break;
case "unlink":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/unlink.gif", "¸µÅ© Á¦°Å", "unlink");
break;
case "emoticon":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/emoticon.gif", "À̸ðƼÄÜ »ðÀÔ", "emoticon");
break;
case "specialchars":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/specialchars.gif", "Ư¼ö¹®ÀÚ »ðÀÔ", "specialchars");
break;
case "hilite":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/hilite.gif", "±ÛÀÚ °Á¶", "hilite");
break;
case "nohilite":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/nohilite.gif", "°Á¶ Ãë¼Ò ¹× °¢Á¾ ±ÛÀÚ¼Ó¼º Á¦°Å", "nohilite");
break;
case "unorderedlist":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/unordered.gif", "Á¡ ¸ñ·Ï", "insertunorderedlist");
break;
case "orderedlist":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/ordered.gif", "¼ýÀÚ ¸ñ·Ï", "insertorderedlist");
break;
case "indent":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/indent.gif", "µé¿©¾²±â", "indent");
break;
case "outdent":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/outdent.gif", "µé¿©¾²±â Ãë¼Ò", "outdent");
break;
case "left":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/left.gif", "¿ÞÂÊ Á¤·Ä", "justifyleft");
break;
case "center":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/center.gif", "Áß¾Ó Á¤·Ä", "justifycenter");
break;
case "right":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/right.gif", "¿À¸¥ÂÊ Á¤·Ä", "justifyright");
break;
case "hr":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/hr.gif", "°¡·Î¼± »ðÀÔ", "inserthorizontalrule");
break;
case "simpleDiv":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/simpleDiv.gif", "´Ü¼ø »óÀÚ", "simpleDiv");
break;
case "table":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/table.gif", "Å×ÀÌºí »ðÀÔ", "table");
break;
case "showhide":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/showhide.gif", "º¸À̱â/°¨Ãß±â", "showhide");
break;
case "preview":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/preview.gif", "¹Ì¸®º¸±â", "preview");
break;
case "spellcheck":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/spellcheck.gif", "ÇÑ±Û ¸ÂÃã¹ý/¹®¹ý °Ë»ç", "spellcheck");
break;
case "space":
var SpaceWidth = (config.toolbarItems[i].split("_")[1])?config.toolbarItems[i].split("_")[1]:config.defaultSpaceWidth;
this.createSpace(SpaceWidth);
break;
case "abs":
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/abs.gif", "position:absolute", "abs");
break;
case "extraHTML":
this.extraDiv = document.createElement("DIV");
this.extraDiv.id = this._iframe.id + "extraDiv";
this.extraDiv.className = "extraDiv";
this.extraDiv.unselectable = "on";
for (xi=0; xi < config.extraHTML.length; xi +=2)
{
var divContent = document.createElement("DIV");
divContent.innerHTML = config.extraHTML[xi] + "..." + config.extraHTML[xi + 1];
divContent.onclick = function () { addExtraTag(self._iframe,this.innerHTML);}
divContent.unselectable = "on";
divContent.firstChild.unselectable = "on";
this.extraDiv.appendChild(divContent);
}
document.body.appendChild(this.extraDiv);
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/extra.gif", "Ãß°¡ Ç׸ñ (¿±â/´Ý±â)", "extraHTML");
break;
}
tempi = i;
if (config.toolbarItems[i] == "row")
{
rowCnt++;
if (config.useExpansion && expanded == false && rowCnt == config.minimumRow)
{
this.createButton(config.alditorPath+"buttons/" + config.buttonSet + "/expand.gif", "ÀÔ·Â µµ±¸ È®Àå", "expand");
expanded = true;
}
break;
}
}
this._toolbarDiv.appendChild(this._buttonSet);
if (tempi != config.toolbarItems.length-1)
{
this.addRow(i+1)
}
return true;
}
alditor.prototype.toolbarClick = function(action, buttonObj)
{
var self = this;
var actionIframe = this._iframe;
if (config.toolbarItems.inArray('color') || config.toolbarItems.inArray('bgcolor'))
{
hideColorPicker();
}
if (config.toolbarItems.inArray('table'))
{
hideTableset();
}
if (config.toolbarItems.inArray('hilite'))
{
hideHiliteSelector();
}
if (config.noSelect)
{
hideFontset();
}
actionIframe.contentWindow.focus();
switch (action)
{
case "html":
switchMode(actionIframe);
if (actionIframe.style.display != 'none' && config.allowStretch)
{
self.reHeight(actionIframe.contentWindow.document.body.scrollTop);
}
break;
case "fontname":
if (config.noSelect)
{
getFontName(actionIframe, buttonObj);
} else {
actionIframe.contentWindow.document.execCommand("fontname", false, buttonObj.value);
buttonObj.selectedIndex=0;
}
break;
case "fontsize":
if (config.noSelect)
{
getFontSize(actionIframe, buttonObj);
} else {
actionIframe.contentWindow.document.execCommand("fontsize", false, buttonObj.value);
buttonObj.selectedIndex=0;
}
break;
case "color":
getColor(actionIframe, buttonObj, "ForeColor");
break;
case "bgcolor":
if (is_IE)
{
getColor(actionIframe, buttonObj, "BackColor");
} else {
getColor(actionIframe, buttonObj, "Hilitecolor");
}
break;
case "link":
popWin(config.alditorPath + 'alditorLink.html?id='+this._iframe.id + '&rnd=' + new Date().getTime(), 650,500, actionIframe);
break;
case "image":
popWin(config.alditorPath + 'alditorImage.html?id='+this._iframe.id + '&rnd=' + new Date().getTime() , 650,400, actionIframe, true);
break;
case "emoticon":
popWin(config.alditorPath + 'alditorEmoticons.html?id='+this._iframe.id + '&rnd=' + new Date().getTime(), 540,460, actionIframe);
break;
case "specialchars":
popWin(config.alditorPath + 'alditorSpecialchars.html?id='+this._iframe.id + '&rnd=' + new Date().getTime() ,350,400, actionIframe);
break;
case "hilite":
getHilite(actionIframe, buttonObj);
break;
case "nohilite":
actionIframe.contentWindow.document.execCommand("RemoveFormat",false,null);
break;
case "simpleDiv":
addExtraTag(actionIframe, "...
");
break;
case "table":
showTableset(actionIframe,buttonObj);
break;
case "showhide":
addExtraTag(actionIframe, '...¼û°ÜÁø ³»¿ë...
', "showhide");
break;
case "preview":
alditorPreview (actionIframe);
break;
case "spellcheck":
spellcheck(actionIframe);
break;
case "extraHTML":
this.extraDiv.style.top = getOffsetTop(this._table) + 'px';
if (is_IE)
{
this.extraDiv.style.height = this._table.offsetHeight + 'px';
} else {
this.extraDiv.style.height = this._table.offsetHeight - 2 + 'px';
}
var newLeft = getOffsetLeft(this._table) + this._table.offsetWidth;
if ((newLeft + config.useExtraHTMLwidth) > document.body.clientWidth)
{
newLeft -= config.useExtraHTMLwidth;
}
this.extraDiv.style.left = newLeft + 'px';
if (this.extraDiv.style.display == "none" || !this.extraDiv.style.display){
this.extraDiv.style.display = "block";
} else {
this.extraDiv.style.display = "none";
}
break;
case "expand":
var buttonrows = this._toolbarDiv.childNodes;
for (i=config.minimumRow; i< buttonrows.length; i++)
{
if ( buttonrows[i].style.display != 'none')
{
buttonrows[i].style.display = 'none';
} else {
buttonrows[i].style.display = 'block';
}
}
break;
case "abs":
makeAbs(actionIframe);
break;
default:
try { actionIframe.contentWindow.document.execCommand( action, false, null); } catch (e) {}
}
if (action != "html")
{
updatePath(actionIframe);
}
return true;
}
alditor.prototype.addRow = function (i) {
this.alditorToolbar(i);
return true;
}
alditor.prototype.createButton = function(imgSrc, title, action)
{
var self = this;
var tempButton = document.createElement("IMG");
tempButton.title = title;
tempButton.alt = action;
tempButton.src = imgSrc;
tempButton.align = 'absmiddle';
tempButton.border = 0;
tempButton.onmouseover = function () { window.status = title; } ;
tempButton.onmousedown = toolbarDown;
tempButton.onmouseup = toolbarUp;
tempButton.onmouseout = toolbarUp;
tempButton.onclick = function () { self.toolbarClick(action, this); return true; } ;
this._buttonSet.appendChild(tempButton);
return true;
}
alditor.prototype.createSelect = function(optionList, action)
{
var self = this;
var theSelect = document.createElement("select");
theSelect.onchange = function () { self.toolbarClick(action, this); return true; } ;
for (var i = 0; i < optionList.length; i += 2)
{
var theOption = document.createElement("option");
var theText = document.createTextNode(optionList[i + 1]);
theOption.value = optionList[i];
theOption.appendChild(theText);
theSelect.appendChild(theOption);
}
this._buttonSet.appendChild(theSelect);
return true;
}
alditor.prototype.createSpace = function(width)
{
var tempSpace = document.createElement("SPAN");
tempSpace.style.width = parseInt(width) + "px";
if (!is_IE)
{
for (iii=0;iii@import url(\""+config.alditorPath+"alditorInnerContent.css\");\
\
\
" + text + "\
\