Click here to Skip to main content
15,891,431 members
Articles / Programming Languages / Javascript
Article

Yahoo! mail and Hotmail like Rich Text Editor

Rate me:
Please Sign up or sign in to vote.
4.60/5 (67 votes)
28 Feb 2002 625.5K   6.9K   121   219
Yahoo! mail and Hotmail like Rich Text Editor using Scriptlets

Sample Image - richtext.gif

Introduction

A friend asked me an interesting question related with a Rich Text Editor Control using JavaScript . At first, I felt to have some study before I answer him. I knew this is tough to answer but thought there is some ways to get solve it. After a long surfing fortunately, found a small secret features of IE known as "scriptlet".

Scriptlet

For many web programmers Scriptlet is still a mystery. Although this features was introduced in IE 4.0 and never used highly. I think its due to cross-compatibility issue because Netscape doesn't support it but don't worry Microsoft has submitted Scriptlet to W3 long ago.

Let me introduce Scriptlet with some few examples. Probably from a year long you are using a rich text compose box in Yahoo! mail or hotmail and someone who are little crazy about internal, probably gone through every tags to know what exactly is this? ... but got nothing except <object ..> tag that is usually use to invoke COM . I have seen lots of programmer used to consider the yahoo! or hotmail compose box as COM /ActiveX ! . Indeed it looks like COM when it loads first but actually its not that what you think.

Actually Scriptlet is ActiveX script. This components consisting of Plain text script code instead of binary. It is nothing more than an HTML file with a body and some script code. It is simply a HTML file that can be nested inside another HTML page like you use to include(...) a file using server side scripts.

The way of executing the Scriptlet is similar to applet or ActiveX. Both ActiveX and Scriplet expose properties, events and methods and also can driven via automation. Well, If you try it once with your web projects, you will find the importance of such tools. Overall I prefer to put it in "easy to adopt" categories. It is the only one tool known to be the coolest solution for DHTML code reusability. Remember It is included in same object tag where we use to invoke ActiveX components.

HTML
<object type="text/x-scriptlet"
data= "Scriptlet.html"></object>

But There are a number of fundamental differences between a standard ActiveX control and a scriptlet

  • It is identified by name, not with an long 128-bit CLSID.
  • It is invoked direct from the server not from the client PC. So no need to compile, register like you do with your ActiveX DLL components before using its various methods, properties from the Web pages.

Here is a very simple example that demonstrate the real usage of scriptlet. The example shows a simple non-toolbar Rich Text Editor.

Before we get inside the example lets read few essential stuffs behind a Web Based Rich Text Editor. In our example IFRAME (Inline Frame) is interfaced as Editor.

IFRAME

IE (3 or later) has introduced the concept of floating frames. These are much like standard frames, except they can be anywhere within a standard HTML document. A floating frame must be enclosed within

<iframe> ...
       </iframe>
elements. like this.

HTML
<iframe class="mytext" width="100%" ID="mytext" height="200">
</iframe>

Every IFRAME element in a document is an object that can be manipulated through scripting. By using the several methods and properties of IFRAME object we can do anything we like.

At frist when u including <iframe..> in the document you can't input or type anything you want. To make it work you need to set the designMode="On" for example.

JavaScript
myiframe.document.designMode="On";

To start writing in IFRAME you have to call open,write and close properly. like this.

JavaScript
myiframe.document.open();
mytext.document.write("Test");
myiframe.document.close();

There are more than 40 methods and several properties in IFRAME. For more information you can visit at Microsoft.

IFRAME Properties

className, document, id, innerHTML, innerText, isTextEdit, lang, language,
offsetHeight, offsetLeft, offsetParent, offsetTop, offsetWidth, outerHTML,
outerText, parentElement, parentTextEdit, sourceIndex, style, tagName, title,
align, border, borderColor, dataFld, dataSrc, frameBorder, height, hspace,
scrolling, src, vspace
and width. etc.

IFRAME Methods

We are looking at few methods that is used in our examples. execCommand, contains, getAttribute, insertAdjacentHTML, insertAdjacentText, removeAttribute, scrollIntoView and setAttribute, focus etc.

execCommand

Sets the given command to the text. Like bold, italic, underline, justifyleft, justifycenter, justifyright etc. like

JavaScript
myiframe.document.execCommand("bold");

contains

Checks whether the given element is contained within the object.

getAttribute

Retrieves the value of the specified attribute.

insertAdjacentHTML

Inserts the given HTML text into the element at the location.

scrollIntoView

Causes the object to scroll into view, aligning it either at the top or bottom of the window.

removeAttribute

Removes the given attribute from the object.

setAttribute

Sets the value of the specified attribute.

focus

Causes the element to receive the focus and executes the code specified by the

onfocus
event.

Example Time to see the real example of Scriptlet. This file (main.htm) includes "richtext.htm" in its <object..> tag. File: main.htm

HTML
<html>
<head></head>
<body>
<h2>I am main page that execute scriptlet</h2>
<object type="text/x-scriptlet" data= "richtext.htm"></object>
</body>
</html>
Lets use some important method and develop our own Rich text editor.
HTML
<!-- File: "richtext.htm" -->

<html>
<head>
</head>
<body>
<form>
    <input type=checkbox name=source value=1 OnClick="SourceCode(source.checked)">Source
    <input type=checkbox name=bold value=1 OnClick="RichtText('Bold')"><b>B</b>
    <input type=checkbox name=under value=1 OnClick="RichtText('underline')"><u>U</u>
    <input type=checkbox name=italic value=1 OnClick="RichtText('italic')"><i>I</i>

    <select name=align OnChange="RichAlign(this[this.selectedIndex].value)">
        <option value="justifyleft" selected>Left</option>
        <option value="justifycenter">Center</option>
        <option value="justifyright">Right</option>
    </select>
    
    <iframe class="mytext" width="100%" ID="mytext" height="200">
    </iframe>
    
    <script langauge="JavaScript">
        function RichtText(what) {
            mytext.document.execCommand(what);
            mytext.focus();
        }

        function RichAlign(what) {
            mytext.document.execCommand(what);
            mytext.focus();
        }

        function SourceCode(mode)
        {
            var htmtext;
            if(mode) {
                htmtext=mytext.document.body.innerHTML;
                mytext.document.body.innerText=htmtext;
            }
            else {
                htmtext=mytext.document.body.innerText;
                mytext.document.body.innerHTML=htmtext;
            }

        }    

        var bLoad=false
        var pureText=true
        var bodyTag="<body MONOSPACE STYLE=\"font:10pt arial,sans-serif\">"
        var bTextMode=false
        mytext.document.open();
        mytext.document.write(bodyTag);
        mytext.document.close();
        mytext.document.designMode="On";
    </script>
