summaryrefslogtreecommitdiffstats
path: root/opennhrp-editinterface-html.lsp
blob: 25b1a0f9a06025c661b1e3728815708fddd32cb1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<% local form, viewlibrary, page_info, session = ...
htmlviewfunctions = require("htmlviewfunctions")
html = require("acf.html")
%>

<script type="text/javascript">
        if (typeof jQuery == 'undefined') {
                document.write('<script type="text/javascript" src="<%= html.html_escape(page_info.wwwprefix) %>/js/jquery-latest.js"><\/script>');
	}
</script>

<script type="text/javascript">
	function enabledisable(){
		if ($("#type").val() == "NHRP Enabled") {
			$("#map").parents(".item").show();
			$("#dynamic-map").parents(".item").show();
		} else {
			$("#map").parents(".item").hide();
			$("#dynamic-map").parents(".item").hide();
		}
	}
	$(function(){
		$("#type").change(enabledisable);
		enabledisable();
	});
</script>

<% htmlviewfunctions.displayitem(form, page_info) %>