Contact Lenses
FYidoctors 的集合页
关于
// SEO Fix: Override non-crawlable links site-wide document.addEventListener('DOMContentLoaded', function() { // Fix javascript:void(0) links const voidLinks = document.querySelectorAll('a[href="javascript:void(0);"], a[href="javascript:void(0)"]'); voidLinks.forEach(function(link) { // Get the onclick content to determine destination const onclick = link.getAttribute('onclick'); if (onclick) { // Extract URL from common patterns let newHref = extractUrlFromOnclick(onclick); if (newHref) { link.href = newHref; link.removeAttribute('onclick'); } } // If no onclick, try to determine from text content if (!link.href || link.href.includes('javascript:')) { const linkText = link.textContent.toLowerCase().trim(); link.href = getUrlFromLinkText(linkText); } }); // Fix empty href links const emptyLinks = document.querySelectorAll('a[href=""], a[href="#"], a:not([href])'); emptyLinks.forEach(function(link) { const linkText = link.textContent.toLowerCase().trim(); const newHref = getUrlFromLinkText(linkText); if (newHref) { link.href = newHref; } }); // Fix language switching links specifically const langLinks = document.querySelectorAll('a[data-lang]'); langLinks.forEach(function(link) { const lang = link.getAttribute('data-lang'); const currentPath = window.location.pathname; if (lang === 'en') { link.href = currentPath.replace('/fr/', '/') || currentPath; } else if (lang === 'fr') { link.href = currentPath.includes('/fr/') ? currentPath : '/fr' + currentPath; } // Remove the onclick attribute if present link.removeAttribute('onclick'); }); }); // Helper function to extract URL from onclick content function extractUrlFromOnclick(onclick) { // Common patterns in onclick handlers const patterns = [ /window\.location\s*=\s*['"]([^'"]+)['"]/, /location\.href\s*=\s*['"]([^'"]+)['"]/, /goTo\(['"]([^'"]+)['"]\)/, /navigate\(['"]([^'"]+)['"]\)/, /redirect\(['"]([^'"]+)['"]\)/ ]; for (let pattern of patterns) { const match = onclick.match(pattern); if (match) { return match[1]; } }
页面 SEO
标题标签 (53)
Contact Lenses – Buy Online in Canada | Free Shipping
页面描述
Order contact lenses online in Canada. Top brands like Acuvue, Dailies and Biofinity with fast shipping, direct insurance billing and optometrist support.
H1
Contact Lenses
Canonical
https://fyidoctors.com/collections/contact-lenses
Robots
index
文案
673 词
登录后查看落在此页的广告及其链接关系。
登录查看全部发现