</form>

</body>
</html>

open main.htm. Isn't it cool?

F.A.Q

How to submit the text in the iframe to another page?

"d-lay" response is as follow.
It isn't possible to read from the IFrame as a form object, however you can use javascript to copy the text from the IFrame into a hidden field in your form and then submit.

Here's the function I added to allow you to do this

JavaScript
function savedocument() { // added 16-02-02 "D-Lay!" <webmaster@7thportal.org> 
  if (!isRTextMode()) return;
  setMode(1); //switch doc to html mode for save
  document.saveform.msg.value=mytext.document.body.innerText;
  setMode(0); //switch doc back to text mode
  document.saveform.submit(); // submit form for save
}

Wondering how can i put a default value or string into the text box?

See below. You have to change either var bodyTag or mytext.document.write(..). That's it!

JavaScript
var bLoad=false
var pureText=true

/** Default value here **/
var bodyTag="<body MONOSPACE bgcolor=green " +
            "STYLE=\"font:10pt arial,sans-serif\">My Text is here"

var bTextMode=false
mytext.document.open();
mytext.document.write(bodyTag);
mytext.document.close();
mytext.document.designMode="On";

Conclusion

I hope you've found this article interesting. This features is remarkably easy to use especially for DHTML code reusability. Being an ActiveX script, It can solve several problems. For demonstration, I tried Rich Text Editor. I encourage everyone to try it and send me some comments.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Web Developer
India India
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions

 
GeneralIFrame Pin
Anonymous8-Apr-03 10:08
Anonymous8-Apr-03 10:08 
GeneralRe: IFrame Pin
Anonymous6-Dec-03 23:39
Anonymous6-Dec-03 23:39 
GeneralStyle sheet Pin
leewsimpson24-Mar-03 4:44
leewsimpson24-Mar-03 4:44 
GeneralInvalid Links Pin
david.hughes27-Feb-03 21:56
david.hughes27-Feb-03 21:56 
GeneralRe: Invalid Links Pin
juan954923-Jul-03 22:35
juan954923-Jul-03 22:35 
GeneralSkip the Servlet Entirely Pin
Anonymous20-Feb-03 10:48
Anonymous20-Feb-03 10:48 
GeneralHowTo Really Set and Submit the HTML Pin
Moe Cazzell19-Feb-03 9:14
Moe Cazzell19-Feb-03 9:14 
GeneralRe: HowTo Really Set and Submit the HTML Pin
Anonymous19-Feb-03 12:58
Anonymous19-Feb-03 12:58 
To see an even better example of doing this, download the zip (to get the images) and then create the following three files (testeditor.htm , htmleditor.htm , colorselect.htm ), and open testeditor.htm

Implements color selection, the control now automatically sizes itself based upon the size parameter that you pass to the object, and the scriptlet interface has been modified. This code was pieced together from the previous examples and various web borrowings, but works good.. no credit is claimed.. probably should only be used as example.

testeditor.htm : Test the Html Editor Page (replacing index.htm)

<html>
<head>
<title>Test Html Editor</title>
</head>

<body bgcolor="#FFFFFF">
<center>

<H1>Testing an HTML Editor</H1>

<script>
<!--

function document.onreadystatechange() {
if (document.readyState == 'complete') {
editor.SetHTML('<P><STRONG>Sample Default Text</STRONG></P>');
editor.Focus();
}
}

function SubmitEditor() {
alert(editor.GetHTML());
}
// -->
</script>

<p><object id="editor" data="htmleditor.htm" align="baseline" border="0" width="500" height="300" type="text/x-scriptlet"></object></p>
<p><button type=button onclick="SubmitEditor()">Submit HTML</button></p>

</center>
</body>
</html>

htmleditor.htm : the html editor scriptlet (replacing main.htm)

<html>
<head>
<title>HTML Editor</title>

<!-- Styles -->
<style type="text/css">
<!--
SELECT {
BACKGROUND: White; FONT: 8pt verdana,arial,sans-serif
}
TABLE {
POSITION: relative
}
BODY {
BORDER-BOTTOM: 0px; BORDER-LEFT: 0px; BORDER-RIGHT: 0px; BORDER-TOP: 0px; MARGIN: 5px
}
.Heading {
BACKGROUND: lightgrey; COLOR: navy
}
.EditBox {
BACKGROUND-COLOR: #ffffff; POSITION: relative
}
.Toolbar {
BACKGROUND-COLOR: buttonface; BORDER-BOTTOM: buttonshadow 1px solid; BORDER-LEFT: buttonhighlight 1px solid; BORDER-RIGHT: buttonshadow 1px solid; BORDER-TOP: buttonhighlight 1px solid; HEIGHT: 27px; LEFT: 0px; POSITION: relative; TOP: 0px
}
.ButtonNormal {
BACKGROUND-COLOR: buttonface; BORDER-BOTTOM: buttonface 1px solid; BORDER-LEFT: buttonface 1px solid; BORDER-RIGHT: buttonface 1px solid; BORDER-TOP: buttonface 1px solid;
}
.Image {
LEFT: -1px; POSITION: relative; TOP: -1px; WIDTH: 22px
}
.Divider {
BORDER-LEFT: buttonshadow 1px solid; BORDER-RIGHT: buttonhighlight 1px solid; FONT-SIZE: 0px; HEIGHT: 22px; POSITION: absolute; TOP: 1px; WIDTH: 1px
}
.List {
FONT: 8pt verdana,arial,sans-serif; POSITION: relative; TOP: 2px
}
.Text {
FONT: 8pt verdana,arial,sans-serif; POSITION: relative; TOP: 2px
}
.ButtonMouseOver {
BACKGROUND-COLOR: buttonface; BORDER-BOTTOM: buttonshadow 1px solid; BORDER-LEFT: buttonhighlight 1px solid; BORDER-RIGHT: buttonshadow 1px solid; BORDER-TOP: buttonhighlight 1px solid;
}
.ButtonDisabled {
BACKGROUND-COLOR: buttonface; BORDER-BOTTOM: buttonhighlight 1px solid; BORDER-LEFT: buttonshadow 1px solid; BORDER-RIGHT: buttonhighlight 1px solid; BORDER-TOP: buttonshadow 1px solid;
}
.ButtonPressed {
BACKGROUND-COLOR: gainsboro; BORDER-BOTTOM: buttonhighlight 1px solid; BORDER-LEFT: buttonshadow 1px solid; BORDER-RIGHT: buttonhighlight 1px solid; BORDER-TOP: buttonshadow 1px solid;
}
-->
</style>

</head>

<body STYLE="margin:0pt;padding:2pt">

