Mass escaping and singular placeholder fix according to the CS check.

This commit is contained in:
Frank419
2024-08-29 15:48:42 +08:00
parent 45e080cfba
commit 3cf6389db6
11 changed files with 65 additions and 66 deletions
+14 -14
View File
@@ -9,24 +9,24 @@ if ( !defined( 'WPINC' ) ) {
<?php
if( is_home() ) {
$sidebar = get_theme_mod( 'minimalistflex_layout_home_sidebar', 'right' );
$mf_sidebar = get_theme_mod( 'minimalistflex_layout_home_sidebar', 'right' );
} elseif ( is_front_page() ) {
$sidebar = get_theme_mod( 'minimalistflex_layout_front_sidebar', 'right' );
$mf_sidebar = get_theme_mod( 'minimalistflex_layout_front_sidebar', 'right' );
} elseif ( is_search() ) {
$sidebar = get_theme_mod( 'minimalistflex_layout_search_sidebar', 'right' );
$mf_sidebar = get_theme_mod( 'minimalistflex_layout_search_sidebar', 'right' );
} elseif ( is_archive() ) {
$sidebar = get_theme_mod( 'minimalistflex_layout_archive_sidebar', 'right' );
$mf_sidebar = get_theme_mod( 'minimalistflex_layout_archive_sidebar', 'right' );
} elseif( is_author() ) {
$sidebar = get_theme_mod( 'minimalistflex_layout_author_sidebar', 'right' );
$mf_sidebar = get_theme_mod( 'minimalistflex_layout_author_sidebar', 'right' );
} elseif( is_single() ) {
$sidebar = get_theme_mod( 'minimalistflex_layout_singular_sidebar', 'right' );
$mf_sidebar = get_theme_mod( 'minimalistflex_layout_singular_sidebar', 'right' );
} elseif( is_page() ) {
$sidebar = get_theme_mod( 'minimalistflex_layout_page_sidebar', 'right' );
$mf_sidebar = get_theme_mod( 'minimalistflex_layout_page_sidebar', 'right' );
}
?>
<?php if ( $sidebar <> 'no' ): ?>
<?php if ( $mf_sidebar <> 'no' ): ?>
<aside class="minimalistflex-sidebar">
<?php get_sidebar(); ?>
</aside>
@@ -42,13 +42,13 @@ if( is_home() ) {
<footer class="minimalistflex-footer">
<div class="minimalistflex-footer-widgets-container">
<?php $sidebars = get_theme_mod( 'minimalistflex_footer_widget_layout', 'one' ); ?>
<?php $mf_sidebars = get_theme_mod( 'minimalistflex_footer_widget_layout', 'one' ); ?>
<?php
get_sidebar( 'footer' );
if ( $sidebars === 'two' || $sidebars === 'three' ) {
if ( $mf_sidebars === 'two' || $mf_sidebars === 'three' ) {
get_sidebar( 'footer-2' );
}
if ( $sidebars === 'three' ) {
if ( $mf_sidebars === 'three' ) {
get_sidebar( 'footer-3' );
}
?>
@@ -67,11 +67,11 @@ if( is_home() ) {
</div>
<?php endif; ?>
<div class="footer-credits">
<?php $footer_type = get_theme_mod( 'minimalistflex_footer_type', 'both' ); ?>
<?php if ( $footer_type === 'both' || $footer_type === 'custom' ): ?>
<?php $mf_footer_type = get_theme_mod( 'minimalistflex_footer_type', 'both' ); ?>
<?php if ( $mf_footer_type === 'both' || $mf_footer_type === 'custom' ): ?>
<?php echo wp_kses_data( get_theme_mod( 'minimalistflex_footer_text' ) ) ?>
<?php endif; ?>
<?php if ( $footer_type === 'both' || $footer_type === 'minimalistflex' ): ?>
<?php if ( $mf_footer_type === 'both' || $mf_footer_type === 'minimalistflex' ): ?>
<?php
printf(
/* translators: %s: Link to theme author website. */