Skip to content

Instantly share code, notes, and snippets.

@fge
Created January 17, 2013 16:05
Show Gist options
  • Select an option

  • Save fge/4557042 to your computer and use it in GitHub Desktop.

Select an option

Save fge/4557042 to your computer and use it in GitHub Desktop.
test page for validation
<!DOCTYPE HTML>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<!-- There is, at present, no official xsd for (X)HTML5. A pity. Usefulness would depend on the parser and extensions made by the site. -->
<title>testcase</title>
<style type="text/css">
* {
margin: 0;
padding: 0;
}
#top {
position: fixed;
width: 100%;
color: black;
height: 95px;
z-index: 2;
padding-left: 5px;
padding-top: 5px;
}
div {
background-color: #fffafa;
}
.content {
padding-top: 100px;
color: black;
position: absolute;
width: 49%;
top: 0;
bottom: 0;
z-index: 1;
padding-left: 1%;
}
#left {
left: 0;
right: 0;
}
#right {
left: 50%;
right: 0;
}
label, textarea, input {
display: block;
}
textarea {
height: 90%;
width: 90%;
}
</style>
</head>
<body>
<div id="top">
<p>Enter your schema in the left text area and the data to validate in the
right text area; then press the "Validate" button.</p>
<p class="intro">This webapp uses the <a
href="https://fge.github.com/json-schema-validator">
json-schema-validator Java library</a>. It is available on <a
href="https://fge.github.com/json-schema-validator">GitHub</a>.
Contributions are welcome.
</p>
</div>
<form action="validate" method="POST">
<div id="left" class="content">
<label for="schema">Schema:</label>
<textarea name="schema" id="schema" rows="20" cols="20"></textarea>
</div>
<div id="right" class="content">
<label for="data">Data:</label>
<textarea name="data" id="data" rows="20" cols="20"></textarea>
<input type="submit" value="Validate">
</div>
</form>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment