aboutsummaryrefslogtreecommitdiff
path: root/imports/codemirror/mode/htmlembedded/index.html
diff options
context:
space:
mode:
authorEric Guzman2012-02-16 00:22:43 -0800
committerEric Guzman2012-02-16 00:22:43 -0800
commit82b1a273219f0ae3d119e156c7acccdbe478f441 (patch)
tree74c45e5e3afc6706b2f7a7918807f72c54cdcfc5 /imports/codemirror/mode/htmlembedded/index.html
parentaf20ca9b11133dd5cefb9275dbe8fb101c3380d0 (diff)
parent966f0adaf1d4b7f2dd5a6e31643df58bff713884 (diff)
downloadninja-82b1a273219f0ae3d119e156c7acccdbe478f441.tar.gz
Merge branch 'refs/heads/TreeComponents' into PresetsPanel
Diffstat (limited to 'imports/codemirror/mode/htmlembedded/index.html')
-rwxr-xr-ximports/codemirror/mode/htmlembedded/index.html49
1 files changed, 49 insertions, 0 deletions
diff --git a/imports/codemirror/mode/htmlembedded/index.html b/imports/codemirror/mode/htmlembedded/index.html
new file mode 100755
index 00000000..c1374e58
--- /dev/null
+++ b/imports/codemirror/mode/htmlembedded/index.html
@@ -0,0 +1,49 @@
1<!doctype html>
2<html>
3 <head>
4 <title>CodeMirror: Html Embedded Scripts mode</title>
5 <link rel="stylesheet" href="../../lib/codemirror.css">
6 <script src="../../lib/codemirror.js"></script>
7 <script src="../xml/xml.js"></script>
8 <script src="../javascript/javascript.js"></script>
9 <script src="../css/css.js"></script>
10 <script src="../htmlmixed/htmlmixed.js"></script>
11 <script src="htmlembedded.js"></script>
12 <style type="text/css">.CodeMirror {border-top: 1px solid black; border-bottom: 1px solid black;}</style>
13 <link rel="stylesheet" href="../../doc/docs.css">
14 </head>
15 <body>
16 <h1>CodeMirror: Html Embedded Scripts mode</h1>
17
18<form><textarea id="code" name="code">
19<%
20function hello(who) {
21 return "Hello " + who;
22}
23%>
24This is an example of EJS (embedded javascript)
25<p>The program says <%= hello("world") %>.</p>
26<script>
27 alert("And here is some normal JS code"); // also colored
28</script>
29</textarea></form>
30
31 <script>
32 var editor = CodeMirror.fromTextArea(document.getElementById("code"), {
33 lineNumbers: true,
34 matchBrackets: true,
35 mode: "application/x-ejs",
36 indentUnit: 4,
37 indentWithTabs: true,
38 enterMode: "keep",
39 tabMode: "shift"
40 });
41 </script>
42
43 <p>Mode for html embedded scripts like JSP and ASP.NET. Depends on HtmlMixed which in turn depends on
44 JavaScript, CSS and XML.<br />Other dependancies include those of the scriping language chosen.</p>
45
46 <p><strong>MIME types defined:</strong> <code>application/x-aspx</code> (ASP.NET),
47 <code>application/x-ejs</code> (Embedded Javascript), <code>application/x-jsp</code> (JavaServer Pages)</p>
48 </body>
49</html>