Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

use html function

  • Loading branch information...
commit 03d7b863f982447a775cd46792857433143d5bbe 1 parent 4cdcc35
Steven Gravell authored
Showing with 2 additions and 4 deletions.
  1. +2 −4 priv/js/tpl.js
View
6 priv/js/tpl.js
@@ -59,9 +59,8 @@ var TPL = (function() {
el.data(k, v);
var child = $("."+k, el);
if(child.length > 0 && v) {
- child.children().remove();
try {
- child.append(v);
+ child.html(v);
} catch(err) {
}
}
@@ -150,9 +149,8 @@ var TPL = (function() {
var jt = type(data);
if(jt == "string") {
- el.children().remove();
try {
- el.append(data);
+ el.html(data);
} catch(err) {
}
} else if(jt == "object") {
Please sign in to comment.
Something went wrong with that request. Please try again.