mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-27 13:47:58 +01:00
use HTML escaping in RSS template, fixes #21
This commit is contained in:
parent
d2ad52da93
commit
4ac63f9f4e
2 changed files with 4 additions and 2 deletions
|
@ -6,6 +6,8 @@ defmodule PhilomenaWeb.Api.Rss.WatchedController do
|
||||||
def index(conn, _params) do
|
def index(conn, _params) do
|
||||||
{:ok, {images, _tags}} = ImageLoader.search_string(conn, "my:watched")
|
{:ok, {images, _tags}} = ImageLoader.search_string(conn, "my:watched")
|
||||||
|
|
||||||
render(conn, "index.rss", images: images)
|
# NB: this is RSS, but using the RSS format causes Phoenix not to
|
||||||
|
# escape HTML
|
||||||
|
render(conn, "index.html", layout: false, images: images)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
|
|
||||||
<%= for image <- @images do %>
|
<%= for image <- @images do %>
|
||||||
<item>
|
<item>
|
||||||
<title><%= "##{image.id} - #{image.tag_list_cache}" %></title>
|
<title>#<%= image.id %> - <%= image.tag_list_cache %></title>
|
||||||
<description>
|
<description>
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
<% mouseovertext = "Size: #{image.image_width}x#{image.image_height} | Tagged: #{image.tag_list_cache}" %>
|
<% mouseovertext = "Size: #{image.image_width}x#{image.image_height} | Tagged: #{image.tag_list_cache}" %>
|
Loading…
Reference in a new issue