Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../httpdocs/wp-conte.../plugins/wp-file-.../lib/codemirr.../mode/javascri...
File: index.html
<!doctype html>
[0] Fix | Delete
[1] Fix | Delete
<title>CodeMirror: JavaScript mode</title>
[2] Fix | Delete
<meta charset="utf-8"/>
[3] Fix | Delete
<link rel=stylesheet href="../../doc/docs.css">
[4] Fix | Delete
[5] Fix | Delete
<link rel="stylesheet" href="../../lib/codemirror.css">
[6] Fix | Delete
<script src="../../lib/codemirror.js"></script>
[7] Fix | Delete
<script src="../../addon/edit/matchbrackets.js"></script>
[8] Fix | Delete
<script src="../../addon/comment/continuecomment.js"></script>
[9] Fix | Delete
<script src="../../addon/comment/comment.js"></script>
[10] Fix | Delete
<script src="javascript.js"></script>
[11] Fix | Delete
<style type="text/css">.CodeMirror {border-top: 1px solid black; border-bottom: 1px solid black;}</style>
[12] Fix | Delete
<div id=nav>
[13] Fix | Delete
<a href="http://codemirror.net"><h1>CodeMirror</h1><img id=logo src="../../doc/logo.png"></a>
[14] Fix | Delete
[15] Fix | Delete
<ul>
[16] Fix | Delete
<li><a href="../../index.html">Home</a>
[17] Fix | Delete
<li><a href="../../doc/manual.html">Manual</a>
[18] Fix | Delete
<li><a href="https://github.com/codemirror/codemirror">Code</a>
[19] Fix | Delete
</ul>
[20] Fix | Delete
<ul>
[21] Fix | Delete
<li><a href="../index.html">Language modes</a>
[22] Fix | Delete
<li><a class=active href="#">JavaScript</a>
[23] Fix | Delete
</ul>
[24] Fix | Delete
</div>
[25] Fix | Delete
[26] Fix | Delete
<article>
[27] Fix | Delete
<h2>JavaScript mode</h2>
[28] Fix | Delete
[29] Fix | Delete
[30] Fix | Delete
<div><textarea id="code" name="code">
[31] Fix | Delete
// Demo code (the actual new parser character stream implementation)
[32] Fix | Delete
[33] Fix | Delete
function StringStream(string) {
[34] Fix | Delete
this.pos = 0;
[35] Fix | Delete
this.string = string;
[36] Fix | Delete
}
[37] Fix | Delete
[38] Fix | Delete
StringStream.prototype = {
[39] Fix | Delete
done: function() {return this.pos >= this.string.length;},
[40] Fix | Delete
peek: function() {return this.string.charAt(this.pos);},
[41] Fix | Delete
next: function() {
[42] Fix | Delete
if (this.pos &lt; this.string.length)
[43] Fix | Delete
return this.string.charAt(this.pos++);
[44] Fix | Delete
},
[45] Fix | Delete
eat: function(match) {
[46] Fix | Delete
var ch = this.string.charAt(this.pos);
[47] Fix | Delete
if (typeof match == "string") var ok = ch == match;
[48] Fix | Delete
else var ok = ch &amp;&amp; match.test ? match.test(ch) : match(ch);
[49] Fix | Delete
if (ok) {this.pos++; return ch;}
[50] Fix | Delete
},
[51] Fix | Delete
eatWhile: function(match) {
[52] Fix | Delete
var start = this.pos;
[53] Fix | Delete
while (this.eat(match));
[54] Fix | Delete
if (this.pos > start) return this.string.slice(start, this.pos);
[55] Fix | Delete
},
[56] Fix | Delete
backUp: function(n) {this.pos -= n;},
[57] Fix | Delete
column: function() {return this.pos;},
[58] Fix | Delete
eatSpace: function() {
[59] Fix | Delete
var start = this.pos;
[60] Fix | Delete
while (/\s/.test(this.string.charAt(this.pos))) this.pos++;
[61] Fix | Delete
return this.pos - start;
[62] Fix | Delete
},
[63] Fix | Delete
match: function(pattern, consume, caseInsensitive) {
[64] Fix | Delete
if (typeof pattern == "string") {
[65] Fix | Delete
function cased(str) {return caseInsensitive ? str.toLowerCase() : str;}
[66] Fix | Delete
if (cased(this.string).indexOf(cased(pattern), this.pos) == this.pos) {
[67] Fix | Delete
if (consume !== false) this.pos += str.length;
[68] Fix | Delete
return true;
[69] Fix | Delete
}
[70] Fix | Delete
}
[71] Fix | Delete
else {
[72] Fix | Delete
var match = this.string.slice(this.pos).match(pattern);
[73] Fix | Delete
if (match &amp;&amp; consume !== false) this.pos += match[0].length;
[74] Fix | Delete
return match;
[75] Fix | Delete
}
[76] Fix | Delete
}
[77] Fix | Delete
};
[78] Fix | Delete
</textarea></div>
[79] Fix | Delete
[80] Fix | Delete
<script>
[81] Fix | Delete
var editor = CodeMirror.fromTextArea(document.getElementById("code"), {
[82] Fix | Delete
lineNumbers: true,
[83] Fix | Delete
matchBrackets: true,
[84] Fix | Delete
continueComments: "Enter",
[85] Fix | Delete
extraKeys: {"Ctrl-Q": "toggleComment"}
[86] Fix | Delete
});
[87] Fix | Delete
</script>
[88] Fix | Delete
[89] Fix | Delete
<p>
[90] Fix | Delete
JavaScript mode supports several configuration options:
[91] Fix | Delete
<ul>
[92] Fix | Delete
<li><code>json</code> which will set the mode to expect JSON
[93] Fix | Delete
data rather than a JavaScript program.</li>
[94] Fix | Delete
<li><code>jsonld</code> which will set the mode to expect
[95] Fix | Delete
<a href="http://json-ld.org">JSON-LD</a> linked data rather
[96] Fix | Delete
than a JavaScript program (<a href="json-ld.html">demo</a>).</li>
[97] Fix | Delete
<li><code>typescript</code> which will activate additional
[98] Fix | Delete
syntax highlighting and some other things for TypeScript code
[99] Fix | Delete
(<a href="typescript.html">demo</a>).</li>
[100] Fix | Delete
<li><code>statementIndent</code> which (given a number) will
[101] Fix | Delete
determine the amount of indentation to use for statements
[102] Fix | Delete
continued on a new line.</li>
[103] Fix | Delete
<li><code>wordCharacters</code>, a regexp that indicates which
[104] Fix | Delete
characters should be considered part of an identifier.
[105] Fix | Delete
Defaults to <code>/[\w$]/</code>, which does not handle
[106] Fix | Delete
non-ASCII identifiers. Can be set to something more elaborate
[107] Fix | Delete
to improve Unicode support.</li>
[108] Fix | Delete
</ul>
[109] Fix | Delete
</p>
[110] Fix | Delete
[111] Fix | Delete
<p><strong>MIME types defined:</strong> <code>text/javascript</code>, <code>application/json</code>, <code>application/ld+json</code>, <code>text/typescript</code>, <code>application/typescript</code>.</p>
[112] Fix | Delete
</article>
[113] Fix | Delete
[114] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function