| 1 |
<!DOCTYPE html> |
| 2 |
<html> |
| 3 |
<head> |
| 4 |
<title>JSXGraph example</title> |
| 5 |
|
| 6 |
<!-- Adjust the paths --> |
| 7 |
|
| 8 |
<!-- JSXGraph --> |
| 9 |
<link rel="stylesheet" type="text/css" href="../../distrib/jsxgraph.css" /> |
| 10 |
<link rel="stylesheet" type="text/css" href="css/jsxexamples.css" /> |
| 11 |
<script type="text/javascript" src="../../distrib/jsxgraphcore.js"></script> |
| 12 |
|
| 13 |
<!-- jQuery --> |
| 14 |
<script type="text/javascript" src="../jquery-3.5.1.min.js"></script> |
| 15 |
|
| 16 |
<!-- Syntax Highlighting --> |
| 17 |
<link rel="stylesheet" type="text/css" href="css/shCore.css" /> |
| 18 |
<link rel="stylesheet" type="text/css" href="css/shThemeDefault.css" /> |
| 19 |
<script type="text/javascript" src="js/shCore.js"></script> |
| 20 |
<script type="text/javascript" src="js/shBrushJScript.js"></script> |
| 21 |
</head> |
| 22 |
<body> |
| 23 |
|
| 24 |
<!-- powered by <a href="http://jsxgraph.org/">JSXGraph</a>.--> |
| 25 |
|
| 26 |
<div id="container"> |
| 27 |
|
| 28 |
<span id="jsxgraph-head">powered by <a href="http://jsxgraph.org/"><img src="img/jsxgraph_badge_39.png" alt="JSXGraph" /></a></span> |
| 29 |
|
| 30 |
<h1>Enter title here</h1> |
| 31 |
|
| 32 |
|
| 33 |
<a name="construction"></a> |
| 34 |
<h2><a href="#construction" id="head-construction">Construction</a></h2> |
| 35 |
|
| 36 |
<div id="construction"> |
| 37 |
<div id="jxgbox" class="jxgbox" style="width: 600px; height: 600px;"></div> |
| 38 |
</div> |
| 39 |
|
| 40 |
<script id="jxg" type="text/javascript"> |
| 41 |
(function() { |
| 42 |
|
| 43 |
var board = JXG.JSXGraph.initBoard('jxgbox', { |
| 44 |
boundingbox: [-5, 5, 5, -5], |
| 45 |
keepaspectreatio: true, |
| 46 |
axis:true, |
| 47 |
grid: true |
| 48 |
}); |
| 49 |
|
| 50 |
// construction |
| 51 |
|
| 52 |
})(); |
| 53 |
</script> |
| 54 |
|
| 55 |
|
| 56 |
<a name="explanation"></a> |
| 57 |
<h2><a href="#explanation" id="head-explanation">Explanation</a></h2> |
| 58 |
|
| 59 |
<div id="explanation"> |
| 60 |
Explanation goes here. |
| 61 |
</div> |
| 62 |
|
| 63 |
|
| 64 |
<a name="source"></a> |
| 65 |
<h2><a href="#source" id="head-source">Source code</a></h2> |
| 66 |
|
| 67 |
<div id="source"> |
| 68 |
<script id="jxgsource" type="syntaxhighlighter" class="brush: js"></script> |
| 69 |
</div> |
| 70 |
|
| 71 |
<div id="footer"> |
| 72 |
<span style="float: left"><img src="img/jsxgraph_logo_20.png" alt="JSXGraph logo" /></span> |
| 73 |
JSXGraph is licensed under the <a href="http://www.gnu.org/licenses/lgpl.txt">LGPL</a>; © 2008-2010 <a href="http://jsxgraph.uni-bayreuth.de/wp/documentation/the-team/">JSXGraph Team</a> |
| 74 |
</div> |
| 75 |
|
| 76 |
</div> <!-- #container --> |
| 77 |
|
| 78 |
|
| 79 |
<script type="text/javascript"> |
| 80 |
// <![CDATA[ |
| 81 |
|
| 82 |
$(document).ready(function() { |
| 83 |
var parts = { |
| 84 |
construction: 'show', |
| 85 |
source: 'hide', |
| 86 |
explanation: 'hide' |
| 87 |
}, |
| 88 |
part; |
| 89 |
|
| 90 |
$('#jxgsource').text($('#jxg').text()); |
| 91 |
SyntaxHighlighter.all(); |
| 92 |
|
| 93 |
for(part in parts) { |
| 94 |
$('#' + part)[parts[part]](); |
| 95 |
|
| 96 |
$('#head-'+part).click(function(_part) { |
| 97 |
return function() { |
| 98 |
$('#'+_part).slideToggle(500); |
| 99 |
} |
| 100 |
}(part)); |
| 101 |
} |
| 102 |
}); |
| 103 |
|
| 104 |
// ]]> |
| 105 |
</script> |
| 106 |
</body> |
| 107 |
</html> |