no page titles
-
How do i disable the page title being listed on the page?
Thanks
Natalie
Viewing 1 replies (of 1 total)
-
Sorry. I didn’t see this support question when you first posted it.
Here is a replacement for the index.php file in the theme, which will remove the main page titles for you. I haven’t tested this, but I can’t see any reason why it wouldn’t work. If you experience any problems, then please let me know and I’ll take a closer look for you ??
<?php /** * Modified main template file with no headings * * @package Hellish Simplicity * @since Hellish Simplicity 1.1 */ get_header(); ?> <div id="content-area"> <div id="site-content" role="main"><?php // Load main loop if ( have_posts() ) { // Start of the Loop while ( have_posts() ) { the_post(); ?> <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> <div class="entry-content"><?php /* * Display full content for home page and single post pages */ if ( is_home() || is_single() || is_page() ) { the_content( __( 'Continue reading <span class="meta-nav">→</span>', 'hellish' ) ); wp_link_pages( array( 'before' => '<div class="page-links">' . __( 'Pages:', 'hellish' ), 'after' => '</div>' ) ); } else { // Use the built in thumbnail system, otherwise attempt to display the latest attachment if ( has_post_thumbnail() ) { the_post_thumbnail( 'excerpt-thumb' ); } else { $args = array( 'post_type' => 'attachment', 'post_mime_type' => 'image', 'post_parent' => get_the_ID(), 'numberposts' => 1, ); $images = get_posts( $args ); foreach( $images as $image ) { echo wp_get_attachment_image( $image->ID, 'excerpt-thumb' ); } } the_excerpt(); } ?> </div><!-- .entry-content --><?php // Don't display meta information on static pages if ( ! is_page() ) { ?> <footer class="entry-meta"> <?php printf( __( 'Posted on <a href="%1$s" title="%2$s" rel="bookmark"><time class="entry-date" datetime="%3$s">%4$s</time></a><span class="byline"> by <span class="author vcard"><a class="url fn n" href="%5$s" title="%6$s" rel="author">%7$s</a></span></span>', 'hellish' ), esc_url( get_permalink() ), esc_attr( get_the_time() ), esc_attr( get_the_date( 'c' ) ), esc_html( get_the_date() ), esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ), esc_attr( sprintf( __( 'View all posts by %s', 'hellish' ), get_the_author() ) ), get_the_author() ); // Category listings $categories_list = get_the_category_list( __( ', ', 'hellish' ) ); if ( $categories_list ) { ?> <span class="cat-links"> <?php printf( __( ' in %1$s', 'hellish' ), $categories_list ); ?> </span><?php } // Tag listings $tags_list = get_the_tag_list( '', __( ', ', 'hellish' ) ); if ( $tags_list ) { ?> <span class="sep"> | </span> <span class="tags-links"> <?php printf( __( 'Tagged %1$s', 'hellish' ), $tags_list ); ?> </span><?php } // Comments info. if ( ! post_password_required() && ( comments_open() || '0' != get_comments_number() ) ) { ?> <span class="sep"> | </span> <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'hellish' ), __( '1 Comment', 'hellish' ), __( '% Comments', 'hellish' ) ); ?></span><?php } // Edit link edit_post_link( __( 'Edit', 'hellish' ), '<span class="sep"> | </span><span class="edit-link">', '</span>' ); ?> </footer><!-- .entry-meta --><?php } ?> </article><!-- #post-<?php the_ID(); ?> --><?php // If comments are open or we have at least one comment, load up the comment template if ( comments_open() || '0' != get_comments_number() ) comments_template( '', true ); } get_template_part( 'template-parts/numeric-pagination' ); } else { get_template_part( 'template-parts/no-results' ); } ?> </div><!-- #site-content --> <?php get_sidebar(); ?> </div><!-- #content-area --> <?php get_footer(); ?>
If anyone is reading this a long time in the future, then be aware that this was done for version 1.6.3 of the Hellish Simplicity.
Viewing 1 replies (of 1 total)
- The topic ‘no page titles’ is closed to new replies.