Mercurial > laserkard
comparison awesome_js/echo.js @ 51:95fa4bcc5d67 laserkard
[svn r52] implemented SVG backend
author | rlm |
---|---|
date | Wed, 03 Feb 2010 03:14:09 -0500 |
parents | |
children | 375225442677 |
comparison
equal
deleted
inserted
replaced
50:1b5417799713 | 51:95fa4bcc5d67 |
---|---|
1 function js_process_func(input) | |
2 | |
3 { | |
4 | |
5 document.getElementById('perlClick').innerHTML = input; | |
6 | |
7 } | |
8 | |
9 | |
10 | |
11 function parseFile() | |
12 { | |
13 document.getElementById('output').innerHTML = "function called"; | |
14 | |
15 var JSONtext = document.getElementById('textEntry').value; | |
16 | |
17 var hash = new Object(); | |
18 hash = eval('(' + JSONtext + ')'); | |
19 document.getElementById('output').innerHTML = ""; | |
20 document.getElementById('perlClick').innerHTML = ""; | |
21 | |
22 | |
23 for (card in hash) | |
24 { | |
25 document.getElementById('output').innerHTML = card; | |
26 clearAll(); | |
27 lineDraw(eval("hash." + card + ".style"), "ff0000"); | |
28 | |
29 for (prop in eval( "hash." + card + ".fields")) | |
30 { | |
31 | |
32 | |
33 | |
34 contentRedraw(eval("hash." + card + ".style"), prop, eval( "hash." + card + ".fields." + prop)); | |
35 | |
36 document.getElementById('output').innerHTML += "<br>" + eval( "hash." + card + ".fields." + prop); | |
37 | |
38 } | |
39 | |
40 for (var ii = 1; ii <= eval("hash." + card + ".number"); ii++) | |
41 { | |
42 | |
43 document.getElementById('perlClick').innerHTML += document.getElementById('disp_contain').innerHTML + "S3ntinEL"; | |
44 //echo(['disp_contain', 'perlClick', num], [js_process_func], 'POST'); | |
45 } | |
46 } | |
47 | |
48 | |
49 var emmm = document.getElementById('sendOff').value; | |
50 | |
51 | |
52 | |
53 echo(['perlClick', "args__" + emmm], ['output'], 'POST'); | |
54 | |
55 | |
56 | |
57 } |