projects
/
misc
/
kostenrechnung
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ca0b80c
)
Support setting values to arbitrary objects using innerHTML
author
Joey Schulze
<joey@infodrom.org>
Thu, 4 Mar 2010 22:51:48 +0000
(23:51 +0100)
committer
Joey Schulze
<joey@infodrom.org>
Thu, 4 Mar 2010 22:51:48 +0000
(23:51 +0100)
lib/functions.js
patch
|
blob
|
history
diff --git
a/lib/functions.js
b/lib/functions.js
index
f1b6d4d
..
de69409
100644
(file)
--- a/
lib/functions.js
+++ b/
lib/functions.js
@@
-66,10
+66,12
@@
function set_value(id, value)
obj.value = value;
else if (obj.nodeName.toLowerCase() == 'span')
obj.innerHTML = value;
- else if (obj.nodeName.toLowerCase() == 'select')
+ else if (obj.nodeName.toLowerCase() == 'select')
{
for (var i=0; i < obj.options.length; i++)
if (obj.options[i].value == value)
obj.selectedIndex = i;
+ } else
+ obj.innerHTML = value;
}
function setvar(obj, name, callback, status)