Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress How to Make a Website with WordPress Custom Post Types and Fields in WordPress Setting Up Custom Post Types and Fields

Jonathan Grieve
MOD
Jonathan Grieve
Treehouse Moderator 91,253 Points

URL of Art Custom Post Types in Wordpress

Hi all,

So i've set up the Art Custom Post Type and Advanced Custom fields which seems to work correctly.

There is a problem however.

I'm not sure how to link it to the Main Menu in the 2013 child theme. So I can only get to the page from the Admin area. Here's link to the page.

http://www.jonniegrieve.co.uk/wordpress-jonniegrieve.co.uk/art/example-1-3/

Now, what I'd rather have is for it to say example-1 in the link so if I was to create the other 3 Art pages, they'd link together properly. But instead i saw somethink like this happening.

http://www.jonniegrieve.co.uk/wordpress-jonniegrieve.co.uk/art/example-1 http://www.jonniegrieve.co.uk/wordpress-jonniegrieve.co.uk/art/example-1/example-2 http://www.jonniegrieve.co.uk/wordpress-jonniegrieve.co.uk/art/example-1/example-3 http://www.jonniegrieve.co.uk/wordpress-jonniegrieve.co.uk/art/example-1/example-4

This would get a 404 I'd imagine it does this because they still exist somewhere on the server but I can't find where to delete them. How can I reset things to start again?

1 Answer

Stanley Thijssen
Stanley Thijssen
22,831 Points

Have you tryed to change your permalink to default and save it, then change it back to post name and save it again? This will reset these kind of problems most of the time. Let me know if it worked or not:)

Jonathan Grieve
Jonathan Grieve
Treehouse Moderator 91,253 Points

I've looked again and i can't how to change the permalink :)

Jonathan Grieve
Jonathan Grieve
Treehouse Moderator 91,253 Points

Turns out what was causing all of this was not deleting pages and posts and fields from the bin, so links were automatically redirecting. Page is much better now, thank you. :-)