Author page redirects to blog homepage
-
Hello! I’ve been searching around in the forums and on Google for an answer to this, but I haven’t found one, so here goes.
I am having problems display an Author page. When a user clicks on an author name link that I generated using
<?php the_author_posts_link(); ?>
it takes them straight back to the homepage.I do have an author.php in my template directory, the code for the author page is`<?php get_header(); ?>
<div id=”main”>
<div id=”main-inner”>
<div id=”page-post”>
<div id=”page-post-header”><h2 class=”page-title”><?php the_title(); ?></h2></div>
<div class=”pad”><!– This sets the $curauth variable –>
<?php
if(isset($_GET[‘author_name’])) :
$curauth = get_userdatabylogin($author_name);
else :
$curauth = get_userdata(intval($author));
endif;
?><h2>About: <?php echo $curauth->nickname; ?></h2>
<dl>
<dt>Website</dt>
<dd>user_url; ?>”><?php echo $curauth->user_url; ?></dd>
<dt>Profile</dt>
<dd><?php echo $curauth->user_description; ?></dd>
</dl><h2>Posts by <?php echo $curauth->nickname; ?>:</h2>
-
<!– The Loop –>
-
” rel=”bookmark” title=”Permanent Link: <?php the_title(); ?>”>
<?php the_title(); ?>,
<?php the_time(‘d M Y’); ?> in <?php the_category(‘&’);?>
<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?><?php endwhile; else: ?>
<p><?php _e(‘No posts by this author.’); ?></p><?php endif; ?>
<!– End Loop –></div>
</div>
<?php include (‘sidebar-ads.php’); ?>
</div>
<?php get_sidebar(); ?></div>
</div>
<?php get_footer(); ?>
`I’d like to troubleshoot this issue, if anyone could help, I’d really appreciate.
Here is a link to a post on my site with the author link being under the post title:Link to post
-
” rel=”bookmark” title=”Permanent Link: <?php the_title(); ?>”>
- The topic ‘Author page redirects to blog homepage’ is closed to new replies.