annotate index.html @ 6:a696cc8f1ee1

Enforce basic paths
author nanaya <me@myconan.net>
date Tue, 24 Nov 2015 20:29:50 +0900
parents 3be5d1679ce0
children c1086c23ef29
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
1 <!doctype html>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
2 <head>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
3 <title>Kalkulator</title>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
4 <meta name="viewport" content="width=device-width">
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
5 <meta http-equiv="Content-Type" content="text/html;charset=utf-8">
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
6 <style type="text/css">
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
7 body {
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
8 font-size: 12px;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
9 font-family: Helvetica Neue, Helvetica, Arial, sans-serif;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
10 line-height: 1.5;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
11 margin: 0px;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
12 background-color: #eee;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
13 }
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
14 #content {
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
15 width: 100%;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
16 min-height: 100vh;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
17 padding: 10px;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
18 margin: auto;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
19 background-color: #fff;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
20 }
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
21 @media (min-width: 600px) {
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
22 #content {
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
23 width: 500px;
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
24 }
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
25 }
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
26 * { box-sizing: border-box; }
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
27 ul { padding-left: 20px; }
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
28 #n, .js { display: none; }
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
29 input, button, select, option, .js { font-size: 150%; }
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
30 </style>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
31 </head>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
32 <body>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
33 <div id="content">
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
34 <h1>Konversi buat nitip</h1>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
35 <form>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
36 <p>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
37 <label for="x">Jumlah dalam yen:</label>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
38 <br>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
39 <input id="x" name="x" type="number" autofocus>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
40 </p>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
41 <p>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
42 <button type="submit">Hitung</button>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
43 <button type="reset">Hapus</button>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
44 </p>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
45 </form>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
46 <div class="js" id="loading">
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
47 <p>Memuat data nilai tukar...</p>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
48 </div>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
49 <div class="js" id="ok">
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
50 <p>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
51 Biaya:
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
52 </p>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
53 <ul>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
54 <li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
55 Bank transfer:
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
56 <span id="result-bank"></span> IDR
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
57 (<span id="rate-text"></span> IDR/JPY)
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
58 </li>
4
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
59
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
60 <li>
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
61 Bank transfer (alt):
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
62 <span id="result-bank-bni"></span> IDR
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
63 (<span id="rate-text-bni"></span> IDR/JPY)
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
64 </li>
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
65
0
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
66 <li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
67 PayPal:
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
68 <span id="result-paypal"></span> JPY
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
69 </li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
70 </ul>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
71 </div>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
72 <div class="js" id="error">
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
73 <p>Koneksi ke server nilai tukar bermasalah.</p>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
74 </div>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
75
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
76 <hr>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
77 <ul>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
78 <li>Ongkir, cukai, dll tidak termasuk.</li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
79 <li>Berhubung sudah punya timbangan, ongkir (estimasi) bisa dihitung sebelum dikirim.</li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
80 <li><a href="http://www.post.japanpost.jp/int/charge/list/ems1_en.html">Tabel ongkir EMS</a>.</li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
81 <li>Perhitungan:
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
82 <ul>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
83 <li>Bank: <code>jumlah &times; 1.07 &times; nilai_tukar</code>, dibulatkan ke seribuan terdekat.</li>
4
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
84 <li>Bank (alt): <code>jumlah &times; 1.01 &times; nilai_tukar + 25000</code>, dibulatkan ke seribuan terdekat.</li>
0
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
85 <li>PayPal: <code>jumlah &times; 1.05</code>, dibulatkan ke satuan terdekat.</li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
86 </ul>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
87 </li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
88 <li>Jangan lupa memastikan jumlah setelah pajak dan ongkir (lokal).</li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
89 <li>Data nilai tukar didapat dari layanan <a href="http://fixer.io/">Fixer.io</a>.</li>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
90 </ul>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
91 </div>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
92
2
9e5f60aae01c Update jquery version.
nanaya <me@myconan.net>
parents: 1
diff changeset
93 <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
0
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
94 <script>
4
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
95 var input = function() { return parseFloat($xForm.val()); }
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
96
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
97 var $loading = $("#loading");
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
98 var $doButton = $("button[type=submit]");
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
99 var $xForm = $("#x");
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
100
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
101 var locks = {};
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
102 var lock = function(isLoading) {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
103 if (!isLoading && locks.fixer === true && locks.bni === true) { return; }
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
104 $loading.toggle(isLoading);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
105 $doButton.attr("disabled", isLoading);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
106 };
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
107
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
108 var rates = {};
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
109
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
110 var displayResult = function() {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
111 if (rates.fixer === undefined || rates.bni === undefined) { return; }
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
112 var x = input();
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
113
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
114 $("#rate-text").text(rates.fixer.toLocaleString());
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
115 $("#result-bank").text((Math.round(x * 1.07 * rates.fixer / 1000) * 1000).toLocaleString());
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
116
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
117 if (rates.bni !== 0) {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
118 $("#rate-text-bni").text(rates.bni.toLocaleString());
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
119 $("#result-bank-bni").text((Math.ceil(x * 1.01 * rates.bni / 1000) * 1000 + 25000).toLocaleString());
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
120 } else {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
121 $("#rate-text-bni").text('x');
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
122 $("#result-bank-bni").text('x');
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
123 };
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
124
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
125 $("#result-paypal").text((Math.round(x * 1.05)).toLocaleString());
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
126 $("#ok").show();
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
127 lock(false);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
128 };
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
129
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
130 var action = function(e) {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
131 e.preventDefault()
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
132 $(".js").hide()
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
133
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
134 var x = input();
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
135
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
136 if (x === NaN || x === undefined) { return false; };
0
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
137
4
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
138 if (rates.fixer === undefined) {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
139 lock(true);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
140 locks.fixer = true;
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
141
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
142 $.getJSON("https://api.fixer.io/latest", { base: "JPY", symbols: "IDR" })
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
143 .done(function(data) {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
144 rates.fixer = parseFloat(data.rates["IDR"]);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
145
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
146 displayResult();
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
147 })
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
148 .fail(function() {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
149 $("#error").show();
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
150 })
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
151 .always(function() {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
152 locks.fixer = false;
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
153 lock(false);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
154 });
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
155 };
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
156
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
157 if (rates.bni === undefined) {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
158 lock(true);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
159 locks.bni = true;
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
160
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
161 $.get("bni-jpyidr.txt")
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
162 .done(function(data) {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
163 if (data === "") {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
164 rates.bni = 0;
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
165 } else {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
166 rates.bni = parseFloat(data);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
167 }
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
168
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
169 displayResult();
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
170 })
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
171 .fail(function() {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
172 $("#error").show();
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
173 })
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
174 .always(function() {
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
175 locks.bni = false;
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
176 lock(false);
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
177 });
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
178 };
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
179
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
180 displayResult();
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
181 };
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
182
0
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
183 $("form").submit(action)
4
3be5d1679ce0 Add bni, rewrite javascript
nanaya <me@myconan.net>
parents: 2
diff changeset
184 $("button[type=reset]").click(function(e) { xForm.focus(); });
0
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
185 </script>
3c9ac4a429a5 Initial import.
nanaya <me@myconan.net>
parents:
diff changeset
186 </body>