466 reputation
38
bio website rachelcarden.com
location Alabama
age 29
visits member for 2 years, 6 months
seen Sep 19 at 17:55

I'm a High Ed Web Developer, with a fondness for WordPress, who loves puzzles and gets way too excited about programming and problem solving.

I like to tweet about all kinds of stuff, but mostly WordPress, Higher Ed Web, and all things Disney and Alabama football.

I have a WordPress plugin that I'm rather fond of.

And a blog, too.


Jul
11
comment Make a custom column sortable, by custom post count
Awesome! Glad to help!
Jul
3
answered Make a custom column sortable, by custom post count
May
16
answered Add Post Screen Keep Category structure
Mar
10
awarded  Yearling
Sep
16
awarded  Nice Answer
Aug
26
awarded  Commentator
Aug
26
comment Custom Post Type Slug / Page Slug Conflict - Prevent use of reserved slug on page save?
I answered your question. :)
Aug
26
answered Is slug “type” reserved and can't be used in taxonomy rewrite?
May
29
comment Nested custom post types with permalinks
@Segfault You can use get_terms(), if you're using a CPT-onomy, or get_posts() to retrieve the post names/slugs.
May
29
comment Nested custom post types with permalinks
@Segfault You will have to retrieve all of the author slugs so you can hard code them into the rewrite rule(s): foreach( $author_slugs as $author_slug ) { add_rewrite_rule( '^authors/' . $author_slug . '/([^/]*)/([^/]*)/?','index.php?authors=' . $author_slug . '&chapters=$matches[2]','top' ); add_rewrite_rule( '^authors/' . $author_slug . '/([^/]*)/?','index.php?authors=' . $author_slug . '&books=$matches[1]','top' ); }
May
23
comment Archive page for custom post type not working
Do you have any other content in your site that might have a conflicting URL? Any pages with a slug/page name of 'case'?
Mar
22
awarded  Yearling
Mar
22
awarded  Necromancer
Feb
19
awarded  Supporter
Aug
14
comment Nested custom post types with permalinks
I have a feeling you might come across some obstacles as your "library" grows but I already have some code in mind so, if you do, just let me know.
Aug
14
answered Nested custom post types with permalinks
Aug
13
comment Nested custom post types with permalinks
I realized the confusion actually lies with the CPTs sharing 'author' as the base slug. Once you set 'author' as the slug for the CPT 'authors', and then you set 'author/%author%' for the CPT 'books' and 'author/%author%/%book%' for the CPT 'chapters', then WordPress thinks the posts for 'books' and the posts for 'chapters' are literally hierarchical children posts for 'authors'. Does that make sense? In my testing you could keep 'author' as the base for the CPT 'authors' and it works just fine. So replace my previous question with: do you need 'author' or can the slug start with %author%?
Aug
13
comment Nested custom post types with permalinks
I'm working on a solution but I have a quick question: is it key to have 'author' in front of each permalink? Because that seems to be the stickler. I think it's confusing WordPress a little too much, especially since that's a permalink slug also used for WP author pages. If having 'author' is required, I think the whole thing is still do-able... it will just be more complicated.
Apr
12
comment rewrite rules and querystring
print( get_query_var( 'photo_id' ) ); should work. Are you sure that your template is the one being used? A quick test of echo-ing some static text near the get_query_var() should do the trick.
Apr
12
revised rewrite rules and querystring
corrected the add_rewrite_rule() code