File tree 2 files changed +18
-2
lines changed
2 files changed +18
-2
lines changed Original file line number Diff line number Diff line change 42
42
<link rel="stylesheet" href="<?php echo site_url () ?> system/resources/css/jquery-ui.css">
43
43
<script>
44
44
$( function() {
45
+ // Decode HTML entities
46
+ function decodeHtml(html) {
47
+ var txt = document.createElement("textarea");
48
+ txt.innerHTML = html;
49
+ return txt.value;
50
+ }
51
+
45
52
var availableTags = [
46
53
<?php foreach ($ tags as $ tag => $ count ):?>
47
54
"<?php echo tag_i18n ($ tag ) ?> ",
48
55
<?php endforeach ;?>
49
- ];
56
+ ].map(decodeHtml); // Decoding all tags
57
+
50
58
function split( val ) {
51
59
return val.split( /,\s*/ );
52
60
}
Original file line number Diff line number Diff line change 88
88
<link rel="stylesheet" href="<?php echo site_url () ?> system/resources/css/jquery-ui.css">
89
89
<script>
90
90
$( function() {
91
+ // Decode HTML entities
92
+ function decodeHtml(html) {
93
+ var txt = document.createElement("textarea");
94
+ txt.innerHTML = html;
95
+ return txt.value;
96
+ }
97
+
91
98
var availableTags = [
92
99
<?php foreach ($ tags as $ tag => $ count ):?>
93
100
"<?php echo tag_i18n ($ tag ) ?> ",
94
101
<?php endforeach ;?>
95
- ];
102
+ ].map(decodeHtml); // Decoding all tags
103
+
96
104
function split( val ) {
97
105
return val.split( /,\s*/ );
98
106
}
You can’t perform that action at this time.
0 commit comments