HEX
Server: LiteSpeed
System: Linux prometheus.hongkongserver.net 4.18.0-553.134.1.el8_10.x86_64 #1 SMP Tue Jun 16 16:05:57 EDT 2026 x86_64
User: ayxmplky (1112)
PHP: 8.1.34
Disabled: NONE
Upload Files
File: /home/ayxmplky/public_html/wp-content/themes/tactic/footer.php
<?php
/**
 * Подвал сайта
 *
 * @package tactic
 */

$icp           = get_theme_mod( 'tactic_icp_number', '' );
$address_cn    = get_theme_mod( 'tactic_address_cn', '圣彼得堡, Staroderevenskaya 大街, 11号, 2号楼' );
$address_en    = get_theme_mod( 'tactic_address_en', 'St. Petersburg, Staroderevenskaya St., 11, Bldg 2' );
$email_eu      = get_theme_mod( 'tactic_email_eu', '' );
$email_global  = get_theme_mod( 'tactic_email_global', '' );
$phone         = get_theme_mod( 'tactic_phone', '' );
$instagram_url = get_theme_mod( 'tactic_instagram_url', '' );
$wechat_url    = get_theme_mod( 'tactic_wechat_url', '' );
$linkedin_url  = get_theme_mod( 'tactic_linkedin_url', '' );
$qr_id         = absint( get_theme_mod( 'tactic_wechat_qr_id', 0 ) );
$db_id         = absint( get_theme_mod( 'tactic_db_badge_id', 0 ) );
$credit        = get_theme_mod( 'tactic_footer_credit', '' );

$is_cn   = tactic_current_lang() !== 'en';
$address = $is_cn ? $address_cn : $address_en;

// Фоновая картинка для всей нижней части (баннер + футер)
$_front_id_bg = (int) get_option( 'page_on_front' );
$_ls_bg_id    = $_front_id_bg ? (int) get_post_meta( $_front_id_bg, '_landscape_bg_id', true ) : 0;
$_ls_bg_url   = $_ls_bg_id ? wp_get_attachment_image_url( $_ls_bg_id, 'full' ) : '';
?>

	<?php if ( is_front_page() && $_ls_bg_url ) : ?>
	<div class="page-bottom-wrap" style="background-image: url('<?php echo esc_url( $_ls_bg_url ); ?>')">
	<?php endif; ?>

	<?php if ( is_front_page() ) : ?>
		<?php get_template_part( 'template-parts/home/landscape-banner' ); ?>
	<?php endif; ?>

	<footer class="site-footer" role="contentinfo">
		<div class="footer__main">
			<div class="container footer__grid">

				<!-- Колонка 1: Логотип + Charger бейдж -->
				<div class="footer__col footer__col--brand">
					<a href="<?php echo esc_url( home_url( '/' ) ); ?>" class="footer__logo" aria-label="<?php bloginfo( 'name' ); ?>">
						<?php
						if ( has_custom_logo() ) {
							the_custom_logo();
						} else {
							echo '<span class="footer__logo-text">' . esc_html( get_bloginfo( 'name' ) ) . '</span>';
						}
						?>
					</a>
				<a href="https://chargerstudio.com/" class="footer__charger-badge" target="_blank" rel="noopener noreferrer" aria-label="<?php echo esc_attr( tactic_s( 'footer_charger_aria' ) ); ?>">
					<img src="<?php echo esc_url( get_template_directory_uri() ); ?>/assets/images/charger-badge.png" alt="<?php echo esc_attr( tactic_s( 'footer_charger_alt' ) ); ?>" class="footer__charger-img">
				</a>
				</div>

				<!-- Колонка 2: Контакты -->
				<div class="footer__col footer__col--contacts">
					<h4 class="footer__heading"><?php echo esc_html( tactic_s( 'footer_contacts' ) ); ?></h4>
					<?php if ( $address ) : ?>
						<address class="footer__address"><?php echo esc_html( $address ); ?></address>
					<?php endif; ?>
