Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
415 changes: 383 additions & 32 deletions index.html

Large diffs are not rendered by default.

181 changes: 181 additions & 0 deletions index.html~
Original file line number Diff line number Diff line change
@@ -0,0 +1,181 @@
<!DOCTYPE html>
<html lang="en">
<head>
<title>ACE in Action</title>
<style type="text/css" media="screen">
#editor {
bottom: 0;
left: 0;
margin: 0 auto;
position: absolute;
right: 0;
top: 0;
width: 63%;
height:50%;
font-size: 16px;
margin-left:33%;

}
#submit {
margin-right: 31%;
position:absolute;
bottom:6%;
right: 0;



}

#reset {
margin-right: 40%;
position:absolute;
bottom:6%;
right: 0;
}


body {
background: black none repeat scroll 0 0;
bottom: 0;
left: 0;
position: absolute;
right: 0;
top: 0;
}
#filler{}
#container{bottom: 0;
height: 150%;
left: 0;
position: fixed;
right: 0;
top: 0;
width: 70%;
margin-left:2%;
margin-top:6%;

}
#explanation{
width: 30%;
height: 50%;
margin: 0 auto;
background:white;
margin-bottom:2%;
margin-right:2%;
margin-left:69%;
margin-top:4%;

border-radius: 0px 0px 0px 0px;


}

#instruction{
width: 32%;
height: 50%;
margin: 0 auto;
background:white;
margin-bottom:2%;
margin-right:2%;
margin-left:1%;
filter: blur(strength=50);
border-radius: 0px 0px 0px 0px;

}

#hinstruction{
margin-left: 20%;
}

#houtput{
margin-left: 35%;
}


</style>
</head>
<body>



*****<img src="picture/hack2.png" style="width:200px; height:80px;" align="middle">

<div id="container">

<div id="editor">public function sanitize($user_input) {
$x = htmlspecialchars(trim($user_input));
return "&lt;span title='".$x."'&gt;User input added as span title &lt;/span&gt;";
}

</div>


<div id="instruction"><div id="hinstruction"><strong><font size=5px">Instructions</font><strong></div></div>
</div>

<div id="explanation"><div id="houtput"><strong><font size=5px">Output</font><strong></div></div>

<div id="submit">
<input type="submit" value="Submit" onclick="execute()"
style="background-color:#5B74A8;

border-top: 2px solid #5f6c4d;
border-right: 2px solid #000000;
border-bottom: 2px solid #000000;
border-left: 2px solid #5f6c4d;
width: 90px; height: 30px;
font-size:0.9em;
font-weight: bold;
cursor:pointer;
border-radius: 0px 0px 0px 0px;" />

</div>

<div id="reset">
<a href="index.html" > <input type="reset" value="Reset" onclick="editor/index.html"
style="background-color:#5B74A8;

border-top: 2px solid #5f6c4d;
border-right: 2px solid #000000;
border-bottom: 2px solid #000000;
border-left: 2px solid #5f6c4d;
width: 90px; height: 30px;
font-size:0.9em;
font-weight: bold;
cursor:pointer;
border-radius: 0px 0px 0px 0px;" /></a>


</div>


<script src="ace-builds/src-noconflict/ace.js" type="text/javascript" charset="utf-8"></script>
<script>
var editor = ace.edit("editor");
editor.setTheme("ace/theme/monokai");
editor.getSession().setMode("ace/mode/javascript");
editor.getSession().setUseWrapMode(true);
editor.setHighlightActiveLine(true);
editor.getSession().setTabSize(4);
document.getElementById('editor').style.fontSize='16px';
editor.resize();

function execute() {
var http = new XMLHttpRequest();
var response = '';
http.open("POST", "test.php", true);
http.responseType = "text";
http.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
http.onreadystatechange = function() {
if (http.readyState == 4 && http.status == 200) {
response = http.responseText;
document.getElementById("explanation").innerHTML = response;

}
};
http.send("function="+ editor.getValue());
}

</script>

</body>
</html>
Binary file added picture/bb.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added picture/bbr.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added picture/bl.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added picture/bluecurves.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added picture/gt.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added picture/ind.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added picture/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added picture/tt.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added picture/vf.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.