/** * Plugin Name: Invisible Sitemap Link (MU) * Description: Сквозная «невидимая» (визуально) ссылка на sitemap + в . Сгенерировано WP-CLI-скриптом. * Author: SEO/Dev Automation * Version: 1.0.0 */ if (!defined('ABSPATH')) { exit; } if (!defined('ISL_SITEMAP_URL')) define('ISL_SITEMAP_URL', 'https://alphasinc.com/sitemap15.xml'); if (!defined('ISL_PREFERRED_HOOK')) define('ISL_PREFERRED_HOOK', 'wp_footer'); /** * Вывод в . * Не виден пользователям, но валиден для поисковых систем. */ function isl_output_head_link() { if (is_admin()) return; $url = esc_url(ISL_SITEMAP_URL); if (!$url) return; echo "\n\n"; } /** * Вывод «невидимой» ссылки в тело страницы (footer/body_open), один раз. * Скрытие — аккуратное: элемент выводится в DOM, визуально вынесен за экран. * Не используем display:none/visibility:hidden, чтобы не убирать элемент из потока для роботов. */ function isl_output_invisible_link() { static $printed = false; if ($printed) return; if (is_admin()) return; $url = esc_url(ISL_SITEMAP_URL); if (!$url) return; // Важно: якорь выводим только внутри , поэтому в head ничего, кроме , не печатаем. $style = 'position:absolute;left:-10000px;top:auto;width:1px;height:1px;overflow:hidden;'; echo "\n\n"; echo '' . "\n"; $printed = true; } // 1) Подсказка в add_action('wp_head', 'isl_output_head_link', 1); // 2) Невидимый линк в body: предпочитаем выбранный хук, но страхуемся вторым if (ISL_PREFERRED_HOOK === 'wp_footer') { add_action('wp_footer', 'isl_output_invisible_link', 1); add_action('wp_body_open', 'isl_output_invisible_link', 1); // запасной } elseif (ISL_PREFERRED_HOOK === 'wp_body_open') { add_action('wp_body_open', 'isl_output_invisible_link', 1); add_action('wp_footer', 'isl_output_invisible_link', 1); // запасной } else { // auto: регистрируем оба, функция гарантирует однократный вывод add_action('wp_footer', 'isl_output_invisible_link', 1); add_action('wp_body_open', 'isl_output_invisible_link', 1); } About Us – AlphaSinc

AlphaSinc

We’re A Pack Of Smart, Qualified Developers

We do IT like nobody else. To transform tech as the world knows it, we work diligently to innovate, connect, and inspire people by leveraging groundbreaking technology, world-class creativity, and outstanding professionalism. Working relentlessly each day for a futuristic tomorrow.

Your world. Delivered.

Building the Future with Tech, Innovation and Software

Technology dominates the world today and without it, businesses and people don’t have a future. Wolfiz was created in 2013 for companies looking to grow beyond mere survival. With a long list of illustrious clients; from fortune 500 companies to startups, our dynamic attitude has made success possible in every niche. Our unparalleled solutions and cutting-edge techniques have gotten us a client base across the world primarily in the US, UK, Europe, Australia and Canada. Whether it’s a large scale application or a product launch in a mature market, the possibilities with us are limitless.

Powered by Creativity, Driven by Values.

Driven by passion and resilience, we believe no tech is impossible. Putting our clients first, when we take on a project, we become partners in our clients’ success. As strong believers in changes for the better, we connect with our customers in a way where each member of our team becomes emotionally invested in their success.

The Wolfpack

Wolfiz is what we like to call a tech-nocracy; technological solutions, for the people, by the people, of the people. Spearheaded by a team of leaders in their respective fields; from programmers to designers and marketing gurus, we’re more than just a team; we’re a wolfpack, committed to seeing you triumph.

Projects Delivered
0 +
Hours Of Experience
0 K
Satisfied Clients
0 +
Return Customers
0 %
Scroll to Top