Forum categories

Записки CotoДела

Мои записи, как типовые решения разных вопросов с Cotonti

webitproff
webitproff • 2026-03-20 11:35 #497

Микроразметка. Добавить плюс один год к текущей дате.

для самостоятельного обьекта ($item) или в цикле с ними добавить 

$next_year_timestamp = date('c', strtotime('+1 year'));

передаем в шаблон: 

        $t->assign([
         ....
            'SEOMARKETPRO_RELATED_ROW_PRICE_VALID_UNTIL'  => $next_year_timestamp,
       ]);

выводим в шаблоне

<meta itemprop="priceValidUntil" content="{SEOMARKETPRO_RELATED_ROW_PRICE_VALID_UNTIL}" />

получаем в браузере: 

<meta itemprop="priceValidUntil" content="2027-03-20T08:34:26+00:00">
🗿

🧙‍♂️ Well met, good traveler! Fate has guided your steps to our humble realm. Here, wise sages and masters of the coding craft ⚒️📜 gather to unravel the mysteries of the code ✨⚙️, share their knowledge, and add new chapters to our chronicles.
⬅️ To the left lie ancient scrolls 📚 filled with forgotten wisdom. ⬆️ Straight ahead, friendly folk offer counsel 💬 to those in need. ➡️ To the right, you may become a chronicler ✍️ yourself, sharing your craft and leaving words of wisdom for those yet to come.
📝 Delay no longer—tell us the name by which you are known, complete the rite of registration 🛡️, and join our fellowship!
🏰 Our brotherhood holds no secret initiation, yet many halls remain closed to wandering guests, for some knowledge 💎 is reserved for those who choose to walk this path beside us.