WordPress.org

Forums

[resolved] How to remove links to previous/next posts? (13 posts)

  1. deko
    Member
    Posted 9 years ago #

    I'm using WordPress 2.02 with the default theme and want to prevent the appearance of links to the previous/next post (located to the top left and right of the post title).

    I tried commenting these two lines from index.php, but no luck:

    <div class="navigation">
    <div class="alignleft"><?php //next_posts_link('« Previous Entries') ?></div>
    <div class="alignright"><?php //previous_posts_link('Next Entries »') ?></div>
    </div>

    What file should I modify? What code am I looking for?

    Thanks in advance.

  2. Chris_K
    Member
    Posted 9 years ago #

    Those are the ones you're after. Is ther a set at top and another set at bottom? maybe you commented out one but not the other?

  3. deko
    Member
    Posted 9 years ago #

    Yeah, you would think. I tried sticking some text in that div - it did not print. Apparently that code is used here ?

    still troubleshooting...

  4. boogszilla
    Member
    Posted 9 years ago #

    hi, this reply is really a call for help: how do I create a new post? Obviously I can get to the posts and reply as I am doing now, but I can't see anywhere on the page to create a new topic?

  5. moshu
    Member
    Posted 9 years ago #

    @deko: Look in the single.php if you after those links that display the title of the next and prev post.

    @boogszilla: on the main page of the forum scroll down and select the section that fits your question. Click and scroll down again, until you see the form.

  6. boogszilla
    Member
    Posted 9 years ago #

    thnx!

  7. deko
    Member
    Posted 9 years ago #

    Yes, I found the next_posts_link/previous_posts_link there as well - I commented them out - no luck. This is weird. I'm thinking there is a cache issue? How to clear cache?

  8. moshu
    Member
    Posted 9 years ago #

    Might be. Delete everything from the cache folder under wp-content.

  9. deko
    Member
    Posted 9 years ago #

    I don't see a cache folder in wp-content - at least it does not appear in Dreamweaver remote view... logging into hoting provider's Control Panel now... will see if I can see it in file manager...

  10. deko
    Member
    Posted 9 years ago #

    hmmm... no cache folder there either. strange. I do see a cache folder on my testing server, however (does not appear in DW). You would think there would be a way to clear cache from the WP admin interface.

  11. deko
    Member
    Posted 9 years ago #

    Okay - code edits are working as desired now. It must have been a caching issue. I deleted code from both index.php and single.php to purposely create an error - NOTHING HAPPENED! The page served up as before.

    That cache sucks. Is there anyway to delete it without logging into my host's control panel and looking for it in file manager? There should be.

  12. moshu
    Member
    Posted 9 years ago #

    You can disable it - but you can delete it only via FTP.

    You can disable caching (temporarily or permanently) by adding this line to your wp-config.php

    define('DISABLE_CACHE', true);

  13. deko
    Member
    Posted 9 years ago #

    10-4. I'm going to disable it until I am done customizing. Let's hope there's an on/off button in the admin interface in the next release.

    Thanks for the help.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags