Commit d22feb1b by Rocky Duan

escape html

parent 70078146
...@@ -26,19 +26,19 @@ ...@@ -26,19 +26,19 @@
</script> </script>
<script type="text/template" id="thread-template"> <script type="text/template" id="thread-template">
<article class="discussion-article" data-id="${'<%= id %>'}"> <article class="discussion-article" data-id="${'<%- id %>'}">
<a href="#" class="dogear"></a> <a href="#" class="dogear"></a>
<div class="discussion-post"> <div class="discussion-post">
<header> <header>
<a href="#" class="vote-btn discussion-vote discussion-vote-up"><span class="plus-icon">+</span> <span class='votes-count-number'>${'<%= votes["up_count"] %>'}</span></a> <a href="#" class="vote-btn discussion-vote discussion-vote-up"><span class="plus-icon">+</span> <span class='votes-count-number'>${'<%- votes["up_count"] %>'}</span></a>
<h1>${'<%= title %>'}</h1> <h1>${'<%- title %>'}</h1>
<p class="posted-details"> <p class="posted-details">
<span class="timeago" title="${'<%= created_at %>'}">sometime</span> by <span class="timeago" title="${'<%- created_at %>'}">sometime</span> by
<a href="${'<%= user_url %>'}">${'<%= username %>'}</a> <a href="${'<%- user_url %>'}">${'<%- username %>'}</a>
</p> </p>
</header> </header>
<div class="post-body"> <div class="post-body">
${'<%= body %>'} ${'<%- body %>'}
</div> </div>
</div> </div>
<ol class="responses"> <ol class="responses">
...@@ -57,11 +57,11 @@ ...@@ -57,11 +57,11 @@
<script type="text/template" id="thread-response-template"> <script type="text/template" id="thread-response-template">
<header> <header>
<a href="#" class="vote-btn" data-tooltip="vote"><span class="plus-icon"></span><span class="votes-count-number">${"<%= votes['up_count'] %>"}</span></a> <a href="#" class="vote-btn" data-tooltip="vote"><span class="plus-icon"></span><span class="votes-count-number">${"<%- votes['up_count'] %>"}</span></a>
<a href="${'<%= user_url %>'}" class="posted-by">${"<%= username %>"}</a> <a href="${'<%- user_url %>'}" class="posted-by">${"<%- username %>"}</a>
<p class="posted-details" title="${'<%= created_at %>'}">Sometime</p> <p class="posted-details" title="${'<%- created_at %>'}">Sometime</p>
</header> </header>
<div class="response-body">${"<%= body %>"}</div> <div class="response-body">${"<%- body %>"}</div>
<ol class="comments"> <ol class="comments">
<li> <li>
<form class="comment-form"> <form class="comment-form">
...@@ -72,9 +72,9 @@ ...@@ -72,9 +72,9 @@
</script> </script>
<script type="text/template" id="response-comment-template"> <script type="text/template" id="response-comment-template">
<p>${'<%= body %>'}<span class="posted-details">posted <span class="timeago" title="${'<%= created_at %>'}">sometime</span> by <a href="${'<%= user_url %>'}">${'<%= username %>'}</a></span></p> <p>${'<%- body %>'}<span class="posted-details">posted <span class="timeago" title="${'<%- created_at %>'}">sometime</span> by <a href="${'<%- user_url %>'}">${'<%- username %>'}</a></span></p>
</script> </script>
<script type="text/template" id="thread-list-item-template"> <script type="text/template" id="thread-list-item-template">
<a href="${'<%= id %>'}" data-id="${'<%= id %>'}"><span class="title">${"<%= title %>"}</span> <span class="comments-count">${"<%= comments_count %>"}</span><span class="votes-count">+${"<%= votes['up_count'] %>"}</span></a> <a href="${'<%- id %>'}" data-id="${'<%- id %>'}"><span class="title">${"<%- title %>"}</span> <span class="comments-count">${"<%- comments_count %>"}</span><span class="votes-count">+${"<%- votes['up_count'] %>"}</span></a>
</script> </script>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment