[wp-testers] Custom Post Types single.php not working
Paul Robinson
pablorobinson at gmail.com
Mon Apr 12 18:37:17 UTC 2010
I don't want to be seen as hijacking a thread or anything, but I was
wondering. In the final version of 3.0 will permalinks be
automatically rebuilt when adding a post type or will we still have to
go settings -> permalinks like we do now? Not that it's much of a
problem, just wondering is all. :)
On 12 April 2010 19:33, Michael Van Winkle <mike at mikevanwinkle.com> wrote:
> I've been troubleshooting this on my own sites and have found there are at
> least two different erros that can cause the problem.
>
> First, make sure the "rewrite" parameter in the register_post_type()
> function is set up properly. It should be 'rewrite' => array('slug' = 'YOUR
> POST TYPE'). I found that using the custom post type UI plugin to set up
> your post type can be buggy regarding the rewrite setup. In one instance it
> kept setting the rewrite to "false" even though I was setting the plugin
> controls to true. I'm finding that registering the post type manually via
> functions.php is a much more reliable method right now.
>
> Second, if the slug for your post type is being used by a category (or maybe
> even a page) you'll get a 404 when you go to your single.php page. You'll
> need to change the slug for your category and the REBUILD your permalinks.
>
> Hope this helps.
>
> Cheers,
>
> Mike Van Winkle
>
> On Mon, Apr 12, 2010 at 12:16 PM, Jimmy Roy <jimmy.roy at gmail.com> wrote:
>
>> hi guys,
>> I haven't any answer for this problem but I'm interesting to know if you
>> know a tutorial about how to use custom type, I already know how to create
>> it, now it's the second step, how to display it.
>>
>> thanks for your help
>>
>> Jimmy
>>
>>
>> 2010/4/11 Brad Williams <brad at webdevstudios.com>
>>
>> > Mike - I would love to hear exactly what you did that caused an issue w/
>> > Custom Post Type UI. Any info you can provide will help me track down
>> bugs
>> > if they exist. Feel free to email me directly, thanks!
>> >
>> > -Brad
>> > @williamsba
>> >
>> > -----Original Message-----
>> > From: wp-testers-bounces at lists.automattic.com
>> > [mailto:wp-testers-bounces at lists.automattic.com] On Behalf Of Michael
>> Van
>> > Winkle
>> > Sent: Saturday, April 10, 2010 4:51 PM
>> > To: wp-testers at lists.automattic.com
>> > Subject: Re: [wp-testers] Custom Post Types single.php not working
>> >
>> > I encountered a similar problem but it turned out to be the Custom Post
>> > Type
>> > UI plugin (which is stil BETA of course). Once I abandoned the plugin and
>> > registered manually using my functions.php I didn't seem to have any
>> > problems. Just FYI.
>> >
>> > Mike
>> >
>> > On Sat, Apr 10, 2010 at 10:29 AM, scribu <scribu at gmail.com> wrote:
>> >
>> > > I think it might be a problem with your theme. Are you calling
>> > > query_posts()
>> > > or doing something with $post?
>> > >
>> > > Try disabling all plugins and using the default theme.
>> > >
>> > >
>> > > --
>> > > http://scribu.net
>> > > _______________________________________________
>> > > wp-testers mailing list
>> > > wp-testers at lists.automattic.com
>> > > http://lists.automattic.com/mailman/listinfo/wp-testers
>> > >
>> >
>> >
>> >
>> > --
>> > Michael Van Winkle
>> > Foundation for Economic Education
>> > 30 S Broadway
>> > Irvington, NY 10533
>> > 708-289-3136
>> > mvanwinkle at fee.org
>> > http://www.twitter.com/mpvanwinkle
>> > http://www.facebook.com/mpvanwinkle
>> >
>> >
>> > "All excellent things are as difficult as they are rare." -Spinoza
>> > _______________________________________________
>> > wp-testers mailing list
>> > wp-testers at lists.automattic.com
>> > http://lists.automattic.com/mailman/listinfo/wp-testers
>> >
>> > _______________________________________________
>> > wp-testers mailing list
>> > wp-testers at lists.automattic.com
>> > http://lists.automattic.com/mailman/listinfo/wp-testers
>> >
>> _______________________________________________
>> wp-testers mailing list
>> wp-testers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-testers
>>
>
>
>
> --
> Michael Van Winkle
> Foundation for Economic Education
> 30 S Broadway
> Irvington, NY 10533
> 708-289-3136
> mvanwinkle at fee.org
> http://www.twitter.com/mpvanwinkle
> http://www.facebook.com/mpvanwinkle
>
>
> "All excellent things are as difficult as they are rare." -Spinoza
> _______________________________________________
> wp-testers mailing list
> wp-testers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-testers
>
More information about the wp-testers
mailing list