Albirew/nyaa-pantsu
Archivé
1
0
Bifurcation 0

Fixes block templates for title and rss (#1068)

* Fixes block templates for title and rss

* Remove duplicate og site_name
* add rss links in meta for torznab and eztv
* Fixed 404 Error in og site_name

* Git didn't update the view fast enough
Cette révision appartient à :
akuma06 2017-06-25 01:54:33 +02:00 révisé par GitHub
Parent 4f203ba92c
révision d4b36e2489
2 fichiers modifiés avec 4 ajouts et 2 suppressions

Voir le fichier

@ -13,13 +13,14 @@
<link rel="shortcut icon" type="image/png" href="/img/favicon.png">
<!-- SMO -->
<meta property="og:site_name" content="Nyaa Pantsu">
<meta property="og:site_name" content="{{if Sukebei}}Sukebei{{else}}Nyaa{{end}} Pantsu - {{template "title" .}}{{ call $.T "error_404" }}">
<meta property="og:site_name" content="{{if Sukebei}}Sukebei{{else}}Nyaa{{end}} Pantsu - {{template "title" .}}">
<meta property="og:image" content="/img/favicon.png">
<meta property="og:description" content="Nyaa Pantsu Homepage">
<!-- RSS Feed with Context -->
<link rel="alternate" type="application/rss+xml" title="Nyaa Pantsu - {{block "rsstitle" .}}Last torrents{{end}} RSS Feed" href="{{ block "rss_link" . }}{{ genRouteWithQuery "feed" .URL }}{{end}}" />
<link rel="alternate" type="application/rss+xml" title="Nyaa Pantsu - {{ template "rsstitle"}} Torznab RSS Feed" href="{{ genRouteWithQuery "feed_torznab" .URL }}&t=search" />
<link rel="alternate" type="application/rss+xml" title="Nyaa Pantsu - {{ template "rsstitle"}} EZTV RSS Feed" href="{{ genRouteWithQuery "feed_eztv" .URL }}" />
<!-- do NOT move -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/simplemde/latest/simplemde.min.css">

Voir le fichier

@ -1,6 +1,7 @@
{{define "title"}}{{ call $.T "profile_page" .UserProfile.Username }}{{end}}
{{define "contclass"}}cont-view{{end}}
{{define "rss_link"}}{{ genRoute "feed_user" "id" ( print .UserProfile.ID ) "username" .UserProfile.Username }}{{end}}
{{define "rss_moreparam"}}&userID={{print .UserProfile.ID}}{{end}}
{{define "rsstitle" }}{{ .UserProfile.Username }}{{end}}
{{define "content"}}
{{ range (index $.FormInfos "infos")}}