Skip to content

Commit c15c428

Browse files
committed
Enhance SEO and structure: Add structured data, improve sitemap, and fix minor title typos
1 parent f4b5d8d commit c15c428

9 files changed

Lines changed: 143 additions & 26 deletions

File tree

_includes/header.html

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<meta charset="utf-8">
22
{% capture og_url %}{{ site.url }}{{ page.url | remove: "index.html" | remove: ".html" }}{% endcapture %}
33
{% capture og_image %}{%- if page.imageurl -%}{{ site.url }}/assets/img/{{page.imageurl}}{% else %}https://avatars2.githubusercontent.com/u/30845478?s=280&amp;v=4{%- endif -%}{% endcapture %}
4-
{% capture page_title %} {%- if page.title -%} {{ page.title | smartify }} · {{ site.title | smartify }}{%- else -%}{{ site.title | smartify }} · {{ site.description | smartify }}{%- endif -%}{% endcapture %}
4+
{% capture page_title %}{%- if page.title -%}{{ page.title | smartify }}{%- unless page.landing == true -%} · {{ site.title | smartify }}{%- endunless -%}{%- else -%}{{ site.title | smartify }} · {{ site.description | smartify }}{%- endif -%}{% endcapture %}
55
{% capture page_description %}{{ page.description | default: site.description | smartify }}{% endcapture %}
66
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
77
<meta property="og:locale" content="en_US" />
@@ -26,12 +26,18 @@
2626
<meta name="generator" content="Jekyll v{{ jekyll.version }}">
2727
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
2828
<link rel="icon" href="/favicon.ico" type="image/x-icon">
29-
<link rel='dns-prefetch' href='https://stackpath.bootstrapcdn.com' />
30-
<link rel='dns-prefetch' href='https://www.googletagmanager.com' />
31-
{%- if page.canonical -%}
32-
<link rel="canonical" href="{{page.canonical}}" />
33-
{%- endif -%}
29+
<link rel="dns-prefetch" href="https://stackpath.bootstrapcdn.com" />
30+
<link rel="dns-prefetch" href="https://www.googletagmanager.com" />
31+
<link rel="dns-prefetch" href="https://code.jquery.com" />
32+
<link rel="dns-prefetch" href="https://cdnjs.cloudflare.com" />
33+
<link rel="dns-prefetch" href="https://translate.google.com" />
34+
<link rel="preconnect" href="https://stackpath.bootstrapcdn.com" crossorigin />
35+
<link rel="preconnect" href="https://cdnjs.cloudflare.com" crossorigin />
36+
<link rel="preconnect" href="https://code.jquery.com" crossorigin />
37+
<link rel="alternate" type="application/rss+xml" title="{{ site.title }}" href="{{ site.url }}/feed.xml" />
38+
<link rel="canonical" href="{{ og_url }}" />
3439
<title>{{ page_title }}</title>
40+
3541
<!-- Bootstrap core CSS -->
3642
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/4.6.2/css/bootstrap.min.css" integrity="sha512-rt/SrQ4UNIaGfDyEXZtNcyWvQeOq0QLygHluFQcSjaGB04IxWhal71tKuzP6K8eYXYB6vJV4pHkXcmFGGQ1/0w==" crossorigin="anonymous" referrerpolicy="no-referrer" />
3743
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.1/css/all.min.css" integrity="sha512-MV7K8+y+gLIBoVD59lQIYicR65iaqukzvf/nwasF0nqhPay5w/9lJmVM2hMDcnK1OnMGCdVK+iQrJ7lzPJQd1w==" crossorigin="anonymous" referrerpolicy="no-referrer" />
@@ -76,10 +82,10 @@
7682
}
7783

7884
if(readCookie('cookie-notice-dismissed')=='true') {
79-
window.dataLayer = window.dataLayer || [];
80-
function gtag(){dataLayer.push(arguments);}
81-
gtag('js', new Date());
82-
gtag('config', 'G-Q5PEKRFRH8');
85+
window.dataLayer = window.dataLayer || [];
86+
function gtag(){dataLayer.push(arguments);}
87+
gtag('js', new Date());
88+
gtag('config', 'G-Q5PEKRFRH8');
8389
} else {
8490
document.getElementById('cookie-notice').style.display = 'block';
8591
}
@@ -89,4 +95,4 @@
8995
location.reload();
9096
});
9197

92-
</script>
98+
</script>

_includes/navbar.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
</div>
3232
</li>
3333
<li class="nav-item">
34-
<a target="_blank" class="nav-link" href="https://doc.openidentityplatform.org">Documentation</span></a>
34+
<a target="_blank" class="nav-link" href="https://doc.openidentityplatform.org">Documentation</a>
3535
</li>
3636
<li class="nav-item {{page.navbar.blog_active}}">
3737
<a class="nav-link" href="/blog/">Blog <span class="sr-only">(current)</span></a>

