Click here to Skip to main content
15,883,901 members
Articles / Web Development / HTML

Fully JavaScript Enabled Editor

Rate me:
Please Sign up or sign in to vote.
4.60/5 (33 votes)
7 Sep 2010CPOL1 min read 65.4K   2.1K   116  
Fully JavaScript enabled editor which also contains some server coding
  • editorvbnet.zip
    • EditorVBNet
      • Default.aspx
      • Default.aspx.vb
      • editorimages
        • BackColor.gif
        • Bold.gif
        • ButtonDesign.gif
        • ButtonHtml.gif
        • ButtonPreview.gif
        • close.gif
        • ConvertToLower.gif
        • ConvertToUpper.gif
        • Copy.gif
        • Cut.gif
        • Delete.gif
        • Delete2.gif
        • Font.gif
        • FontSize.gif
        • ForeColor.gif
        • FormatCodeBlock.gif
        • ImageMapDialog.gif
        • Indent.gif
        • InsertDate.gif
        • InsertHorizontalRule.gif
        • InsertOrderedList.gif
        • InsertSymbol.gif
        • InsertTable.gif
        • InsertTime.gif
        • InsertUnorderedList.gif
        • Italic.gif
        • JustifyCenter.gif
        • JustifyFull.gif
        • JustifyLeft.gif
        • JustifyRight.gif
        • LinkManager.gif
        • Outdent.gif
        • Paste.gif
        • Print.gif
        • Redo.gif
        • RemoveFormat.gif
        • SelectAll.gif
        • StrikeThrough.gif
        • Subscript.gif
        • Superscript.gif
        • Thumbs.db
        • toolbarstart.gif
        • Underline.gif
        • Undo.gif
        • zoomInIcon.gif
        • zoomOutIcon.gif
      • EditorScript.js
      • EditorStyle.css
      • imgWindow.aspx
      • imgWindow.aspx.vb
      • InsertLink.htm
      • InsertTable.htm
      • NEditor.ascx
      • NEditor.ascx.vb
      • SpecialChars.htm
      • uploadsDir
        • imagefiles
          • ball.gif
          • dog.jpg
          • dolphin.jpg
          • eye.jpg
          • image004.jpg
          • image009.jpg
          • mob1.jpg
          • Thumbs.db
          • WATERsky.jpg
  • editorphp.zip
    • EditorPHP
      • default.php
      • editorimages
        • BackColor.gif
        • Bold.gif
        • ButtonDesign.gif
        • ButtonHtml.gif
        • ButtonPreview.gif
        • close.gif
        • ConvertToLower.gif
        • ConvertToUpper.gif
        • Copy.gif
        • Cut.gif
        • Delete.gif
        • Delete2.gif
        • Font.gif
        • FontSize.gif
        • ForeColor.gif
        • FormatCodeBlock.gif
        • ImageMapDialog.gif
        • Indent.gif
        • InsertDate.gif
        • InsertHorizontalRule.gif
        • InsertOrderedList.gif
        • InsertSymbol.gif
        • InsertTable.gif
        • InsertTime.gif
        • InsertUnorderedList.gif
        • Italic.gif
        • JustifyCenter.gif
        • JustifyFull.gif
        • JustifyLeft.gif
        • JustifyRight.gif
        • LinkManager.gif
        • Outdent.gif
        • Paste.gif
        • Print.gif
        • Redo.gif
        • RemoveFormat.gif
        • SelectAll.gif
        • StrikeThrough.gif
        • Subscript.gif
        • Superscript.gif
        • Thumbs.db
        • toolbarstart.gif
        • Underline.gif
        • Undo.gif
        • zoomInIcon.gif
        • zoomOutIcon.gif
      • EditorScript.js
      • EditorStyle.css
      • imgWindow.php
      • InsertLink.htm
      • InsertTable.htm
      • NEditor.php
      • SpecialChars.htm
      • uploadsDir
        • imagefiles
          • ball.gif
          • dog.jpg
          • dolphin.jpg
          • eye.jpg
          • image004.jpg
          • image009.jpg
          • mob1.jpg
          • Thumbs.db
          • WATERsky.jpg
  • editorcs.zip
    • EditorCS
      • Default.aspx
      • Default.aspx.cs
      • editorimages
        • BackColor.gif
        • Bold.gif
        • ButtonDesign.gif
        • ButtonHtml.gif
        • ButtonPreview.gif
        • close.gif
        • ConvertToLower.gif
        • ConvertToUpper.gif
        • Copy.gif
        • Cut.gif
        • Delete.gif
        • Delete2.gif
        • Font.gif
        • FontSize.gif
        • ForeColor.gif
        • FormatCodeBlock.gif
        • ImageMapDialog.gif
        • Indent.gif
        • InsertDate.gif
        • InsertHorizontalRule.gif
        • InsertOrderedList.gif
        • InsertSymbol.gif
        • InsertTable.gif
        • InsertTime.gif
        • InsertUnorderedList.gif
        • Italic.gif
        • JustifyCenter.gif
        • JustifyFull.gif
        • JustifyLeft.gif
        • JustifyRight.gif
        • LinkManager.gif
        • Outdent.gif
        • Paste.gif
        • Print.gif
        • Redo.gif
        • RemoveFormat.gif
        • SelectAll.gif
        • StrikeThrough.gif
        • Subscript.gif
        • Superscript.gif
        • Thumbs.db
        • toolbarstart.gif
        • Underline.gif
        • Undo.gif
        • zoomInIcon.gif
        • zoomOutIcon.gif
      • EditorScript.js
      • EditorStyle.css
      • imgWindow.aspx
      • imgWindow.aspx.cs
      • InsertLink.htm
      • InsertTable.htm
      • NEditor.ascx
      • NEditor.ascx.cs
      • SpecialChars.htm
      • uploadsDir
        • imagefiles
          • ball.gif
          • dog.jpg
          • dolphin.jpg
          • eye.jpg
          • image004.jpg
          • image009.jpg
          • mob1.jpg
          • Thumbs.db
          • WATERsky.jpg
  • editor_php.zip
    • editor_php
      • default.php
      • editorimages
        • BackColor.gif
        • Bold.gif
        • ButtonDesign.gif
        • ButtonHtml.gif
        • ButtonPreview.gif
        • close.gif
        • ConvertToLower.gif
        • ConvertToUpper.gif
        • Copy.gif
        • Cut.gif
        • Delete.gif
        • Delete2.gif
        • Font.gif
        • FontSize.gif
        • ForeColor.gif
        • ImageMapDialog.gif
        • Indent.gif
        • InsertDate.gif
        • InsertFlash.gif
        • InsertFormButton.gif
        • InsertFormCheckbox.gif
        • InsertFormFileUpload.gif
        • InsertFormForm.gif
        • InsertFormHidden.gif
        • InsertFormPassword.gif
        • InsertFormRadio.gif
        • InsertFormReset.gif
        • InsertFormSelect.gif
        • InsertFormSelect2.gif
        • InsertFormSubmit.gif
        • InsertFormText.gif
        • InsertFormTextarea.gif
        • InsertHorizontalRule.gif
        • InsertMedia.gif
        • InsertOrderedList.gif
        • InsertSymbol.gif
        • InsertTable.gif
        • InsertTemplate.gif
        • InsertTime.gif
        • InsertUnorderedList.gif
        • Italic.gif
        • JustifyCenter.gif
        • JustifyFull.gif
        • JustifyLeft.gif
        • JustifyRight.gif
        • LinkManager.gif
        • Outdent.gif
        • Paste.gif
        • Print.gif
        • Redo.gif
        • RemoveFormat.gif
        • Save.gif
        • SaveLocal.gif
        • SelectAll.gif
        • StrikeThrough.gif
        • Subscript.gif
        • Superscript.gif
        • Thumbs.db
        • toolbarstart.gif
        • Underline.gif
        • Undo.gif
        • zoomInIcon.gif
        • zoomOutIcon.gif
      • EditorScripts.js
      • EditorStyle.css
      • flashWindow.php
      • imgWindow.php
      • InsertLinks.htm
      • InsertTable.htm
      • mediaWindow.php
      • NEditor.php
      • saveWindow.php
      • SpecialChars.htm
      • templateWindow.php
      • uploadsDir
        • flashfiles
        • imagefiles
          • Thumbs.db
        • mediafiles
          • Thumbs.db
        • templatefiles
  • editor_vb.net.zip
  • Editor.zip
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>Insert Special Characters</title>
    <link href="EditorStyle.css" rel="stylesheet" type="text/css" />

    <script language="javascript">

		var sChars = ["&quot;","&amp;","&lt;","&gt;","&euro;","&Aacute;","&aacute;","&Acirc;","&acirc;","&acute;","&AElig;","&aelig;","&Agrave;","&agrave;","&Aring;","&aring;","&Atilde;","&atilde;","&Auml;","&auml;","&brvbar;","&Ccedil;","&ccedil;","&cedil;","&cent;","&circ;","&copy;","&curren;","&deg;","&divide;","&Eacute;","&eacute;","&Ecirc;","&ecirc;","&Egrave;","&egrave;","&ETH;","&eth;","&Euml;","&euml;","&fnof;","&frac12;","&frac14;","&frac34;","&Iacute;","&iacute;","&Icirc;","&icirc;","&iexcl;","&Igrave;","&igrave;","&iquest;","&Iuml;","&iuml;","&laquo;","&macr;","&micro;","&middot;","&not;","&Ntilde;","&ntilde;","&Oacute;","&oacute;","&Ocirc;","&ocirc;","&OElig;","&oelig;","&Ograve;","&ograve;","&ordf;","&ordm;","&Oslash;","&oslash;","&Otilde;","&otilde;","&Ouml;","&ouml;","&para;","&plusmn;","&pound;","&raquo;","&reg;","&Scaron;","&scaron;","&sect;","&sup1;","&sup2;","&sup3;","&szlig;","&THORN;","&thorn;","&tilde;","&times;","&Uacute;","&uacute;","&Ucirc;","&ucirc;","&Ugrave;","&ugrave;",
					"&uml;","&Uuml;","&uuml;","&Yacute;","&yacute;","&yen;","&Yuml;","&yuml;","&zwnj;","&zwj;","&ndash;","&mdash;","&lsquo;","&rsquo;","&sbquo;","&ldquo;","&rdquo;","&bdquo;","&lsaquo;","&rsaquo;","&dagger;","&Dagger;","&permil;","&bull;","&hellip;","&Prime;","&prime;","&oline;","&frasl;","&trade;","&part;","&prod;","&sum;","&minus;","&radic;","&infin;","&int;","&asymp;","&ne;","&equiv;","&le;","&ge;","&loz;","&spades;","&clubs;","&hearts;","&diams;","&Alpha;","&alpha;","&Beta;","&beta;","&Gamma;","&gamma;","&Delta;","&delta;","&Epsilon;","&epsilon;","&Zeta;","&zeta;","&Eta;","&eta;","&Theta;","&theta;","&Iota;","&iota;","&Kappa;","&kappa;","&Lambda;","&lambda;","&Mu;","&mu;","&Nu;","&nu;","&Xi;","&xi;","&Omicron;","&omicron;","&Pi;","&pi;","&piv;","&Rho;","&rho;","&Sigma;","&sigma;","&sigmaf;","&Tau;","&tau;","&Upsilon;","&upsilon;","&upsih;","&Phi;","&phi;","&Chi;","&chi;","&Psi;","&psi;","&Omega;","&omega;"];
        function setTable()
		{
			var cols = 15 ;
			var tableStr = "<table cellpadding='1' cellspacing='1' align='center' border='0' width='100%' height='100%'>";
			var i = 0 ;
			while (i < sChars.length)
			{
				tableStr += "<TR>" ;
				for(var j = 0 ; j < cols ; j++)
				{
					if (sChars[i])
					{
						tableStr +=  '<TD width="2%" class="scstyle" align="center" onclick="insertChar()" onmouseover="over(this)">';
						tableStr += sChars[i];
					}
					else
						tableStr += "<TD>&nbsp;" ;
					tableStr += "</TD>";
					i++ ;
				}
				tableStr += "</TR>";
			}
			tableStr += "</table>";
			document.getElementById("sclisttd").innerHTML = tableStr;
		}

		function insertChar()
		{
            returnValue = event.srcElement.innerHTML;
            window.close();
		}
		
		function over(td)
		{
			document.getElementById("scSample").innerHTML = td.innerHTML;
		}
    </script>

</head>
<body onload="setTable()" topmargin="0" bottommargin="0" rightmargin="0" leftmargin="0"
    class='txtStyle' bgcolor='#fffcd1'>
    <form name="form1">
    <table align="Center" cellpadding="2" cellspacing="2">
        <tr>
            <td colspan="2" align="center">
                INSERT SPECIAL CHARACTERS
            </td>
        </tr>
        <tr>
            <td colspan="2" height="10">&nbsp;
                
            </td>
        </tr>
        <tr>
            <td align="center" id="sclisttd">
            </td>
            <td align="center" valign="top">
                <div id="scSample" class="scsamplestyle">
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="2" align="right">
                <button id="btnCancel" class="buttonStyle2" onclick="window.close()">
                    Cancel</button>
            </td>
        </tr>
    </table>
    </form>
</body>
</html>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
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