commit | author | age
|
c5042d
|
1 |
|
T |
2 |
function toggleblock(id, link) |
|
3 |
{ |
|
4 |
var block = document.getElementById(id); |
|
5 |
|
|
6 |
return false; |
|
7 |
} |
|
8 |
|
|
9 |
|
|
10 |
function addhostfield() |
|
11 |
{ |
|
12 |
var container = document.getElementById('defaulthostlist'); |
|
13 |
var row = document.createElement('div'); |
|
14 |
var input = document.createElement('input'); |
|
15 |
var link = document.createElement('a'); |
|
16 |
|
|
17 |
input.name = '_default_host[]'; |
|
18 |
input.size = '30'; |
|
19 |
link.href = '#'; |
|
20 |
link.onclick = function() { removehostfield(this.parentNode); return false }; |
|
21 |
link.className = 'removelink'; |
|
22 |
link.innerHTML = 'remove'; |
|
23 |
|
|
24 |
row.appendChild(input); |
|
25 |
row.appendChild(link); |
|
26 |
container.appendChild(row); |
|
27 |
} |
|
28 |
|
|
29 |
|
|
30 |
function removehostfield(row) |
|
31 |
{ |
|
32 |
var container = document.getElementById('defaulthostlist'); |
|
33 |
container.removeChild(row); |
|
34 |
} |
|
35 |
|
|
36 |
|