Forums

problems with the_permalink (4 posts)

  1. mondayblues
    Member
    Posted 2 years ago #

    I'm terribly new with WordPress. I'm trying to modify the classic theme that comes with the installation. It got the index page up and running but whenever I click on the link (the_permalink) the page doesn't change instead it displays the full index page. However, the link shown already has the post id.

    Below is my sample code.

    <div id = "latest">
    <?php query_posts("category_name=latest"); ?>
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <div id="storytitle">
    <div class="day">
    <strong class="month">
    <?php the_time('M') ?><br />
    </strong>
    <?php the_time('j') ?>
    </div>
    <div class="maintitle">
    <div <?php post_class() ?> id="post-<?php the_ID(); ?>">
    <a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a>
    </div>
    </div>
    <br /><br />
    </div>
    <div class="storycontent">
    <div class="thumb"><img src="<?php echo get_post_meta($post->ID, "Thumbnail", true);?>" height="110" width="110"/></div>
    <?php the_excerpt(); ?>
    </div>
    <hr>
    <?php comments_template(); // Get wp-comments.php template ?>
    <?php endwhile; else: ?>
    <p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
    <?php endif; ?>
    </div>
  2. Chris_K
    Member
    Posted 2 years ago #

    Out of curiosity, if you change your Permalinks to the Default, does the link work?

    Do other links (categories, pages, etc) work with non-Default Permalinks?

  3. Dakosha
    Member
    Posted 1 year ago #

    Hi, I'm having the same problem.

    I'm using custom permalinks: /%postname%
    And when viewing a single post, the post title link is not like: http://www.something.com/?p=123, but it is just: http://www.something.com/

    I have checked it with default premalink setting, and it worked fine, but with custom I have this peoblem.

    Please help.

    D.

  4. Samuel B
    moderator
    Posted 1 year ago #

    Dakosha

    linux or windows server?
    can you supply a link?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.