Underscores Menu not responding on mobile
-
I’m new to creating themes and I’ve recently started work on my first Underscores theme.
Everything seemed to be going well, but then I realized that the post pages and archive pages aren’t responding well on mobile.
Here is the single.php code
<?php /** * The template for displaying all single posts * * @link https://developer.www.ads-software.com/themes/basics/template- hierarchy/#single-post * * @package Elesha */ get_header(); ?> <div id="primary" class="content-area"> <main id="main" class="site-main" role="main"> <?php while ( have_posts() ) : the_post(); get_template_part( 'template-parts/content', get_post_format() ); the_post_navigation(); // If comments are open or we have at least one comment, load up the comment template. if ( comments_open() || get_comments_number() ) : comments_template(); endif; endwhile; // End of the loop. ?> </main><!-- #main --> <?php get_sidebar(); get_footer();
and here is the content.php code
<?php /** * Template part for displaying posts * * @link https://codex.www.ads-software.com/Template_Hierarchy * * @package Elesha */ ?> <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> <header class="entry-header"> <?php if ( is_single() ) : the_title( '<h1 class="entry-title">', '</h1>' ); else : the_title( '<h2 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h2>' ); endif; if ( 'post' === get_post_type() ) : ?> <div class="entry-meta"> <?php elesha_posted_on(); ?> </div><!-- .entry-meta --> <?php endif; ?> </header><!-- .entry-header --> <div class="entry-content"> <?php the_content( sprintf( /* translators: %s: Name of current post. */ wp_kses( __( 'Continue reading %s <span class="meta-nav">→ </span>', 'elesha' ), array( 'span' => array( 'class' => array() ) ) ), the_title( '<span class="screen-reader-text">"', '"</span>', false ) ) ); wp_link_pages( array( 'before' => '<div class="page-links">' . esc_html__( 'Pages:', 'elesha' ), 'after' => '</div>', ) ); ?> </div><!-- .entry-content --> <footer class="entry-footer"> <?php elesha_entry_footer(); ?> </footer><!-- .entry-footer -->
I honestly don’t know what’s wrong here.
- The topic ‘Underscores Menu not responding on mobile’ is closed to new replies.