WordPress.org

Ready to get started?Download WordPress

Forums

archive-{posttype}.php (9 posts)

  1. Karthuizer
    Member
    Posted 2 years ago #

  2. marv51
    Member
    Posted 2 years ago #

    If you have the same problem, then the solution you linked to should work for you ;-) this problem was fixed, so can you describe what is not working for you?

  3. Karthuizer
    Member
    Posted 2 years ago #

    I don't know, why its not working.
    The 'has_archive' is set to true.
    I have a archive.php and a archive-kattenrassen.php
    I' trying to link to the archive-kattenrassen.php with the get_the_term_list(), or is there a other why to link to the archive-kattenrassen.php ??
    My permalink is set to the Default.

    [ Please do not bump, it's not permitted here. ]

  4. marv51
    Member
    Posted 2 years ago #

    Did you refresh the permalinks? E.g. Hit save on the permalinks page?

  5. Karthuizer
    Member
    Posted 2 years ago #

    Hi, my permalinks are on the default settings is this ok?

  6. marv51
    Member
    Posted 2 years ago #

    I've never trieed 'default', but in any case to refresh the permalinks, you have to save the permalinks page, it does't matter if you change anything.
    I assume you've read this: http://codex.wordpress.org/Post_Types#URLs_with_Namespaced_Custom_Post_Types and http://codex.wordpress.org/Post_Types#Single_template (esp. the note!)

  7. Tirumal
    Member
    Posted 2 years ago #

    Try giving 755 permission to .htaccess file in your http(s)docs directory and save the permalinks settings again.

    Hope this works for you.

    (To change permission open ftp, right click on file and select change permission on FileZilla.)

  8. Karthuizer
    Member
    Posted 2 years ago #

    Nope, it's not working :(
    I'm trying to load my archive-$posttype.php page with the get_the_term_list() function is the right way to do it?
    (I'm on my single-$posttype.php page).

  9. marv51
    Member
    Posted 2 years ago #

    Don't really know what you are doing. The single-$posttype.php doesn't get loaded if your archive page is loaded. (see: http://codex.wordpress.org/Template_Hierarchy)
    What I do to debug this kind of problem is put a die("Test"); in the archive-$posttype file and try wordpress to load that page. So if it is loaded you know for sure.
    Going to http://example.com/$posttype/ should propably show your archive page. If not, try to resave your permalinks, also check that browser cache is not a problem. Try a different browser, maybe in privat browsing mode to confirm it's not a cache issue.
    If that's not working maybe changing the permalink structure is a good idea, too.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.