<SCRIPT>
<!--

function UtilBeginScript()
{
return String.fromCharCode(60, 115, 99, 114, 105, 112, 116, 62);
}

function UtilEndScript()
{
return String.fromCharCode(60, 47, 115, 99, 114, 105, 112, 116, 62);
}

function IDGenerator(nextID)
{
this.nextID = nextID;
this.GenerateID = IDGeneratorGenerateID;
}

function IDGeneratorGenerateID()
{
return this.nextID++;
}

var BUTTON_IMAGE_PREFIX = "buttonImage";
var BUTTON_DIV_PREFIX = "buttonDiv";
var BUTTON_PAD1_PREFIX = "buttonPad1";
var BUTTON_PAD2_PREFIX = "buttonPad2";
var buttonMap = new Object();

function Button
(
idGenerator,
caption,
action,
image
)
{
this.idGenerator = idGenerator;
this.caption = caption;
this.action = action;
this.image = image;
this.enabled = true;
this.Instantiate = ButtonInstantiate;
this.Enable = ButtonEnable;
}

function ButtonInstantiate()
{
this.id = this.idGenerator.GenerateID();
buttonMap[this.id] = this;
var html = "";
html += '<div id="';
html += BUTTON_DIV_PREFIX;
html += this.id;
html += '" class="ButtonNormal"';
html += ' onselectstart="ButtonOnSelectStart()"';
html += ' ondragstart="ButtonOnDragStart()"';
html += ' onmousedown="ButtonOnMouseDown(this)"';
html += ' onmouseup="ButtonOnMouseUp(this)"';
html += ' onmouseout="ButtonOnMouseOut(this)"';
html += ' onmouseover="ButtonOnMouseOver(this)"';
html += ' onclick="ButtonOnClick(this)"';
html += ' ondblclick="ButtonOnDblClick(this)"';
html += '>';
html += '<table cellpadding=0 cellspacing=0 border=0><tr><td><img id="';
html += BUTTON_PAD1_PREFIX;
html += this.id;
html += '" width=2 height=2></td><td></td><td></td></tr><tr><td></td><td>';
html += '<img id="';
html += BUTTON_IMAGE_PREFIX;
html += this.id;
html += '" src="';
html += this.image;
html += '" title="';
html += this.caption;
html += '" class="Image"';
html += '>';
html += '</td><td></td></tr><tr><td></td><td></td><td><img id="';
html += BUTTON_PAD2_PREFIX;
html += this.id;
html += '" width=2 height=2></td></tr></table>';
html += '</div>';
document.write(html);
}

function ButtonEnable(enabled)
{
this.enabled = enabled;
if (this.enabled)
{
document.all[BUTTON_DIV_PREFIX + this.id].className = "ButtonNormal";
}
else
{
document.all[BUTTON_DIV_PREFIX + this.id].className = "ButtonDisabled";
}
}

function ButtonOnSelectStart()
{
window.event.returnValue = false;
}

function ButtonOnDragStart()
{
window.event.returnValue = false;
}

function ButtonOnMouseDown(element)
{
if (event.button == 1)
{
var id = element.id.substring(BUTTON_DIV_PREFIX.length, element.id.length);
var button = buttonMap[id];
if (button.enabled)
{
ButtonPushButton(id);
}
}
}

function ButtonOnMouseUp(element)
{
if (event.button == 1)
{
var id = element.id.substring(BUTTON_DIV_PREFIX.length, element.id.length);
var button = buttonMap[id];
if (button.enabled)
{
ButtonReleaseButton(id);
}
}
}

function ButtonOnMouseOut(element)
{
var id = element.id.substring(BUTTON_DIV_PREFIX.length, element.id.length);
var button = buttonMap[id];
if (button.enabled)
{
ButtonReleaseButton(id);
}
}

function ButtonOnMouseOver(element)
{
var id = element.id.substring(BUTTON_DIV_PREFIX.length, element.id.length);
var button = buttonMap[id];
if (button.enabled)
{
ButtonReleaseButton(id);
document.all[BUTTON_DIV_PREFIX + id].className = "ButtonMouseOver";
}
}

function ButtonOnClick(element)
{
var id = element.id.substring(BUTTON_DIV_PREFIX.length, element.id.length);
var button = buttonMap[id];
if (button.enabled)
{
eval(button.action);
}
}

function ButtonOnDblClick(element)
{
ButtonOnClick(element);
}

function ButtonPushButton(id)
{
document.all[BUTTON_PAD1_PREFIX + id].width = 3;
document.all[BUTTON_PAD1_PREFIX + id].height = 3;
document.all[BUTTON_PAD2_PREFIX + id].width = 1;
document.all[BUTTON_PAD2_PREFIX + id].height = 1;
document.all[BUTTON_DIV_PREFIX + id].className = "ButtonPressed";
}

function ButtonReleaseButton(id)
{
document.all[BUTTON_PAD1_PREFIX + id].width = 2;
document.all[BUTTON_PAD1_PREFIX + id].height = 2;
document.all[BUTTON_PAD2_PREFIX + id].width = 2;
document.all[BUTTON_PAD2_PREFIX + id].height = 2;
document.all[BUTTON_DIV_PREFIX + id].className = "ButtonNormal";
}

var EDITOR_COMPOSITION_PREFIX = "editorComposition";
var EDITOR_PARAGRAPH_PREFIX = "editorParagraph";
var EDITOR_LIST_AND_INDENT_PREFIX = "editorListAndIndent";
var EDITOR_TOP_TOOLBAR_PREFIX = "editorTopToolbar";
var EDITOR_BOTTOM_TOOLBAR_PREFIX = "editorBottomToolbar";
var editorMap = new Object();
var editorIDGenerator = new IDGenerator(0);

function Editor()
{
this.GetText = EditorGetText;
this.SetText = EditorSetText;
this.GetHTML = EditorGetHTML;
this.SetHTML = EditorSetHTML;
this.GetBrief = EditorGetBrief;
this.SetBrief = EditorSetBrief;
this.Focus = EditorFocus;
this.SetDomain = SetDomain;
this.Instantiate = EditorInstantiate;

this.textMode = false;
this.brief = false;
this.instantiated = false;
this.id = editorIDGenerator.GenerateID();
}