_includes/structured-data.html

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
{% capture page_url %}{{ site.url }}{{ page.url | remove: "index.html" | remove: ".html" }}{% endcapture %}
2+
3+
{% comment %}Organization schema on every page{% endcomment %}
4+
<script type="application/ld+json">
5+
{
6+
"@context": "https://schema.org",
7+
"@type": "Organization",
8+
"name": "{{ site.title }}",
9+
"url": "{{ site.url }}",
10+
"logo": "{{ site.image }}",
11+
"description": "{{ site.description | smartify }}",
12+
"sameAs": [
13+
"https://github.com/OpenIdentityPlatform",
14+
"https://github.com/orgs/OpenIdentityPlatform/discussions"
15+
]
16+
}
17+
</script>
18+
19+
{% comment %}Product schema on product pages{% endcomment %}
20+
{%- if page.product -%}
21+
{%- assign product_data = site.data.products | where: "product", page.product | first -%}
22+
{%- if product_data == nil -%}
23+
{%- for p in site.data.products -%}
24+
{%- assign p_name = p.name | downcase -%}
25+
{%- assign page_product = page.product -%}
26+
{%- if p_name == page_product -%}
27+
{%- assign product_data = p -%}
28+
{%- endif -%}
29+
{%- endfor -%}
30+
{%- endif -%}
31+
<script type="application/ld+json">
32+
{
33+
"@context": "https://schema.org",
34+
"@type": "SoftwareSourceCode",
35+
"name": "{{ page.title }}",
36+
"description": "{{ page_description }}",
37+
"url": "{{ page_url }}",
38+
"codeRepository": "{{ product_data.link }}",
39+
"programmingLanguage": "Java",
40+
"license": "https://spdx.org/licenses/CDDL-1.1",
41+
"isPartOf": {
42+
"@type": "Organization",
43+
"name": "{{ site.title }}",
44+
"url": "{{ site.url }}"
45+
}
46+
}
47+
</script>
48+
{%- endif -%}
49+
50+
{% comment %}Article schema on blog posts{% endcomment %}
51+
{%- if page.url contains "/blog/" and page.date -%}
52+
<script type="application/ld+json">
53+
{
54+
"@context": "https://schema.org",
55+
"@type": "BlogPosting",
56+
"headline": "{%- if page.landing-title -%}{{ page.landing-title }}{%- else -%}{{ page.title }}{%- endif -%}",
57+
"description": "{{ page_description }}",
58+
"url": "{{ page_url }}",
59+
"datePublished": "{{ page.date | date_to_xmlschema }}",
60+
{%- if page.lastmod %}
61+
"dateModified": "{{ page.lastmod | date_to_xmlschema }}",
62+
{%- else %}
63+
"dateModified": "{{ page.date | date_to_xmlschema }}",
64+
{%- endif %}
65+
"author": {
66+
"@type": "Organization",
67+
"name": "{{ site.authors }}"
68+
},
69+
"publisher": {
70+
"@type": "Organization",
71+
"name": "{{ site.title }}",
72+
"logo": {
73+
"@type": "ImageObject",
74+
"url": "{{ site.image }}"
75+
}
76+
},
77+
{%- if page.imageurl %}
78+
"image": "{{ site.url }}/assets/img/{{ page.imageurl }}",
79+
{%- else %}
80+
"image": "{{ site.image }}",
81+
{%- endif %}
82+
"mainEntityOfPage": {
83+
"@type": "WebPage",
84+
"@id": "{{ page_url }}"
85+
}
86+
}
87+
</script>
88+
{%- endif -%}

_layouts/home.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<html lang="en">
33
<head>
44
{% include header.html %}
5+
{% include structured-data.html %}
56
</head>
67
<body class="oip">
78
{%comment%}

_layouts/redirect.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33
<head>
44
<meta http-equiv="refresh" content="0; url={{page.redirect_to}}">
55
<link rel="canonical" href="{{page.redirect_to}}" />
6+
<meta name="robots" content="noindex, follow">
67
</head>
78
</html>

blog/index.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
---
22
layout: home
33
description: Open Identity Platform Blog
4-
title: Open Identity Platform releases info, news and technical aticles
4+
title: Open Identity Platform releases info, news and technical articles
55
keywords: Access Management, Identity Management, Directory Services, LDAP, Identity Gateway, SSO, OpenAM, OpenDJ, OpenIG, OpenICF, OpenIDM, Open Identity Platform, blog, news, articles
66
navbar:
77
blog_active: 'active'
8-
canonical: "https://www.openidentityplatform.org/blog/"
98
---
109

