Forums

[resolved] Author Template- posts do not link correctly (3 posts)

  1. oste15
    Member
    Posted 3 years ago #

    I followed this http://wphacks.com/how-to-adding-an-author-page-to-your-wordpress-blog/ tutorial to make an authors page.

    You can see what I have at http://www.aquaculturetalk.com/author/admin/

    The problem is when you click on a post link, you get a 404 error.

    This is the code directly from my author.php page. Any help to fix this will be greatly appreciated.

    <?php get_header(); ?>
    <div class="apost">
    <div class="head">

    </div>
    <div class="content">
    <div id="content" class="narrowcolumn">
    <!-- This sets the $curauth variable -->
    <?php
    if(isset($_GET['author_name'])) :
    $curauth = get_userdatabylogin($author_name);
    else :
    $curauth = get_userdata(intval($author));
    endif;
    ?>
    <h3>About: <?php echo $curauth->display_name; ?></h3>
    <p>Website: user_url; ?>”><?php echo $curauth->user_url; ?></p>
    <p>Profile: <?php echo $curauth->user_description; ?></p>
    <h3>Posts by <?php echo $curauth->display_name; ?>:</h3>

    </div>
    </div>
    <ul class="foot">
    </div>
    <?php get_sidebar(); ?>
    <?php get_footer(); ?>

  2. MichaelH
    Volunteer
    Posted 3 years ago #

    The post link from wp-content/themes/default/index.php is coded as:
    <h2><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>

    Other resource
    Creating_an_Archive_Index
    Template_Hierarchy

  3. oste15
    Member
    Posted 3 years ago #

    ok I got that to work, Thanks for the help.

    One other small issue. CAn you show me how to fix the profile text so that it doesnt get so close to the sidebar.

    I am guessing I need to make that a div but I am not sure how to do that.

    Again I am new to this, so any help is greatly appreciated.

Topic Closed

This topic has been closed to new replies.

About this Topic