Refactor method names/views for Articles
This commit is contained in:
parent
a3d1fec56d
commit
e320bec899
5 changed files with 7 additions and 7 deletions
27
resources/views/articles/rss.blade.php
Normal file
27
resources/views/articles/rss.blade.php
Normal file
|
@ -0,0 +1,27 @@
|
|||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
|
||||
<channel>
|
||||
<title>{{ env('DISPLAY_NAME') }}</title>
|
||||
<atom:link href="{{ config('app.url') }}/feed" rel="self" type="application/rss+xml" />
|
||||
<description>An RSS feed of the blog posts found on {{ config('url.longurl') }}</description>
|
||||
<link>{{ config('app.url') }}</link>
|
||||
<lastBuildDate>{{ $buildDate }}</lastBuildDate>
|
||||
<ttl>1800</ttl>
|
||||
|
||||
@foreach($articles as $article)
|
||||
<item>
|
||||
<title>{{ strip_tags($article->title) }}</title>
|
||||
<description>
|
||||
<![CDATA[
|
||||
{{ $article->main }}
|
||||
@if($article->url)<p><a href="{{ config('app.url') }}{{ $article->link }}">Permalink</a></p>@endif
|
||||
]]>
|
||||
</description>
|
||||
<link>@if($article->url != ''){{ $article->url }}@else{{ config('app.url') }}{{ $article->link }}@endif</link>
|
||||
<guid>{{ config('app.url') }}{{ $article->link }}</guid>
|
||||
<pubDate>{{ $article->pubdate }}</pubDate>
|
||||
</item>
|
||||
@endforeach
|
||||
|
||||
</channel>
|
||||
</rss>
|
Loading…
Add table
Add a link
Reference in a new issue