fix: update sitemap with pSeo pages, fix dynamic metadata placeholders, and add llms.txt
This commit is contained in:
105
app/layout.tsx
105
app/layout.tsx
@@ -14,22 +14,22 @@ import sql from "@/lib/db";
|
|||||||
export async function generateMetadata(): Promise<Metadata> {
|
export async function generateMetadata(): Promise<Metadata> {
|
||||||
let settings: any = null;
|
let settings: any = null;
|
||||||
try {
|
try {
|
||||||
const result = await sql`SELECT site_name, site_description FROM settings WHERE id = 1 LIMIT 1`;
|
const result = await sql`SELECT * FROM settings WHERE id = 1 LIMIT 1`;
|
||||||
if (result.length > 0) settings = result[0];
|
if (result.length > 0) settings = result[0];
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error(e);
|
console.error(e);
|
||||||
}
|
}
|
||||||
const siteName = settings?.site_name || "Muğla Dijital Medya Ajansı";
|
const siteName = settings?.site_name || "Muğla Dijital | Medya & Prodüksiyon Ajansı";
|
||||||
const siteDesc = settings?.site_description || "Muğla Dijital Medya Ajansı olarak sosyal medya yönetimi, reklam yönetimi, SEO, web tasarım ve dijital pazarlama çözümleriyle markanızı öne çıkarıyoruz.";
|
const siteDesc = settings?.site_description || "Muğla'nın öncü dijital medya ajansı. Drone çekimi, sosyal medya yönetimi ve profesyonel reklam çözümleri.";
|
||||||
const baseUrl = process.env.NEXT_PUBLIC_BASE_URL || "https://mugladijitalmedya.com";
|
const baseUrl = process.env.NEXT_PUBLIC_BASE_URL || "https://mugladijitalmedya.com";
|
||||||
|
|
||||||
return {
|
return {
|
||||||
metadataBase: new URL(baseUrl),
|
metadataBase: new URL(baseUrl),
|
||||||
title: {
|
title: {
|
||||||
default: "Muğla Dijital | Medya & Prodüksiyon Ajansı",
|
default: siteName,
|
||||||
template: "%s | Muğla Dijital"
|
template: `%s | ${siteName.split('|')[0].trim()}`
|
||||||
},
|
},
|
||||||
description: "Muğla'nın öncü dijital medya ajansı. Drone çekimi, sosyal medya yönetimi ve profesyonel reklam çözümleri.",
|
description: siteDesc,
|
||||||
authors: [{ name: "Muğla Dijital" }],
|
authors: [{ name: "Muğla Dijital" }],
|
||||||
creator: "Muğla Dijital",
|
creator: "Muğla Dijital",
|
||||||
publisher: "Muğla Dijital",
|
publisher: "Muğla Dijital",
|
||||||
@@ -39,10 +39,10 @@ export async function generateMetadata(): Promise<Metadata> {
|
|||||||
openGraph: {
|
openGraph: {
|
||||||
type: "website",
|
type: "website",
|
||||||
locale: "tr_TR",
|
locale: "tr_TR",
|
||||||
url: "https://mugladijitalmedya.com",
|
url: baseUrl,
|
||||||
siteName: "Muğla Dijital",
|
siteName: "Muğla Dijital",
|
||||||
title: "Muğla Dijital | Medya & Prodüksiyon Ajansı",
|
title: siteName,
|
||||||
description: "Profesyonel drone çekimi ve dijital medya çözümleri.",
|
description: siteDesc,
|
||||||
images: [
|
images: [
|
||||||
{
|
{
|
||||||
url: "/og-image.jpg",
|
url: "/og-image.jpg",
|
||||||
@@ -54,74 +54,61 @@ export async function generateMetadata(): Promise<Metadata> {
|
|||||||
},
|
},
|
||||||
twitter: {
|
twitter: {
|
||||||
card: "summary_large_image",
|
card: "summary_large_image",
|
||||||
title: "Muğla Dijital | Medya & Prodüksiyon Ajansı",
|
title: siteName,
|
||||||
description: "Dijital dünyada markanızı zirveye taşıyın.",
|
description: siteDesc,
|
||||||
images: ["/og-image.jpg"],
|
images: ["/og-image.jpg"],
|
||||||
},
|
},
|
||||||
robots: {
|
robots: {
|
||||||
index: true,
|
index: true,
|
||||||
follow: true,
|
follow: true,
|
||||||
googleBot: {
|
|
||||||
index: true,
|
|
||||||
follow: true,
|
|
||||||
'max-video-preview': -1,
|
|
||||||
'max-image-preview': 'large',
|
|
||||||
'max-snippet': -1,
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function RootLayout({
|
export default async function RootLayout({
|
||||||
children,
|
children,
|
||||||
}: Readonly<{
|
}: Readonly<{
|
||||||
children: React.ReactNode;
|
children: React.ReactNode;
|
||||||
}>) {
|
}>) {
|
||||||
return (
|
let settings: any = null;
|
||||||
<html lang="tr">
|
try {
|
||||||
<body
|
const result = await sql`SELECT * FROM settings WHERE id = 1 LIMIT 1`;
|
||||||
className={`${martianMono.variable} antialiased`}
|
if (result.length > 0) settings = result[0];
|
||||||
>
|
} catch (e) {
|
||||||
<ClientWrapper>
|
console.error(e);
|
||||||
{children}
|
}
|
||||||
</ClientWrapper>
|
|
||||||
<script
|
const jsonLd = {
|
||||||
type="application/ld+json"
|
|
||||||
dangerouslySetInnerHTML={{
|
|
||||||
__html: JSON.stringify({
|
|
||||||
"@context": "https://schema.org",
|
"@context": "https://schema.org",
|
||||||
"@type": "Organization",
|
"@type": "Organization",
|
||||||
"name": "Muğla Dijital Medya Ajansı",
|
"name": settings?.site_name || "Muğla Dijital Medya Ajansı",
|
||||||
"url": "https://mugladijitalmedya.com",
|
"url": "https://mugladijitalmedya.com",
|
||||||
"logo": "https://mugladijitalmedya.com/logo.png",
|
"logo": "https://mugladijitalmedya.com/logo.png",
|
||||||
"sameAs": [
|
"sameAs": [
|
||||||
"https://www.instagram.com/mugladijitalmedya/",
|
settings?.instagram_url,
|
||||||
// Add other social media links here
|
settings?.twitter_url,
|
||||||
],
|
settings?.linkedin_url
|
||||||
|
].filter(Boolean),
|
||||||
"contactPoint": {
|
"contactPoint": {
|
||||||
"@type": "ContactPoint",
|
"@type": "ContactPoint",
|
||||||
"telephone": "+90-XXX-XXX-XXXX", // Should be updated with real phone
|
"telephone": settings?.contact_phone || "+90-252-XXX-XXXX",
|
||||||
"contactType": "customer service",
|
"contactType": "customer service",
|
||||||
"areaServed": "TR",
|
"areaServed": "TR",
|
||||||
"availableLanguage": ["Turkish", "English"]
|
"availableLanguage": ["Turkish", "English"]
|
||||||
}
|
}
|
||||||
})
|
};
|
||||||
}}
|
|
||||||
/>
|
const localBusinessLd = {
|
||||||
<script
|
|
||||||
type="application/ld+json"
|
|
||||||
dangerouslySetInnerHTML={{
|
|
||||||
__html: JSON.stringify({
|
|
||||||
"@context": "https://schema.org",
|
"@context": "https://schema.org",
|
||||||
"@type": "LocalBusiness",
|
"@type": "LocalBusiness",
|
||||||
"name": "Muğla Dijital Medya Ajansı",
|
"name": settings?.site_name || "Muğla Dijital Medya Ajansı",
|
||||||
"image": "https://mugladijitalmedya.com/og-image.jpg",
|
"image": "https://mugladijitalmedya.com/og-image.jpg",
|
||||||
"@id": "https://mugladijitalmedya.com",
|
"@id": "https://mugladijitalmedya.com",
|
||||||
"url": "https://mugladijitalmedya.com",
|
"url": "https://mugladijitalmedya.com",
|
||||||
"telephone": "+90-XXX-XXX-XXXX",
|
"telephone": settings?.contact_phone || "+90-252-XXX-XXXX",
|
||||||
"address": {
|
"address": {
|
||||||
"@type": "PostalAddress",
|
"@type": "PostalAddress",
|
||||||
"streetAddress": "Muğla",
|
"streetAddress": settings?.office_address || "Muğla",
|
||||||
"addressLocality": "Muğla",
|
"addressLocality": "Muğla",
|
||||||
"addressRegion": "Muğla",
|
"addressRegion": "Muğla",
|
||||||
"postalCode": "48000",
|
"postalCode": "48000",
|
||||||
@@ -134,19 +121,25 @@ export default function RootLayout({
|
|||||||
},
|
},
|
||||||
"openingHoursSpecification": {
|
"openingHoursSpecification": {
|
||||||
"@type": "OpeningHoursSpecification",
|
"@type": "OpeningHoursSpecification",
|
||||||
"dayOfWeek": [
|
"dayOfWeek": ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"],
|
||||||
"Monday",
|
|
||||||
"Tuesday",
|
|
||||||
"Wednesday",
|
|
||||||
"Thursday",
|
|
||||||
"Friday",
|
|
||||||
"Saturday"
|
|
||||||
],
|
|
||||||
"opens": "09:00",
|
"opens": "09:00",
|
||||||
"closes": "18:00"
|
"closes": "18:00"
|
||||||
}
|
}
|
||||||
})
|
};
|
||||||
}}
|
|
||||||
|
return (
|
||||||
|
<html lang="tr">
|
||||||
|
<body className={`${martianMono.variable} antialiased`}>
|
||||||
|
<ClientWrapper>
|
||||||
|
{children}
|
||||||
|
</ClientWrapper>
|
||||||
|
<script
|
||||||
|
type="application/ld+json"
|
||||||
|
dangerouslySetInnerHTML={{ __html: JSON.stringify(jsonLd) }}
|
||||||
|
/>
|
||||||
|
<script
|
||||||
|
type="application/ld+json"
|
||||||
|
dangerouslySetInnerHTML={{ __html: JSON.stringify(localBusinessLd) }}
|
||||||
/>
|
/>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -28,5 +28,23 @@ export default async function sitemap(): Promise<MetadataRoute.Sitemap> {
|
|||||||
priority: 0.6,
|
priority: 0.6,
|
||||||
}));
|
}));
|
||||||
|
|
||||||
return [...staticPages, ...projectPages];
|
// Programmatic SEO pages (Services + Locations)
|
||||||
|
const [services, locations] = await Promise.all([
|
||||||
|
sql`SELECT slug FROM services`,
|
||||||
|
sql`SELECT slug FROM locations`
|
||||||
|
]);
|
||||||
|
|
||||||
|
const pSeoPages = [];
|
||||||
|
for (const service of services) {
|
||||||
|
for (const location of locations) {
|
||||||
|
pSeoPages.push({
|
||||||
|
url: `${baseUrl}/services/${service.slug}/${location.slug}`,
|
||||||
|
lastModified: new Date(),
|
||||||
|
changeFrequency: 'weekly' as const,
|
||||||
|
priority: 0.7,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return [...staticPages, ...projectPages, ...pSeoPages];
|
||||||
}
|
}
|
||||||
27
public/llms.txt
Normal file
27
public/llms.txt
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
# Muğla Dijital Medya Ajansı
|
||||||
|
|
||||||
|
Muğla'nın öncü dijital medya ve prodüksiyon ajansı. Sosyal medya yönetimi, profesyonel video prodüksiyon, drone çekimi ve dijital reklam stratejileri sunar.
|
||||||
|
|
||||||
|
## Core Services
|
||||||
|
- **Drone & Video Prodüksiyon**: 4K havadan çekimler, tanıtım filmleri, etkinlik çekimleri.
|
||||||
|
- **Sosyal Medya Yönetimi**: İçerik stratejisi, topluluk yönetimi, kreatif tasarım.
|
||||||
|
- **Dijital Reklam Yönetimi**: Google Ads, Meta Ads (Instagram/Facebook) ve hedefli kampanya yönetimi.
|
||||||
|
- **SEO & Web Tasarım**: Modern, hızlı ve arama motoru dostu web çözümleri.
|
||||||
|
|
||||||
|
## Service Areas (pSEO)
|
||||||
|
Muğla Dijital provides localized services across all major districts of Muğla:
|
||||||
|
- Bodrum
|
||||||
|
- Marmaris
|
||||||
|
- Fethiye
|
||||||
|
- Datça
|
||||||
|
- Dalaman
|
||||||
|
- Milas
|
||||||
|
- Menteşe
|
||||||
|
|
||||||
|
## Methodology
|
||||||
|
We combine editorial design aesthetics with data-driven performance marketing. Our process includes deep analysis, strategic planning, creative execution, and transparent reporting.
|
||||||
|
|
||||||
|
## Contact Information
|
||||||
|
- Website: https://mugladijitalmedya.com
|
||||||
|
- Location: Muğla, Turkey
|
||||||
|
- Specialization: Local and international brand positioning in the Muğla region.
|
||||||
Reference in New Issue
Block a user