<!-- 
					<?php if ( $email_eu ) : ?>
						<span class="footer__label"><?php echo esc_html( tactic_s( 'footer_email_eu' ) ); ?></span>
						<a href="mailto:<?php echo esc_attr( sanitize_email( $email_eu ) ); ?>" class="footer__link">
							<?php echo esc_html( $email_eu ); ?>
						</a>
					<?php endif; ?>

					<?php if ( $email_global ) : ?>
						<span class="footer__label"><?php echo esc_html( tactic_s( 'footer_email_global' ) ); ?></span>
						<a href="mailto:<?php echo esc_attr( sanitize_email( $email_global ) ); ?>" class="footer__link">
							<?php echo esc_html( $email_global ); ?>
						</a>
					<?php endif; ?>

					<?php if ( $phone ) : ?>
						<a href="tel:<?php echo esc_attr( preg_replace( '/[^\d+]/', '', $phone ) ); ?>" class="footer__link footer__phone">
							<?php echo esc_html( $phone ); ?>
						</a>
					<?php endif; ?> -->
				</div>

				<!-- Колонка 3: Соцсети (скрыто) -->
				<div class="footer__col footer__col--social footer__col--social--hidden" aria-hidden="true">
					<a href="<?php echo $instagram_url ? esc_url( $instagram_url ) : '#'; ?>" class="footer__social-link"<?php echo $instagram_url ? ' target="_blank" rel="noopener noreferrer"' : ''; ?> aria-label="<?php echo esc_attr( tactic_s( 'footer_instagram_aria' ) ); ?>">
						<?php echo tactic_icon_instagram(); // phpcs:ignore WordPress.Security.EscapeOutput ?>
					</a>
					<a href="<?php echo $wechat_url ? esc_url( $wechat_url ) : '#'; ?>" class="footer__social-link"<?php echo $wechat_url ? ' target="_blank" rel="noopener noreferrer"' : ''; ?> aria-label="<?php echo esc_attr( tactic_s( 'footer_wechat_aria' ) ); ?>">
						<?php echo tactic_icon_wechat(); // phpcs:ignore WordPress.Security.EscapeOutput ?>
					</a>
					<a href="<?php echo $linkedin_url ? esc_url( $linkedin_url ) : '#'; ?>" class="footer__social-link"<?php echo $linkedin_url ? ' target="_blank" rel="noopener noreferrer"' : ''; ?> aria-label="<?php echo esc_attr( tactic_s( 'footer_linkedin_aria' ) ); ?>">
						<?php echo tactic_icon_linkedin(); // phpcs:ignore WordPress.Security.EscapeOutput ?>
					</a>
				</div>

				<!-- Колонка 4: QR-код -->
				<div class="footer__col footer__col--qr">
					<?php
					if ( $qr_id ) :
						echo wp_get_attachment_image(
							$qr_id,
							[ 110, 110 ],
							false,
							[
								'class' => 'footer__qr-img',
								'style' => 'display:block;background:#fff;padding:6px;border-radius:4px;',
								'alt'   => esc_attr( tactic_s( 'footer_qr_alt' ) ),
							]
						);
					elseif ( file_exists( get_template_directory() . '/assets/images/qr-wechat.png' ) ) :
						?>
						<img
							src="<?php echo esc_url( get_template_directory_uri() . '/assets/images/qr-wechat.png' ); ?>"
							class="footer__qr-img"
							style="display:block;background:#fff;padding:6px;border-radius:4px;"
							width="110" height="110"
							alt="<?php echo esc_attr( tactic_s( 'footer_qr_alt' ) ); ?>">
					<?php endif; ?>
				</div>

				<!-- Колонка 5: D&B бейдж -->
				<div class="footer__col footer__col--db">
					<?php
					$db_url = $db_id ? wp_get_attachment_image_url( $db_id, 'full' ) : '';
					if ( $db_url || file_exists( get_template_directory() . '/assets/images/db-badge.png' ) ) :
						$db_src = $db_url ?: get_template_directory_uri() . '/assets/images/db-badge.png';
						?>
						<div class="footer__db-badge">
							<a href="https://www.dnb.com/" target="_blank" rel="noopener noreferrer" aria-label="<?php echo esc_attr( tactic_s( 'footer_dnb_aria' ) ); ?>">
								<img src="<?php echo esc_url( $db_src ); ?>" alt="<?php echo esc_attr( tactic_s( 'footer_dnb_alt' ) ); ?>" width="110" height="auto">
							</a>
						</div>
					<?php endif; ?>
				</div>

			</div><!-- .footer__grid -->
		</div><!-- .footer__main -->

		<!-- ICP-лицензия (обязательно для сайтов в Китае) -->
		<?php if ( $icp ) : ?>
			<div class="footer__icp">
				<div class="container">
					<a href="https://beian.miit.gov.cn/" target="_blank" rel="noopener noreferrer">
						<?php echo esc_html( $icp ); ?>
					</a>
				</div>
			</div>
		<?php endif; ?>

	</footer>

	<?php if ( is_front_page() && $_ls_bg_url ) : ?>
	</div><!-- .page-bottom-wrap -->
	<?php endif; ?>

<?php wp_footer(); ?>
</body>
</html>