File tree Expand file tree Collapse file tree 2 files changed +12
-5
lines changed
Expand file tree Collapse file tree 2 files changed +12
-5
lines changed Original file line number Diff line number Diff line change @@ -30,12 +30,17 @@ navigation:
3030 url : /restful/
3131languages :
3232- label : English
33+ iso-alpha2 : en
3334 path : /
3435- label : Japanese
36+ iso-alpha2 : ja
3537 path : /ja/
3638- label : Français
39+ iso-alpha2 : fr
3740 path : /fr/
3841- label : Português (Brasil)
42+ iso-alpha2 : br
3943 path : /br/
4044- label : Türkçe
41- path : /tr/
45+ iso-alpha2 : tr
46+ path : /tr/
Original file line number Diff line number Diff line change 1- <!DOCTYPE html>
2- < html >
1+ <!DOCTYPE html> {% assign hreflang = 'en' %}{% for lang in site.languages %}{% if lang.path == page.url %}{% assign hreflang = lang.iso-alpha2 %}{% endif %}{% endfor %}
2+ < html hreflang =" {{hreflang}} " >
33 < head >
44 < meta charset ="utf-8 ">
55 < meta http-equiv ="X-UA-Compatible " content ="IE=edge,chrome=1 ">
1414
1515 < title > {{ page.title }} | WP-CLI</ title >
1616 < meta name ="description " content ="{{ page.description }} ">
17+
18+ {% for lang in site.languages %}< link rel ="alternate " hreflang ="{{lang.iso-alpha2}} " href ="{{site.url}}{{lang.path}} " />
19+ {% endfor %}
1720 </ head >
1821
1922 {% if page.display_global_parameters %}
2023 < body class ="display-global-parameters ">
2124 {% else %}
2225 < body >
2326 {% endif %}
24-
2527 < header class ="cf ">
2628 < div class ="container ">
2729 < h1 > < a href ="/ "> WP-CLI</ a > </ h1 >
@@ -33,7 +35,7 @@ <h2>A command line interface for WordPress</h2>
3335 {% endif %}
3436
3537 {% include navigation.html %}
36- {% include languages.html %}
38+ {% include languages.html %}
3739 </ div >
3840 </ header >
3941
You can’t perform that action at this time.
0 commit comments