• Resolved samanime

    (@samanime)


    Hello,

    I’m trying to create a rewrite rule which will get a post matching a specific slug that is within a specific custom taxonomy. Any ideas?

    The reason I have to do this is because I have slugs which are the same (in different parts), but the parents are stripped out of the URL, so I have to use the custom taxonomy to differentiate them.

    Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter samanime

    (@samanime)

    So, I realized that I could change my rules around and hard-code in the parent.

    However, post_parent=123 doesn’t seem to be working. WP_Query just ignores it completely and I’m not sure why.

    Any help would be greatly appreciated.

    Thread Starter samanime

    (@samanime)

    So, instead of using:
    post_type=myposttype&name=mypage

    I ended up doing
    myposttype=parent/mypage

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Rewrite – Get Post in Category’ is closed to new replies.