WordPress.org

Ready to get started?Download WordPress

Forums

Question and Answer Forum
Blog actual authors URLs changed when using this plugin (2 posts)

  1. tipsninja
    Member
    Posted 1 year ago #

    Hello. the plugin is great but there is one issue.
    I have installed it and posted few demo questions and answers but what i see is, it is not posting URL for authors posts correctly.
    It has changed the authors URL to 'questions asked by author' page.

    For example:
    at following page
    http://www.tipsninja.com/transfer-epub-mobi-files-pc-to-iphone-ipad/
    author url should be:
    http://www.tipsninja.com/author/tips-ninja/
    and not the
    http://www.tipsninja.com/question-users/master-ninja-2/
    tips-ninja is admin of site who has published articles at site.

    The regular blog authors have different urls for their posts and users who have posted questions should have different urls for their page where all their questions should be listed. Not being this case, plugin changes URLs for blog users, but question users don't show URLs for their page...just the name and that name i have implemented using code if post_type==question then show the_author() -- something like that...

    http://wordpress.org/extend/plugins/question-and-answer-forum/

  2. tipsninja
    Member
    Posted 1 year ago #

    Single post author code:

    <?php if (option::get('post_author') == 'on') { ?>
    <div class="post_author">
    <?php echo get_avatar( get_the_author_meta('ID'), 70 ); ?>
    <span><?php _e('Author:', 'wpzoom'); ?> 
    
    <?php
    // custom script for retrieving question author name -- i added
    // get post type
    $gpt=get_post_type($post->ID);
    if ($gpt=="question")
    {
    the_author();
    }
    // end of my editing
    ?>
    <?php the_author_posts_link(); ?></span>
    <?php the_author_meta('description'); ?>
    <?php } ?>

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic