← back to AsSeenInMovies
asseeninmovies: canonical URLs + WebSite/Organization JSON-LD — htmlShell now takes optional canonical param; /movie/:id + /person/:id pass theirs; home page gets WebSite schema with SearchAction (Google sitelinks search box) + Organization → Designer Wallcoverings + OG + Twitter Card. Closes the asim-vs-sod canonical parity gap.
f89066da67c41fff2532487aaadd59d1ccbd6785 · 2026-05-12 18:46:07 -0700 · SteveStudio2
Files touched
Diff
commit f89066da67c41fff2532487aaadd59d1ccbd6785
Author: SteveStudio2 <stevestudio2@SteveStacStudio.lan>
Date: Tue May 12 18:46:07 2026 -0700
asseeninmovies: canonical URLs + WebSite/Organization JSON-LD — htmlShell now takes optional canonical param; /movie/:id + /person/:id pass theirs; home page gets WebSite schema with SearchAction (Google sitelinks search box) + Organization → Designer Wallcoverings + OG + Twitter Card. Closes the asim-vs-sod canonical parity gap.
---
server.js | 14 +++++++++++---
1 file changed, 11 insertions(+), 3 deletions(-)
diff --git a/server.js b/server.js
index 3d41d67..696bff6 100644
--- a/server.js
+++ b/server.js
@@ -841,12 +841,13 @@ function imageCreditHtml(credit, license, sourceUrl, sourceKind) {
return `<span class="img-credit">Photo: ${artistPart}${licPart}<a href="${esc(sourceUrl)}" rel="nofollow noopener" target="_blank">source</a></span>`;
}
-function htmlShell(title, body, headExtras = '') {
+function htmlShell(title, body, headExtras = '', canonical = '') {
return `<!doctype html>
<html lang="en"><head>
<meta charset="utf-8"><title>${esc(title)} · AsSeenInMovies</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" type="image/svg+xml" href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Crect width='32' height='32' rx='6' fill='%230d0c0a'/%3E%3Ctext x='16' y='22' font-family='Georgia,serif' font-style='italic' font-size='20' fill='%23c9a14b' text-anchor='middle'%3EA%3C/text%3E%3C/svg%3E">
+${canonical ? `<link rel="canonical" href="${esc(canonical)}">` : ''}
${headExtras}
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
@@ -1038,7 +1039,7 @@ app.get('/movie/:id', async (req, res) => {
<meta name="twitter:description" content="${esc(ogDesc)}">
<meta name="twitter:image" content="${esc(ogImage)}">
<script type="application/ld+json">${jsonLd}</script>`;
- res.type('html').send(htmlShell(mv.title || ('Movie #' + id), heroHtml + spottedHtml + (creditsHtml ? `<section><h2>Cast & crew</h2>${creditsHtml}</section>` : ''), headExtras));
+ res.type('html').send(htmlShell(mv.title || ('Movie #' + id), heroHtml + spottedHtml + (creditsHtml ? `<section><h2>Cast & crew</h2>${creditsHtml}</section>` : ''), headExtras, `https://asseeninmovies.com/movie/${id}`));
} catch (e) {
res.status(500).type('html').send(htmlShell('Error', `<div class="empty">${esc(e.message)}</div>`));
}
@@ -1147,7 +1148,7 @@ app.get('/person/:id', async (req, res) => {
<meta name="twitter:description" content="${esc(ogDesc)}">
<meta name="twitter:image" content="${esc(ogImage)}">
<script type="application/ld+json">${jsonLd}</script>`;
- res.type('html').send(htmlShell(person.full_name, heroHtml + filmHtml + personSpottedHtml, headExtras));
+ res.type('html').send(htmlShell(person.full_name, heroHtml + filmHtml + personSpottedHtml, headExtras, `https://asseeninmovies.com/person/${id}`));
} catch (e) {
res.status(500).type('html').send(htmlShell('Error', `<div class="empty">${esc(e.message)}</div>`));
}
@@ -1456,7 +1457,14 @@ app.get('/', async (_req, res) => {
<meta charset="utf-8"><title>AsSeenInMovies</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" type="image/svg+xml" href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Crect width='32' height='32' rx='6' fill='%230d0c0a'/%3E%3Ctext x='16' y='22' font-family='Georgia,serif' font-style='italic' font-size='20' fill='%23c9a14b' text-anchor='middle'%3EA%3C/text%3E%3C/svg%3E">
+<link rel="canonical" href="https://asseeninmovies.com/">
<meta name="description" content="AsSeenInMovies — a film + TV reference built on public data. Browse 290k+ movies, 61k+ people, and verified SPOTTED set decor, wallcoverings, lighting, and props from the films you love.">
+<meta property="og:type" content="website">
+<meta property="og:title" content="AsSeenInMovies — A Film + TV Reference">
+<meta property="og:description" content="290k+ movies, 61k+ people, and verified SPOTTED set decor, wallcoverings, lighting, and props from the films you love.">
+<meta property="og:url" content="https://asseeninmovies.com/">
+<meta name="twitter:card" content="summary_large_image">
+<script type="application/ld+json">{"@context":"https://schema.org","@graph":[{"@type":"WebSite","@id":"https://asseeninmovies.com/#website","url":"https://asseeninmovies.com/","name":"AsSeenInMovies","description":"A film + TV reference built on public data — movies, people, and verified SPOTTED set decor placements.","potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://asseeninmovies.com/search?q={search_term_string}"},"query-input":"required name=search_term_string"}},{"@type":"Organization","@id":"https://asseeninmovies.com/#org","name":"Designer Wallcoverings","url":"https://designerwallcoverings.com/","sameAs":["https://www.themoviedb.org/"]}]}</script>
<style>
:root { --bg:#0d0c0a; --ink:#f0ebe3; --gold:#c9a14b; --muted:#7a706a; --line:#2a2620; }
*,*::before,*::after { box-sizing: border-box; }
← f4b860b asseeninmovies: home cache — true stale-while-revalidate. St
·
back to AsSeenInMovies
·
asseeninmovies: canonical URLs on all 5 remaining htmlShell f353476 →