Merge branch 'dev_aliyun' of http://bdgit.educoder.net/Hjqreturn/educoder into dev_aliyun

dev_forum
cxt 6 years ago
commit 52bf60c247

@ -335,6 +335,7 @@ module ApplicationHelper
end
def to_markdown(text)
Rails.logger.info("#########################text______________tedxt_________________###{text}")
return nil if text.blank?
options = {
:autolink => true,
@ -345,9 +346,11 @@ module ApplicationHelper
:superscript => true,
:tables => true
}
markdown = Redcarpet::Markdown.new(Redcarpet::Render::HTML,options)
markdown.render(text).html_safe
ss = markdown.render(text)
Rails.logger.info("#########################text______________markdown.render(text)________________###{ss}")
ss
end
end

@ -75,10 +75,10 @@
<% q_name = q_markdown_name&.include?("src=\"") ? q_markdown_name&.gsub("src=\"","src=\"#{@request_url}")&.html_safe : q_markdown_name %>
<span class="ques-title" id="ques_marked_<%= index %>"><%= q_name %></span>
<div class="mt8 text-gray">
<span id="ques_title_<%= index %>"><%= q_title %></span>
<span id="ques_title_<%= index %>"><%= q_markdown %></span>
</div>
<% else %>
<span class="ques-title" id="ques_title_<%= index %>"><%= q_title %></span>
<span class="ques-title" id="ques_title_<%= index %>"><%= q_markdown %></span>
<% end %>
</div>
<div class="pbt5">

Loading…
Cancel
Save