1110
<h1>Recent blog articles:</h1>

index.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
---
22
layout: home
33
landing: true
4+
title: "Open Source IAM & SSO"
45
landing-title: "Welcome to Open Identity Platform Community"
56
landing-title2: "Open-source community organization, hosted on <a target=\"_blank\" href=\"https://github.com/OpenIdentityPlatform\">GitHub</a>"
67
landing-title3: "We develop and support Single Sign-On, Access Management, Identity Management, User-Managed Access, Directory Services, and Identity Gateway, designed and built as a single, unified platform"
7-
8-
canonical: "https://www.openidentityplatform.org"
98
---
109
<!--<h3>Products</h3>
1110
<p>Access management, identity management, user-managed access, directory services, and identity gateway, designed and built as a single, unified platform:</p>

openig.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
layout: home
3-
title: OpenIG - Open Indentity Gateway
3+
title: OpenIG - Open Identity Gateway
44
description: 'OpenIG by Open Identity Platform: High-performance identity gateway & reverse proxy. Secure apps/APIs with SSO/SLO, standards federation (OAuth, OIDC, SAML), policy enforcement, no-code integration. High-performance, flexible access management solution.'
55
keywords: OpenIG, Open Identity Gateway, open source identity gateway, reverse proxy, OpenIG gateway, Open Identity Platform, SSO gateway, identity gateway open source, OAuth 2.0 gateway, OpenID Connect proxy, SAML 2.0 federation, API security gateway, policy enforcement point, credential replay, secure access proxy, Java reverse proxy, open source SSO, federation gateway, OpenIG download, zero trust access
66
reponame: OpenIG

sitemap.xml

Lines changed: 32 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,31 +3,54 @@ layout: null
33
---
44
<?xml version="1.0" encoding="UTF-8"?>
55
<urlset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd" xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
6+
{% assign product_pages = "/opendj,/openam,/openig,/openicf,/openidm" | split: "," %}
67
{% for post in site.posts %}
78
<url>
89
<loc>{{ site.url }}{{ post.url }}</loc>
9-
{% if post.lastmod == null %}
10+
{% if post.lastmod %}
11+
<lastmod>{{ post.lastmod | date_to_xmlschema }}</lastmod>
12+
{% else %}
1013
<lastmod>{{ post.date | date_to_xmlschema }}</lastmod>
14+
{% endif %}
15+
{% assign now_ts = "now" | date: "%s" | times: 1 %}
16+
{% assign post_ts = post.date | date: "%s" | times: 1 %}
17+
{% assign days_since_post = now_ts | minus: post_ts | divided_by: 86400 %}
18+
{% if days_since_post < 90 %}
19+
<changefreq>weekly</changefreq>
1120
{% else %}
12-
<lastmod>{{ post.lastmod | date_to_xmlschema }}</lastmod>
21+
<changefreq>monthly</changefreq>
1322
{% endif %}
14-
<changefreq>weekly</changefreq>
15-
<priority>1.0</priority>
23+
<priority>0.8</priority>
1624
</url>
1725
{% endfor %}
1826
{% for page in site.pages %}
19-
{% if page.layout != null and page.layout != empty and page.layout != "redirect" %}
27+
{% if page.layout != null and page.layout != empty and page.layout != "redirect" %}
2028
<url>
2129
<loc>{{ site.url }}{{ page.url | remove: "index.html" | remove: ".html" }}</loc>
22-
</url>
23-
{% endif %}
30+
{% if page.lastmod %}
31+
<lastmod>{{ page.lastmod | date_to_xmlschema }}</lastmod>
32+
{% endif %}
33+
{% if page.url == "/" %}
34+
<changefreq>weekly</changefreq>
35+
<priority>1.0</priority>
36+
{% elsif product_pages contains page.url %}
37+
<changefreq>monthly</changefreq>
38+
<priority>0.9</priority>
39+
{% else %}
40+
<changefreq>monthly</changefreq>
41+
<priority>0.5</priority>
42+
{% endif %}
43+
</url>
44+
{% endif %}
2445
{% endfor %}
2546

2647
{% for file in site.static_files %}
27-
{% if file.name == "index.html"%}
48+
{% if file.name == "index.html" %}
2849
<url>
2950
<loc>{{ site.url }}{{ file.path | remove: "index.html" | remove: ".html" }}</loc>
30-
</url>
51+
<changefreq>monthly</changefreq>
52+
<priority>0.5</priority>
53+
</url>
3154
{% endif %}
3255
{% endfor %}
3356
</urlset>

0 commit comments

Comments
 (0)