File: index.html

package info (click to toggle)
ruby-jekyll-polyglot 1.9.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 5,196 kB
  • sloc: xml: 1,500; ruby: 947; sh: 10; makefile: 4
file content (245 lines) | stat: -rw-r--r-- 9,245 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
<!DOCTYPE html>
<html lang="en-us">

  <head>
  
  <link href="http://gmpg.org/xfn/11" rel="profile">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta http-equiv="content-type" content="text/html; charset=utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta name="title" content="SEO Recipes &middot; Polyglot">
  <meta name="description" content="These additions can help improve the SEO of your multi-language jekyll blog when using Polyglot.">
  <meta name="keywords" content="multilingual, i18n, jekyll, polyglot, fast, intuitive, untra, github, pages, blog, plugin, ruby, gem, internationalization, localization, translation, language, support, multi-language, multi-lingual">
  <meta http-equiv="Content-Language" content="en">
<link rel="alternate" hreflang="en" href="https://polyglot.untra.io/seo/"/>
<link rel="alternate" hreflang="es" href="https://polyglot.untra.io/es/seo/"/>
<link rel="alternate" hreflang="de" href="https://polyglot.untra.io/de/seo/"/>
<link rel="alternate" hreflang="fr" href="https://polyglot.untra.io/fr/seo/"/>
<link rel="alternate" hreflang="ru" href="https://polyglot.untra.io/ru/seo/"/>
<link rel="alternate" hreflang="nl" href="https://polyglot.untra.io/nl/seo/"/>
<link rel="alternate" hreflang="he" href="https://polyglot.untra.io/he/seo/"/>
<link rel="alternate" hreflang="ko" href="https://polyglot.untra.io/ko/seo/"/>
<link rel="alternate" hreflang="zh-CN" href="https://polyglot.untra.io/zh-CN/seo/"/>
<link rel="alternate" hreflang="pt-BR" href="https://polyglot.untra.io/pt-BR/seo/"/>

  <title>
    
      SEO Recipes &middot; Polyglot
    
  </title>

  <!-- CSS -->
  <link rel="stylesheet" href="/public/css/poole.css">
  <link rel="stylesheet" href="/public/css/syntax.css">
  <link rel="stylesheet" href="/public/css/hyde.css">
  <link rel="stylesheet" href="/public/css/custom.css">
  <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=PT+Sans:400,400italic,700|Abril+Fatface">

  <!-- Icons -->
  <link rel="apple-touch-icon-precomposed" sizes="144x144" href="/public/apple-touch-icon-144-precomposed.png">
                                 <link rel="shortcut icon" href="/public/favicon.ico">

  <!-- RSS -->
  <link rel="alternate" type="application/rss+xml" title="RSS" href="/atom.xml">
</head>


  <body theme-base-08>

    
<div class="sidebar">
  <div class="container sidebar-sticky">
    <div class="sidebar-about">
      <p class="speech">Hello!</p>
    </br>
      <h1>
        <a href="">
          Polyglot
        </a>
      </h1>
      <p class="lead">A i18n support plugin for <a href="http://jekyllrb.com" target="_blank">Jekyll</a> that makes multi-language support fast and intuitive, for blogs big and small. Made by <a href="https://github.com/untra" target="_blank">@untra</a>.</p>
    </div>

    <nav class="sidebar-nav">
      <a class="sidebar-nav-item" href="/">Home</a>

      
      
      
        
        
          
          
        
      
        
        
          
            <a class="sidebar-nav-item" href="/about/">About</a>
          
          
        
      
        
        
          
            <a class="sidebar-nav-item" href="/a-really-long/permalink/">A really long permalink</a>
          
          
        
      
        
        
          
          
        
      
        
        
      
        
        
          
            <a class="sidebar-nav-item" href="/sample/">Sample rich text data</a>
          
          
        
      
        
        
          
            <a class="sidebar-nav-item active" href="/seo/">SEO Recipes</a>
          
          
        
      
        
        
      
        
        
      
        
        
      
        
        
      
        
        
      
        
        
      
        
        
      
        
        
      
        
        
      
        
        
      
        
        
      
        
          
        
          
        
          
        
          
      <a class="sidebar-nav-item" href=""></a>

      <a class="sidebar-nav-item" href="https://rubygems.org/gems/jekyll-polyglot">Ruby Gem</a>
      <a class="sidebar-nav-item" href="https://github.com/untra/polyglot">GitHub project</a>
      <a class="sidebar-nav-item" href="https://github.com/untra/polyglot/tree/master/site/seo.md"><small>view this page source on github</small></a>
      <small class="sidebar-nav-item">Currently v1.9.0</small>
    </nav>

    <p><small>&copy; 2025 Samuel Volin</small><br/><small>MIT Licensed</small></p>
