WordPress.org

Ready to get started?Download WordPress

Forums

remove link attribute from H2 entry title- TwentyTen theme (3 posts)

  1. webguync
    Member
    Posted 2 years ago #

    I have a child theme based off of the TwentyTen theme. I want to remove the entry title link and just make it a static h2. I know I need to remove the <a href="">h2</a> in one of the files, but wasn't sure which one or where. This is the entry title that appears above a post.

    [Please post code or markup snippets between backticks or use the code button.]

  2. alchymyth
    The Sweeper & Moderator
    Posted 2 years ago #

    have a look into content.php which generates the output for the main index page and the archives:

    <?php if ( is_sticky() ) : ?>
    				<hgroup>
    					<h2 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyeleven' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h2>
    					<h3 class="entry-format"><?php _e( 'Featured', 'twentyeleven' ); ?></h3>
    				</hgroup>
    			<?php else : ?>
    			<h1 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyeleven' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h1>
    			<?php endif; ?>

    considering this is the link that links to the single posts, how are you planning to reach the single posts after the link is removed?

  3. webguync
    Member
    Posted 2 years ago #

    thanks. There will only be one post. I may leave it in, but wanted to know how to remove if needed.

Topic Closed

This topic has been closed to new replies.

About this Topic