Не даёт мне жизни такая штука:
Это если заходить из профиля пользователя
хтмл: Контейнер subscribe почему-то генерируется раньше заголовка
2.17.1 чистая установка
В файле \templates\modern\controllers\users\profile_content.tpl.php
Вот код, который выводит заголовок (проверено)
<a class="avatar icms-user-avatar d-none d-lg-flex mr-3 <?php if (!empty($profile['is_online'])){ ?>peer_online<?php } else { ?>peer_no_online<?php } ?>" href="<?php echo href_to_profile($profile); ?>"> <?php if($profile['avatar']){ ?> <?php echo html_avatar_image($profile['avatar'], $fields['avatar']['options']['size_teaser'], $profile['nickname']); ?> <?php } else { ?> <?php echo html_avatar_image_empty($profile['nickname'], 'avatar__inlist'); ?> <?php } ?> </a> <h1 class="d-flex align-items-center h2"> <span> <a href="<?php echo href_to_profile($profile); ?>" class="text-muted"> <?php html($profile['nickname']); ?> </a> <span class="d-none d-lg-inline-block"> · <?php echo $list_header_h1; ?></span> </span> <sup> <a class="inline_rss_icon d-none d-lg-inline-block" href="<?php echo $ctype['rss_link']; ?>" title="RSS"> <?php html_svg_icon('solid', 'rss'); ?> </a> </sup> <?php } ?> </h1> <?php $this->addToBlock('before_body', ob_get_clean().($toolbar_html ? html_each($toolbar_html) : '')); } ?>
html
<div class="icms-body-toolbox"> <div class="subscribe_wrap position-relative ml-lg-2 mb-2 mb-lg-0 d-flex flex-shrink-0"> <a href="/subscriptions/subscribe" class="btn subscriber btn-responsive subscribe btn-primary" data-hash="6a93750e3eda550db86a7d1ccbd7107" data-link0="/subscriptions/subscribe" data-link1="/subscriptions/unsubscribe" data-text0="Подписаться" data-text1="Отписаться" data-issubscribe="0" data-target="{"controller":"content","subject":"posts","params":{"filters":[{"field":"user_id","condition":"eq","value":"1"}]}}" title="" data-show_btn_title="1"> <b class="icon-bell"> <svg class="icms-svg-icon w-16" fill="currentColor"><use href="/templates/modern/images/icons/solid.svg#bell"></use></svg> </b> <b class="icon-bell-slash"> <svg class="icms-svg-icon w-16" fill="currentColor"><use href="/templates/modern/images/icons/solid.svg#bell-slash"></use></svg> </b> <span class="icms-subscriptions__label">Подписаться</span> </a> <span title="Подписчики" class="count-subscribers btn btn-responsive btn-outline-secondary position-relative ml-2" data-list_link="/subscriptions/list_subscribers/6a93750ef3eda550db86a7d1ccbd7107"> 0 </span> </div> <a class="avatar icms-user-avatar d-none d-lg-flex mr-3 peer_no_online" href="/users/1"> <span class="icms-profile-avatar__default avatar__inlist" style="background-color: rgba(184, 161, 142, .9); color: black;"><svg fill="currentColor" viewBox="0 0 28 21"><text x="50%" y="50%" dominant-baseline="central" text-anchor="middle">Д</text></svg></span> </a> <h1 class="d-flex align-items-center h2"> <span> <a href="/users/1" class="text-muted"> Денис Юрьевич </a> <span class="d-none d-lg-inline-block"> · Блог</span> </span> </h1> </div>
думаю это связано c ob_start(); но не знаю как поправить
* на гитхате не нашёл