Skip to content

Commit

Permalink
Merge pull request #188 from linuxserver/metatags
Browse files Browse the repository at this point in the history
  • Loading branch information
Roxedus authored Nov 23, 2023
2 parents efc975f + b17b716 commit a9d3e62
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
2 changes: 1 addition & 1 deletion config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ params:
# on the footer and meta tags.
#
# Default: We continuously monitor the status of our services and if there are any interruptions, a note will be posted here.
description:
description: LinuxServer.io Status page

# Tabs on homepage
# Uncomment to enable.
Expand Down
18 changes: 18 additions & 0 deletions layouts/partials/custom/meta.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
{{ $url := .Site.BaseURL }}
{{ $u := urls.Parse $url }}

<style>
.pre-header-links {
background-color: #0a0c0f;
Expand All @@ -10,3 +13,18 @@
color: #fff;
}
</style>

<!-- Facebook Meta Tags -->
<meta property="og:url" content="{{ .Permalink }}">
<meta property="og:type" content="website">
<meta property="og:title" content="{{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{.}} | {{ end }}{{ .Site.Title }}{{ end }}">
<meta property="og:description" content="{{ with .Summary }}{{ . }}{{ else }}{{ .Site.Params.description | markdownify | plainify }}{{ end }}">
<meta property="og:image" content="{{ absURL .Site.Params.logo }}">

<!-- Twitter Meta Tags -->
<meta name="twitter:card" content="summary_large_image">
<meta property="twitter:domain" content="{{ $u.Hostname }}">
<meta property="twitter:url" content="{{ .Permalink }}">
<meta name="twitter:title" content="{{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{.}} | {{ end }}{{ .Site.Title }}{{ end }}">
<meta name="twitter:description" content="{{ with .Summary }}{{ . }}{{ else }}{{ .Site.Params.description | markdownify | plainify }}{{ end }}">
<meta name="twitter:image" content="{{ absURL .Site.Params.logo }}">

0 comments on commit a9d3e62

Please sign in to comment.