function EditorInstantiate()
{
if (this.instantiated) {
return;
}
editorMap[this.id] = this;

var html = "";

html += "<div id=\"" + EDITOR_TOP_TOOLBAR_PREFIX + this.id + "\" class=\"Toolbar\">";
html += "<table cellpaddin=\"0\" cellspacing=\"0\" border=\"0\">";
html += "<tr>";
html += "<td>";
html += "<span id=\"" + EDITOR_PARAGRAPH_PREFIX + this.id + "\" style=\"display:" + (this.brief ? "none" : "inline") + "\">";
html += "<select class=\"List\" onchange=\"EditorOnParagraph(" + this.id + ", this)\">";
html += "<option class=\"Heading\">Paragraph</option>";
html += "<option value=\"Normal\">Normal</option>";
html += "<option value=\"Heading 1\">Heading 1 &lt;H1&gt;</option>";
html += "<option value=\"Heading 2\">Heading 2 &lt;H2&gt;</option>";
html += "<option value=\"Heading 3\">Heading 3 &lt;H3&gt;</option>";
html += "<option value=\"Heading 4\">Heading 4 &lt;H4&gt;</option>";
html += "<option value=\"Heading 5\">Heading 5 &lt;H5&gt;</option>";
html += "<option value=\"Heading 6\">Heading 6 &lt;H6&gt;</option>";
html += "<option value=\"Address\">Address &lt;ADDR&gt;</option>";
html += "<option value=\"Formatted\">Formatted &lt;PRE&gt;</option>";
html += "</select>";
html += "</span>";
html += "</td>";
html += "<td>";
html += "<select class=\"List\" onchange=\"EditorOnFont(" + this.id + ", this)\">";
html += "<option class=\"Heading\">Font</option>";
html += "<option value=\"Arial\">Arial</option>";
html += "<option value=\"Arial Black\">Arial Black</option>";
html += "<option value=\"Arial Narrow\">Arial Narrow</option>";
html += "<option value=\"Comic Sans MS\">Comic Sans MS</option>";
html += "<option value=\"Courier New\">Courier New</option>";
html += "<option value=\"System\">System</option>";
html += "<option value=\"Times New Roman\">Times New Roman</option>";
html += "<option value=\"Verdana\">Verdana</option>";
html += "<option value=\"Wingdings\">Wingdings</option>";
html += "</select>";
html += "</td>";
html += "<td>";
html += "<select class=\"List\" onchange=\"EditorOnSize(" + this.id + ", this)\">";
html += "<option class=\"Heading\">Size</option>";
html += "<option value=\"1\">1</option>";
html += "<option value=\"2\">2</option>";
html += "<option value=\"3\">3</option>";
html += "<option value=\"4\">4</option>";
html += "<option value=\"5\">5</option>";
html += "<option value=\"6\">6</option>";
html += "<option value=\"7\">7</option>";
html += "</select>";
html += "</td>";
html += "<td>";
html += "<div class=\"Divider\"></div>";
html += "</td>";
html += "<td class=\"Text\">";
html += "<input type=\"checkbox\" onclick=\"EditorOnViewHTMLSource(" + this.id + ", this.checked)\">";
html += "View HTML Source";
html += "</td>";
html += "</tr>";
html += "</table>";
html += "</div>";

html += "<div id=\"" + EDITOR_BOTTOM_TOOLBAR_PREFIX + this.id + "\" class=\"Toolbar\">";
html += "<table cellpaddin=\"0\" cellspacing=\"0\" border=\"0\">";
html += "<tr>";
html += "<td>";
html += UtilBeginScript();
html += "var cutButton = new Button(";
html += "editorIDGenerator,";
html += "\"Cut\",";
html += "\"EditorOnCut(" + this.id + ")\",";
html += "\"cut.gif\"";
html += ");";
html += "cutButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var copyButton = new Button(";
html += "editorIDGenerator,";
html += "\"Copy\",";
html += "\"EditorOnCopy(" + this.id + ")\",";
html += "\"copy.gif\"";
html += ");";
html += "copyButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var pasteButton = new Button(";
html += "editorIDGenerator,";
html += "\"Paste\",";
html += "\"EditorOnPaste(" + this.id + ")\",";
html += "\"paste.gif\"";
html += ");";
html += "pasteButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += "<div class=\"Divider\"></div>";
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var boldButton = new Button(";
html += "editorIDGenerator,";
html += "\"Bold\",";
html += "\"EditorOnBold(" + this.id + ")\",";
html += "\"bold.gif\"";
html += ");";
html += "boldButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var italicButton = new Button(";
html += "editorIDGenerator,";
html += "\"Italic\",";
html += "\"EditorOnItalic(" + this.id + ")\",";
html += "\"italic.gif\"";
html += ");";
html += "italicButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var underlineButton = new Button(";
html += "editorIDGenerator,";
html += "\"Underline\",";
html += "\"EditorOnUnderline(" + this.id + ")\",";
html += "\"under.gif\"";
html += ");";
html += "underlineButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += "<div class=\"Divider\"></div>";
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var foregroundColorButton = new Button(";
html += "editorIDGenerator,";
html += "\"Foreground Color\",";
html += "\"EditorOnForegroundColor(" + this.id + ")\",";
html += "\"tpaint.gif\"";
html += ");";
html += "foregroundColorButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var backgroundColorButton = new Button(";
html += "editorIDGenerator,";
html += "\"Background Color\",";
html += "\"EditorOnBackgroundColor(" + this.id + ")\",";
html += "\"parea.gif\"";
html += ");";
html += "backgroundColorButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += "<div class=\"Divider\"></div>";
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var alignLeftButton = new Button(";
html += "editorIDGenerator,";
html += "\"Align Left\",";
html += "\"EditorOnAlignLeft(" + this.id + ")\",";
html += "\"aleft.gif\"";
html += ");";
html += "alignLeftButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var centerButton = new Button(";
html += "editorIDGenerator,";
html += "\"Center\",";
html += "\"EditorOnCenter(" + this.id + ")\",";
html += "\"center.gif\"";
html += ");";
html += "centerButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var alignRightButton = new Button(";
html += "editorIDGenerator,";
html += "\"Align Right\",";
html += "\"EditorOnAlignRight(" + this.id + ")\",";
html += "\"aright.gif\"";
html += ");";
html += "alignRightButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += "<div class=\"Divider\"></div>";
html += "</td>";
html += "<td id=\"" + EDITOR_LIST_AND_INDENT_PREFIX + this.id + "\" style=\"display:" + (this.brief ? "none" : "inline") + "\">";
html += "<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">";
html += "<tr>";
html += "<td>";
html += UtilBeginScript();
html += "var numberedListButton = new Button(";
html += "editorIDGenerator,";
html += "\"Numbered List\",";
html += "\"EditorOnNumberedList(" + this.id + ")\",";
html += "\"nlist.gif\"";
html += ");";
html += "numberedListButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var bullettedListButton = new Button(";
html += "editorIDGenerator,";
html += "\"Bulletted List\",";
html += "\"EditorOnBullettedList(" + this.id + ")\",";
html += "\"blist.gif\"";
html += ");";
html += "bullettedListButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += "<div class=\"Divider\"></div>";
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var decreaseIndentButton = new Button(";
html += "editorIDGenerator,";
html += "\"Decrease Indent\",";
html += "\"EditorOnDecreaseIndent(" + this.id + ")\",";
html += "\"ileft.gif\"";
html += ");";
html += "decreaseIndentButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var increaseIndentButton = new Button(";
html += "editorIDGenerator,";
html += "\"Increase Indent\",";
html += "\"EditorOnIncreaseIndent(" + this.id + ")\",";
html += "\"iright.gif\"";
html += ");";
html += "increaseIndentButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "<td>";
html += "<div class=\"Divider\"></div>";
html += "</td>";
html += "</tr>";
html += "</table>";
html += "</td>";
html += "<td>";
html += UtilBeginScript();
html += "var createHyperlinkButton = new Button(";
html += "editorIDGenerator,";
html += "\"Create Hyperlink\",";
html += "\"EditorOnCreateHyperlink(" + this.id + ")\",";
html += "\"wlink.gif\"";
html += ");";
html += "createHyperlinkButton.Instantiate();";
html += UtilEndScript();
html += "</td>";
html += "</tr>";
html += "</table>";
html += "</div>";

document.write(html); html = "";

var EditBoxHeight = (document.body.offsetHeight - 2) - (document.all[EDITOR_BOTTOM_TOOLBAR_PREFIX + this.id].offsetHeight+document.all[EDITOR_TOP_TOOLBAR_PREFIX + this.id].offsetHeight);

html += "<iframe class=\"EditBox\" id=\"" + EDITOR_COMPOSITION_PREFIX + this.id + "\" width=\"100%\" height=\"" + EditBoxHeight + "\" onblur=\"EditorOnBlur(" + this.id + ")\">";
html += "</iframe>";

document.write(html); html = "";

html += '<body style="font:10pt arial">';
html += '</body>';
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.open();
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.write(html);
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.close();
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.designMode = "on";
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.onclick = new Function("EditorOnClick(" + this.id + ")");

this.instantiated = true;
}

function EditorGetText()
{
return eval(EDITOR_COMPOSITION_PREFIX + this.id).document.body.innerText;
}

function EditorSetText(text)
{
text = text.replace(/\n/g, "<br>");
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.body.innerHTML = text;
}

function EditorGetHTML()
{
if (this.textMode) {
return eval(EDITOR_COMPOSITION_PREFIX + this.id).document.body.innerText;
}
return eval(EDITOR_COMPOSITION_PREFIX + this.id).document.body.innerHTML;
}

function EditorSetHTML(html)
{
if (this.textMode) {
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.body.innerText = html;
}
else {
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.body.innerHTML = html;
}
}

function EditorGetBrief()
{
return this.brief;
}

function EditorSetBrief(brief)
{
this.brief = brief;
var display = this.brief ? "none" : "inline";
if (this.instantiated) {
eval(EDITOR_PARAGRAPH_PREFIX + this.id).style.display = display;
eval(EDITOR_LIST_AND_INDENT_PREFIX + this.id).style.display = display;
}
}

function EditorFocus()
{
eval(EDITOR_COMPOSITION_PREFIX + this.id).focus();
}

function SetDomain(d)
{
eval(EDITOR_COMPOSITION_PREFIX + this.id).document.domain = d;
}

function EditorOnCut(id)
{
EditorFormat(id, "cut");
}

function EditorOnCopy(id)
{
EditorFormat(id, "copy");
}

function EditorOnPaste(id)
{
EditorFormat(id, "paste");
}

function EditorOnBold(id)
{
EditorFormat(id, "bold");
}

function EditorOnItalic(id)
{
EditorFormat(id, "italic");
}

function EditorOnUnderline(id)
{
EditorFormat(id, "underline");
}

function EditorOnForegroundColor(id)
{
if (!EditorValidateMode(id)) {
return;
}
var color = showModalDialog("colorselect.htm", "", "font-family:Verdana;font-size:12;dialogWidth:28em;dialogHeight:32em");
if (color) {
EditorFormat(id, "forecolor", color);
}
else {

eval(EDITOR_COMPOSITION_PREFIX + id).focus();
}
}

function EditorOnBackgroundColor(id)
{
if (!EditorValidateMode(id)) {
return;
}
var color = showModalDialog("colorselect.htm", "", "font-family:Verdana;font-size:12;dialogWidth:28em;dialogHeight:32em");
if (color) {
EditorFormat(id, "backcolor", color);
}
else {
eval(EDITOR_COMPOSITION_PREFIX + id).focus();
}
}

function EditorOnAlignLeft(id)
{
EditorFormat(id, "justifyleft");
}

function EditorOnCenter(id)
{
EditorFormat(id, "justifycenter");
}

function EditorOnAlignRight(id)
{
EditorFormat(id, "justifyright");
}

function EditorOnNumberedList(id)
{
EditorFormat(id, "insertOrderedList");
}

function EditorOnBullettedList(id)
{
EditorFormat(id, "insertUnorderedList");
}

function EditorOnDecreaseIndent(id)
{
EditorFormat(id, "outdent");
}

function EditorOnIncreaseIndent(id)
{
EditorFormat(id, "indent");
}

function EditorOnCreateHyperlink(id)
{
if (!EditorValidateMode(id)) {
return;
}
var anchor = EditorGetElement("A", eval(EDITOR_COMPOSITION_PREFIX + id).document.selection.createRange().parentElement());
var link = prompt("enter link location (eg. http://www.mydomain.com):", anchor ? anchor.href : "http://");
if (link && link != "http://") {
if (eval(EDITOR_COMPOSITION_PREFIX + id).document.selection.type == "None") {
var range = eval(EDITOR_COMPOSITION_PREFIX + id).document.selection.createRange();
range.pasteHTML('<A HREF="' + link + '"></A>');
range.select();
}
else {
EditorFormat(id, "CreateLink", link);
}
}
}

function EditorOnParagraph(id, select)
{
EditorFormat(id, "formatBlock", select[select.selectedIndex].value);
select.selectedIndex = 0;
}

function EditorOnFont(id, select)
{
EditorFormat(id, "fontname", select[select.selectedIndex].value);
select.selectedIndex = 0;
}

function EditorOnSize(id, select)
{
EditorFormat(id, "fontsize", select[select.selectedIndex].value);
select.selectedIndex = 0;
}

function EditorOnViewHTMLSource(id, textMode)
{
var editor = editorMap[id];
editor.textMode = textMode;
if (editor.textMode) {
eval(EDITOR_COMPOSITION_PREFIX + id).document.body.innerText = eval(EDITOR_COMPOSITION_PREFIX + id).document.body.innerHTML;
}
else {
eval(EDITOR_COMPOSITION_PREFIX + id).document.body.innerHTML = eval(EDITOR_COMPOSITION_PREFIX + id).document.body.innerText;
}
eval(EDITOR_COMPOSITION_PREFIX + id).focus();
}

function EditorOnClick(id)
{
}

function EditorOnBlur(id)
{
}

function EditorValidateMode(id)
{
var editor = editorMap[id];
if (!editor.textMode) {
return true;
}
alert("Please uncheck the \"View HTML Source\" checkbox to use the toolbars.");
eval(EDITOR_COMPOSITION_PREFIX + id).focus();
return false;
}

function EditorFormat(id, what, opt)
{
if (!EditorValidateMode(id)) {
return;
}
if (opt == "removeFormat") {
what = opt;
opt = null;
}
if (opt == null) {
eval(EDITOR_COMPOSITION_PREFIX + id).document.execCommand(what);
}
else {
eval(EDITOR_COMPOSITION_PREFIX + id).document.execCommand(what, "", opt);
}
}

function EditorCleanHTML(id)
{
var fonts = eval(EDITOR_COMPOSITION_PREFIX + id).document.body.all.tags("FONT");
for (var i = fonts.length - 1; i >= 0; i--) {
var font = fonts[i];
if (font.style.backgroundColor == "#ffffff") {
font.outerHTML = font.innerHTML;
}
}
}

function EditorGetElement(tagName, start)
{
while (start && start.tagName != tagName) {
start = start.parentElement;
}
return start;
}

public_description=new Editor

public_description.Instantiate();

// -->
</SCRIPT>

</body>
</html>

colorselect.htm : implementing color selection

<html>
<head>
<title>Color Select</title>

<style type="text/css">
body {margin:10; font:arial,helvetica; background:menu}
button {width:5em}
table.CTab {cursor:hand}
.CTab TD {border: solid 2px #ffffff;}
</style>
</head>

<body class="bgd">
<script>
var selected = "c00";
function CTabCLICK()
{
document.all[selected].style.borderColor = "white";
selected = event.srcElement.id;
document.all[selected].style.borderColor = "black";
ShowSelected();
}

function CTabOVER()
{
RGB.innerText = event.srcElement.bgColor;
SAMP.style.backgroundColor = event.srcElement.bgColor;
}

function CTabOUT()
{
ShowSelected();
}

function Done()
{
window.returnValue = SAMP.style.backgroundColor;
window.close();
}

function Cancel()
{
window.close();
}

function ShowSelected()
{
RGB.innerText = document.all[selected].bgColor;
SAMP.style.backgroundColor = document.all[selected].bgColor;
}
</script>

<center>
<table bgcolor=white cellpadding=4 cellspacing=0 border=0>
<tr>
<td>
<center>
<table class="CTab" ID=ColorTable border=0 cellspacing=0 cellpadding=0 onclick="CTabCLICK();" onmouseover="CTabOVER();" onmouseout="CTabOUT();" width=300>
<tr>
<td id=c00 bgcolor="#000000" title="#000000" style="border:solid 2px black;">&nbsp;</td>
<td id=c01 bgcolor="#111111" title="#111111">&nbsp;</td>
<td id=c02 bgcolor="#2a2a2a" title="#2a2a2a">&nbsp;</td>
<td id=c03 bgcolor="#434343" title="#434343">&nbsp;</td>
<td id=c04 bgcolor="#5b5b5b" title="#5b5b5b">&nbsp;</td>
<td id=c05 bgcolor="#737373" title="#737373">&nbsp;</td>
<td id=c06 bgcolor="#8b8b8b" title="#8b8b8b">&nbsp;</td>
<td id=c07 bgcolor="#a2a2a2" title="#a2a2a2">&nbsp;</td>
<td id=c08 bgcolor="#b9b9b9" title="#b9b9b9">&nbsp;</td>
<td id=c09 bgcolor="#d0d0d0" title="#d0d0d0">&nbsp;</td>
<td id=c0a bgcolor="#e6e6e6" title="#e6e6e6">&nbsp;</td>
<td id=c0b bgcolor="#ffffff" title="#ffffff">&nbsp;</td>
</tr>
<tr>
<td id=c10 bgcolor="#7f7f00" title="#7f7f00">&nbsp;</td>
<td id=c11 bgcolor="#bfbf00" title="#bfbf00">&nbsp;</td>
<td id=c12 bgcolor="#ffff00" title="#ffff00">&nbsp;</td>
<td id=c13 bgcolor="#ffff40" title="#ffff40">&nbsp;</td>
<td id=c14 bgcolor="#ffff80" title="#ffff80">&nbsp;</td>
<td id=c15 bgcolor="#ffffbf" title="#ffffbf">&nbsp;</td>
<td id=c16 bgcolor="#525330" title="#525330">&nbsp;</td>
<td id=c17 bgcolor="#898a49" title="#898a49">&nbsp;</td>
<td id=c18 bgcolor="#aea945" title="#aea945">&nbsp;</td>
<td id=c19 bgcolor="#c3be71" title="#c3be71">&nbsp;</td>
<td id=c1a bgcolor="#e0dcaa" title="#e0dcaa">&nbsp;</td>
<td id=c1b bgcolor="#fcfae1" title="#fcfae1">&nbsp;</td>
</tr>
<tr>
<td id=c20 bgcolor="#407f00" title="#407f00">&nbsp;</td>
<td id=c21 bgcolor="#60bf00" title="#60bf00">&nbsp;</td>
<td id=c22 bgcolor="#80ff00" title="#80ff00">&nbsp;</td>
<td id=c23 bgcolor="#a0ff40" title="#a0ff40">&nbsp;</td>
<td id=c24 bgcolor="#c0ff80" title="#c0ff80">&nbsp;</td>
<td id=c25 bgcolor="#dfffbf" title="#dfffbf">&nbsp;</td>
<td id=c26 bgcolor="#3b5738" title="#3b5738">&nbsp;</td>
<td id=c27 bgcolor="#668f5a" title="#668f5a">&nbsp;</td>
<td id=c28 bgcolor="#7f9757" title="#7f9757">&nbsp;</td>
<td id=c29 bgcolor="#8a9b55" title="#8a9b55">&nbsp;</td>
<td id=c2a bgcolor="#b7c296" title="#b7c296">&nbsp;</td>
<td id=c2b bgcolor="#e6ebd5" title="#e6ebd5">&nbsp;</td>
</tr>
<tr>
<td id=c30 bgcolor="#007f40" title="#007f40">&nbsp;</td>
<td id=c31 bgcolor="#00bf60" title="#00bf60">&nbsp;</td>
<td id=c32 bgcolor="#00ff80" title="#00ff80">&nbsp;</td>
<td id=c33 bgcolor="#40ffa0" title="#40ffa0">&nbsp;</td>
<td id=c34 bgcolor="#80ffc0" title="#80ffc0">&nbsp;</td>
<td id=c35 bgcolor="#bfffdf" title="#bfffdf">&nbsp;</td>
<td id=c36 bgcolor="#033d21" title="#033d21">&nbsp;</td>
<td id=c37 bgcolor="#438059" title="#438059">&nbsp;</td>
<td id=c38 bgcolor="#7fa37c" title="#7fa37c">&nbsp;</td>
<td id=c39 bgcolor="#8dae94" title="#8dae94">&nbsp;</td>
<td id=c3a bgcolor="#acc6b5" title="#acc6b5">&nbsp;</td>
<td id=c3b bgcolor="#ddebe2" title="#ddebe2">&nbsp;</td>
</tr>
<tr>
<td id=c40 bgcolor="#007f7f" title="#007f7f">&nbsp;</td>
<td id=c41 bgcolor="#00bfbf" title="#00bfbf">&nbsp;</td>
<td id=c42 bgcolor="#00ffff" title="#00ffff">&nbsp;</td>
<td id=c43 bgcolor="#40ffff" title="#40ffff">&nbsp;</td>
<td id=c44 bgcolor="#80ffff" title="#80ffff">&nbsp;</td>
<td id=c45 bgcolor="#bfffff" title="#bfffff">&nbsp;</td>
<td id=c46 bgcolor="#033d3d" title="#033d3d">&nbsp;</td>
<td id=c47 bgcolor="#347d7e" title="#347d7e">&nbsp;</td>
<td id=c48 bgcolor="#609a9f" title="#609a9f">&nbsp;</td>
<td id=c49 bgcolor="#96bdc4" title="#96bdc4">&nbsp;</td>
<td id=c4a bgcolor="#b5d1d7" title="#b5d1d7">&nbsp;</td>
<td id=c4b bgcolor="#e2f1f4" title="#e2f1f4">&nbsp;</td>
</tr>
<tr>
<td id=c50 bgcolor="#00407f" title="#00407f">&nbsp;</td>
<td id=c51 bgcolor="#0060bf" title="#0060bf">&nbsp;</td>
<td id=c52 bgcolor="#0080ff" title="#0080ff">&nbsp;</td>
<td id=c53 bgcolor="#40a0ff" title="#40a0ff">&nbsp;</td>
<td id=c54 bgcolor="#80c0ff" title="#80c0ff">&nbsp;</td>
<td id=c55 bgcolor="#bfdfff" title="#bfdfff">&nbsp;</td>
<td id=c56 bgcolor="#1b2c48" title="#1b2c48">&nbsp;</td>
<td id=c57 bgcolor="#385376" title="#385376">&nbsp;</td>
<td id=c58 bgcolor="#57708f" title="#57708f">&nbsp;</td>
<td id=c59 bgcolor="#7792ac" title="#7792ac">&nbsp;</td>
<td id=c5a bgcolor="#a8bed1" title="#a8bed1">&nbsp;</td>
<td id=c5b bgcolor="#deebf6" title="#deebf6">&nbsp;</td>
</tr>
<tr>
<td id=c60 bgcolor="#00007f" title="#00007f">&nbsp;</td>
<td id=c61 bgcolor="#0000bf" title="#0000bf">&nbsp;</td>
<td id=c62 bgcolor="#0000ff" title="#0000ff">&nbsp;</td>
<td id=c63 bgcolor="#4040ff" title="#4040ff">&nbsp;</td>
<td id=c64 bgcolor="#8080ff" title="#8080ff">&nbsp;</td>
<td id=c65 bgcolor="#bfbfff" title="#bfbfff">&nbsp;</td>
<td id=c66 bgcolor="#212143" title="#212143">&nbsp;</td>
<td id=c67 bgcolor="#373e68" title="#373e68">&nbsp;</td>
<td id=c68 bgcolor="#444f75" title="#444f75">&nbsp;</td>
<td id=c69 bgcolor="#585e82" title="#585e82">&nbsp;</td>
<td id=c6a bgcolor="#8687a4" title="#8687a4">&nbsp;</td>
<td id=c6b bgcolor="#d2d1e1" title="#d2d1e1">&nbsp;</td>
</tr>
<tr>
<td id=c70 bgcolor="#40007f" title="#40007f">&nbsp;</td>
<td id=c71 bgcolor="#6000bf" title="#6000bf">&nbsp;</td>
<td id=c72 bgcolor="#8000ff" title="#8000ff">&nbsp;</td>
<td id=c73 bgcolor="#a040ff" title="#a040ff">&nbsp;</td>
<td id=c74 bgcolor="#c080ff" title="#c080ff">&nbsp;</td>
<td id=c75 bgcolor="#dfbfff" title="#dfbfff">&nbsp;</td>
<td id=c76 bgcolor="#302449" title="#302449">&nbsp;</td>
<td id=c77 bgcolor="#54466f" title="#54466f">&nbsp;</td>
<td id=c78 bgcolor="#655a7f" title="#655a7f">&nbsp;</td>
<td id=c79 bgcolor="#726284" title="#726284">&nbsp;</td>
<td id=c7a bgcolor="#9e8fa9" title="#9e8fa9">&nbsp;</td>
<td id=c7b bgcolor="#dcd1df" title="#dcd1df">&nbsp;</td>
</tr>
<tr>
<td id=c80 bgcolor="#7f007f" title="#7f007f">&nbsp;</td>
<td id=c81 bgcolor="#bf00bf" title="#bf00bf">&nbsp;</td>
<td id=c82 bgcolor="#ff00ff" title="#ff00ff">&nbsp;</td>
<td id=c83 bgcolor="#ff40ff" title="#ff40ff">&nbsp;</td>
<td id=c84 bgcolor="#ff80ff" title="#ff80ff">&nbsp;</td>
<td id=c85 bgcolor="#ffbfff" title="#ffbfff">&nbsp;</td>
<td id=c86 bgcolor="#4a234a" title="#4a234a">&nbsp;</td>
<td id=c87 bgcolor="#794a72" title="#794a72">&nbsp;</td>
<td id=c88 bgcolor="#936386" title="#936386">&nbsp;</td>
<td id=c89 bgcolor="#9d7292" title="#9d7292">&nbsp;</td>
<td id=c8a bgcolor="#c0a0b6" title="#c0a0b6">&nbsp;</td>
<td id=c8b bgcolor="#ecdae5" title="#ecdae5">&nbsp;</td>
</tr>
<tr>
<td id=c90 bgcolor="#7f003f" title="#7f003f">&nbsp;</td>
<td id=c91 bgcolor="#bf005f" title="#bf005f">&nbsp;</td>
<td id=c92 bgcolor="#ff007f" title="#ff007f">&nbsp;</td>
<td id=c93 bgcolor="#ff409f" title="#ff409f">&nbsp;</td>
<td id=c94 bgcolor="#ff80bf" title="#ff80bf">&nbsp;</td>
<td id=c95 bgcolor="#ffbfdf" title="#ffbfdf">&nbsp;</td>
<td id=c96 bgcolor="#451528" title="#451528">&nbsp;</td>
<td id=c97 bgcolor="#823857" title="#823857">&nbsp;</td>
<td id=c98 bgcolor="#a94a76" title="#a94a76">&nbsp;</td>
<td id=c99 bgcolor="#bc6f95" title="#bc6f95">&nbsp;</td>
<td id=c9a bgcolor="#d8a5bb" title="#d8a5bb">&nbsp;</td>
<td id=c9b bgcolor="#f7dde9" title="#f7dde9">&nbsp;</td>
</tr>
<tr>
<td id=ca0 bgcolor="#800000" title="#800000">&nbsp;</td>
<td id=ca1 bgcolor="#c00000" title="#c00000">&nbsp;</td>
<td id=ca2 bgcolor="#ff0000" title="#ff0000">&nbsp;</td>
<td id=ca3 bgcolor="#ff4040" title="#ff4040">&nbsp;</td>
<td id=ca4 bgcolor="#ff8080" title="#ff8080">&nbsp;</td>
<td id=ca5 bgcolor="#ffc0c0" title="#ffc0c0">&nbsp;</td>
<td id=ca6 bgcolor="#441415" title="#441415">&nbsp;</td>
<td id=ca7 bgcolor="#82393c" title="#82393c">&nbsp;</td>
<td id=ca8 bgcolor="#aa4d4e" title="#aa4d4e">&nbsp;</td>
<td id=ca9 bgcolor="#bc6e6e" title="#bc6e6e">&nbsp;</td>
<td id=caa bgcolor="#d8a3a4" title="#d8a3a4">&nbsp;</td>
<td id=cab bgcolor="#f8dddd" title="#f8dddd">&nbsp;</td>
</tr>
<tr>
<td id=cb0 bgcolor="#7f3f00" title="#7f3f00">&nbsp;</td>
<td id=cb1 bgcolor="#bf5f00" title="#bf5f00">&nbsp;</td>
<td id=cb2 bgcolor="#ff7f00" title="#ff7f00">&nbsp;</td>
<td id=cb3 bgcolor="#ff9f40" title="#ff9f40">&nbsp;</td>
<td id=cb4 bgcolor="#ffbf80" title="#ffbf80">&nbsp;</td>
<td id=cb5 bgcolor="#ffdfbf" title="#ffdfbf">&nbsp;</td>
<td id=cb6 bgcolor="#482c1b" title="#482c1b">&nbsp;</td>
<td id=cb7 bgcolor="#855a40" title="#855a40">&nbsp;</td>
<td id=cb8 bgcolor="#b27c51" title="#b27c51">&nbsp;</td>
<td id=cb9 bgcolor="#c49b71" title="#c49b71">&nbsp;</td>
<td id=cba bgcolor="#e1c4a8" title="#e1c4a8">&nbsp;</td>
<td id=cbb bgcolor="#fdeee0" title="#fdeee0">&nbsp;</td>
</tr>
</table>
</center>
</td>
</tr>
<tr>
<td align=right>
<table>
<tr>
<td id=RGB>#c0ff80</td>
<td><div style="width:24px; height:24px; background-color: #c0ff80; border: solid 1px black;" id="SAMP">&nbsp;</div></td>
</tr>
</table>

</td>
</tr>
<tr class="bbar">
<td align=center>
<input type="button" class="abutton" onclick="Done()" value="&nbsp;&nbsp;Done&nbsp;&nbsp;"> <input type="button" class="fbutton" onclick="Cancel()" value="Cancel">
</td>
</tr>
</table>
</center>
</body>
</html>

GeneralRe: HowTo Really Set and Submit the HTML Pin
anonymous coward31-Mar-03 9:45
anonymous coward31-Mar-03 9:45 
GeneralIframe - Problem Pin
Gulbarga4-Feb-03 19:54
Gulbarga4-Feb-03 19:54 
GeneralRe: Iframe - Problem Pin
Moe Cazzell19-Feb-03 9:32
Moe Cazzell19-Feb-03 9:32 
GeneralTo find out the cSS Style in the iFrame above.. Pin
Anonymous13-Jan-03 22:27
Anonymous13-Jan-03 22:27 
GeneralRe: To find out the cSS Style in the iFrame above.. Pin
Moe Cazzell25-Feb-03 10:37
Moe Cazzell25-Feb-03 10:37 
Generaliframe under security - get rid of browser alert message Pin
raphi9-Jan-03 3:55
raphi9-Jan-03 3:55 
GeneralRe: iframe under security - get rid of browser alert message Pin
Anonymous16-Mar-03 10:24
Anonymous16-Mar-03 10:24 
GeneralA little help please... Pin
Dustpup4-Jan-03 17:17
Dustpup4-Jan-03 17:17 
GeneralRe: A little help please... Pin
Dustpup4-Jan-03 18:35
Dustpup4-Jan-03 18:35 
GeneralTutorial Pin
slin4-Dec-02 6:25
slin4-Dec-02 6:25 
GeneralRe: Tutorial Pin
Steve McLenithan20-Dec-02 2:54
Steve McLenithan20-Dec-02 2:54 
GeneralSaving value from this editor Pin
AYSHA SAEED3-Dec-02 17:40
AYSHA SAEED3-Dec-02 17:40 
GeneralRe: Saving value from this editor Pin
Steve McLenithan20-Dec-02 2:53
Steve McLenithan20-Dec-02 2:53 
Generalsubmit text in the Iframe to Another page Pin
Suresh_u_n28-Nov-02 3:18
Suresh_u_n28-Nov-02 3:18 
GeneralSorry, but I don't understand this... Pin
dbdownunder20-Mar-03 21:24
dbdownunder20-Mar-03 21:24 
GeneralAddin Story Title and Created By Field Pin
scottyunt8-Nov-02 7:50
scottyunt8-Nov-02 7:50 
Generalwhen cursor is outside... Pin
eladr22-Oct-02 4:32
eladr22-Oct-02 4:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.