<p>
  <!-- jekyll-polyglot will process ferh= into href= through the static_href liquid block tag without relativizing the url; useful for making language navigation switchers  -->
  
<a style="font-weight: bold;" href="/seo/" >en</a> •
<a  href="/es/seo/" >es</a> •
<a  href="/de/seo/" >de</a> •
<a  href="/fr/seo/" >fr</a> •
<a  href="/ru/seo/" >ru</a> •
<a  href="/nl/seo/" >nl</a> •
<a  href="/he/seo/" >he</a> •
<a  href="/ko/seo/" >ko</a> •
<a  href="/zh-CN/seo/" >zh-CN</a> •
<a  href="/pt-BR/seo/" >pt-BR</a>
</p>
  </div>
</div>


    <div class="content container">
      <div class="page">
  <h1 class="page-title">SEO Recipes</h1>
  <h1 id="recipes-for-search-engine-optimization-using-polyglot">Recipes for Search Engine Optimization using Polyglot</h1>

<p>If you have installed the <code class="language-plaintext highlighter-rouge">jekyll-polyglot</code> gem, these additions to your site head can easily provide your jekyll blog with Google-powered SEO bonuses.</p>

<h2 id="html-language-declaration">HTML Language Declaration</h2>

<p>Per <a href="http://www.w3.org/International/geo/html-tech/tech-lang.html#ri20060630.133615821">W3C Internationalization Best Practices</a>
you can set the default language of every page with a meta tag. Just add the following to your head:</p>

<figure class="highlight"><pre><code class="language-html" data-lang="html"><span class="nt">&lt;meta</span> <span class="na">http-equiv=</span><span class="s">"Content-Language"</span> <span class="na">content=</span><span class="s">"{{site.active_lang}}"</span><span class="nt">&gt;</span></code></pre></figure>

<h2 id="multi-language-seo-using-hreflang-alternate-tags">Multi-language SEO using hreflang alternate tags</h2>

<p>You can easily add <a href="https://support.google.com/webmasters/answer/189077?hl=en">hreflang alternate tags</a>
to your site, achieving SEO with google multi-language searches. Add the following to your head:</p>

<figure class="highlight"><pre><code class="language-html" data-lang="html"><span class="nt">&lt;link</span> <span class="na">rel=</span><span class="s">"alternate"</span>
      <span class="na">hreflang=</span><span class="s">"{{site.default_lang}}"</span>
      <span class="na">href=</span><span class="s">"http://yoursite.com{{page.permalink}}"</span> <span class="nt">/&gt;</span>
{% for lang in site.languages %}
{% if lang == site.default_lang %}
  {% continue %}
{% endif %}
<span class="nt">&lt;link</span> <span class="na">rel=</span><span class="s">"alternate"</span>
    <span class="na">hreflang=</span><span class="s">"{{lang}}"</span>
    <span class="na">href=</span><span class="s">"http://yoursite.com/{{lang}}{{page.permalink}}"</span> <span class="nt">/&gt;</span>
{% endfor %}</code></pre></figure>

<h2 id="all-of-the-above">All of the above</h2>

<p>You can get all of the above with a single tag added to your <code class="language-plaintext highlighter-rouge">head.html</code>:</p>

<figure class="highlight"><pre><code class="language-html" data-lang="html">{% I18n_Headers %}</code></pre></figure>

<p>With this SEO, each page click for one sites language will count towards the net clicks of all languages on the website.</p>

<h2 id="other-seo-best-practices-for-polyglot">Other SEO best practices for polyglot</h2>

<ul>
  <li>always be sure to specify <code class="language-plaintext highlighter-rouge">&lt;meta&gt;</code> tags for <code class="language-plaintext highlighter-rouge">keywords</code> and <code class="language-plaintext highlighter-rouge">description</code> of pages. Search Engines will use these tags to better index pages; for multi-language websites you should supply different values for each sub-language your website supports:</li>
</ul>

<figure class="highlight"><pre><code class="language-html" data-lang="html">  <span class="nt">&lt;meta</span> <span class="na">name=</span><span class="s">"description"</span> <span class="na">content=</span><span class="s">"{{ page.description | default: site.description[site.active_lang] }}"</span><span class="nt">&gt;</span>
  <span class="nt">&lt;meta</span> <span class="na">name=</span><span class="s">"keywords"</span> <span class="na">content=</span><span class="s">"{{ page.keywords | default: site.keywords[site.active_lang] }}"</span><span class="nt">&gt;</span></code></pre></figure>

</div>

    </div>

  </body>
  <script async src="https://www.googletagmanager.com/gtag/js?id=G-HWC3D32MT8"></script>
  <script>
    window.dataLayer = window.dataLayer || [];
    function gtag(){dataLayer.push(arguments);}
    gtag('js', new Date());
  
    gtag('config', 'G-HWC3D32MT8');
  </script>
</html>