WordPress.org

Ready to get started?Download WordPress

Forums

register_taxonomy and permalinks, white screen of death (3 posts)

  1. dennissmolek
    Member
    Posted 2 years ago #

    I am doing a project using custom post types and was 80% through when I started messing with the permalinks.

    Normally I just have to turn them on and I'm pretty good, some slight tweaks.

    But when I switched permalink structures I got white screened and had no idea what caused it.
    I upped my memory, did some other things, then renamed my plugin folder.
    This fixed the issue.
    I narrowed it down to my plugin, and then do this specific call:

    register_taxonomy('attributes',array (
      0 => 'girls',1 => 'food',2 => 'elements',3 => 'templates',
    ),array( 'hierarchical' => false, 'label' => 'Attributes','show_ui' => true,'query_var' => true,'rewrite' => array('slug' => ''),'singular_label' => 'Attribute') );

    Now admittedly I haven't done much with changing permalink structure in the past, nor with custom Tax's. But I can't seem to find any info on whats causing the crash.

  2. dennissmolek
    Member
    Posted 2 years ago #

    One fix, removing the rewrite argument all together fixes, and defaults to true which is fine by me.
    Then I flushed the rules..

    Still a odd problem that I'll have to get to later for sure.

    EDIT: Nope, still broken on any version of permalinks besides default.

  3. AdrianLiem
    Member
    Posted 2 years ago #

    Did you use the init action to call register_taxonomy()? That may be the problem.

    It may also be related to flushing rewrite. I experienced the white screen of death after trying to register a new post type, and in tat case I simply missed the part about Flushing Rewrite on Activation: http://codex.wordpress.org/Function_Reference/register_post_type#Flushing_Rewrite_on_Activation

Topic Closed

This topic has been closed to new replies.

About this Topic