In this lesson you'll import or create 30 posts in our custom post-time.
You'll organize lots of posts images categories and tags and make sure they display well within the
theme.
By the end you'll have the skills to set up custom post types for any website project no matter what
theme you've settled on with the client.
Let's go let's go and just take one more look at my sample site which is showing a single photograph
post in the custom post type called photographs.
So this one is Jake the dog.
It's got a little bit of copy and a full size photo inside of the single post and then below it's got
where the category which is our custom taxonomy called dogs.
And then whatever words that it's been tagged with back in the student's sandbox in the Wordpress dashboard
under the site that we've been working on with the cafe pro theme in the last video we enabled custom
press and we set up a content type called photographs and a custom taxonomy as well as some custom fields
let's create four posts in our photographs custom post type and let's create one post for each of the
four categories or photo types.
So under photographs click Add new and you can see over on the right.
We've already got four photo types that are available.
Let's start with dogs and just choose any name for your dog.
And now since these posts are already inside our photographs custom post hope and we've created those
post types taxonomies and custom fields.
You can see we've got all of our choices up here a tag system the photo types that I just mentioned
as well as below the content editing area a photograph information section which is our custom fields.
Here's a small challenge for you.
Create all four posts that are photographed custom posts and populate them with information.
Choose a camera.
Fill in a type of lens and choose a date using the date picker and over on the right hand side.
Choose two or three tags if you click the button choose from the most use tags you'll see the tags that
I have populated into the sandbox right here for you.
Choose one of the photo types for each of the four posts and then use the same image for the featured
image.
You'll see that there's 30 images here.
Some are landscapes some are dogs some are people and others are still life so you can choose a dog's
photo for the featured image for this particular one.
And lastly inside the body text area click Add media choose the same image that you did for the featured
image make it centered.
Use no you are l and let's make it the large size and click insert into post and now the cursor is right
below the image here or click enter once and then however you like put a little bit of copy down here.
You might go to Lipscombe dot org as I've instructed you before and grab maybe one sentence really of
Lorem Ipsum text to put inside the post to.
So I'll just grab one sentence here and click copy that will be a little bit of content below each of
our images.
And now we've got all the information that we need.
And you can click publish so pas the video now create all four posts one for each photo type and populate
them with images content and custom fields as word tags.
I didn't choose the tags for this one.
I think this is it's a dog I would call this summer.
Is that a dog sweater.
Sure.
That sounds fine and a quick update.
So come back after pausing the video and we'll see how you do it.
How did that go for you.
It should have been relatively straightforward.
If you open one of your four posts you created and open the permalink.
Let's take a look at one of our individual posts or right click and click Open link in new tab.
And as I open up that page you can see that I've got the title of full with image.
Some copy that I placed below.
Here's where we have the Filed under.
This is our category or our photo type and on the right are tags.
Let's take a look at the L slash photographs.
If you navigate to that this should give you a list of all of your photograph posts along with their
image and their text and filed under still live.
And here are the tags.
Great.
And as I go down I'm showing four items on a page and then I've got a pagination here via number and
I can go to the next page.
One thing I'm seeing that I want to change is that I'm showing this full with image and the text below.
And I'm just going to make a quick Genesis change and you can follow along and do this on your own sandbox
site under Genesis and theme settings.
I want to scroll down and I know the default layout is full with but I'd like to show in the content
archives when I list different posts in a list instead of showing the entry content.
I'd like to show an excerpt as well as the featured image and I think 300 for my medium is probably
a little bit small but let's take a look at it.
Image alignment left.
Great.
And let's go down and click save changes.
Now let's look at that photograph page again by refreshing and yeah I like it except I'd like this image
to fill up maybe half the screen or a little bit more pert perhaps so I'm going to change my thumbnails
to 600 pixel thumbnails.
Do you remember how to do that.
Here's a nice challenge for you.
Go back into settings and media settings and change your medium thumbnail size to 600 by 600 and then
use the regenerate thumbnails plug in to regenerate those thumbnails into the larger size puzzle video
now and give it a go.
How they go for you.
Well I mean settings media and I just need to change my Macs with to 600 by 600
and then I'll click save changes.
And the last step as I suggested use the regenerate thumbnails plug in and just regenerate all the thumbnails
that will create those 600 pixel wide images from the originals.
So we maintain quality instead of enlarging the 300 pixel size.
Great now that that's 100 percent finished it's open.
The photographs archive again and take a look at our 600 pixel white images.
Nice So we're listing for posts and then we can click next page and we've got four more.
Great.
Now if we look at one of our photo type categories one called Still Life.
I've got all the still lives in one list again for at a time.
That's great.
And what happens if I go to one of my tags.
I'm going to click antique.
Now if you get this problem we may have to change the settings under the custom press plugin for how
to display archive pages like this.
You can see that I'm trying to view the tag page for the tag antique and no posts are matching my criteria.
Well go back into the Wordpress dashboard and you can see I do have all these tags and the antique tag
does have 5 posts or photograph posts.
Well under custom press and settings.
This is a place where you will need to make a slight change now on the archive pages when we look at
tags or categories.
Instead of checking default to uncheck default and we want to check photograph and that way when we
look at archive pages it will show posts from the photograph post type as well as anything else we'd
like to select here.
So if I click save changes now when I go back to the antique tag page if I refresh the page I should
get five posts in the antique category.
Great.
And on the next page I think this should just be one more awesome.
Now when we're looking at any archive page if we click the image or the title it'll bring us to a full
width page which is the single post with its content the full size image as well as the file under data
which is our photo type or category as well as the tags that we're using for each image.
In this lesson you imported or created 30 posts in our new photographs custom post type and make sure
they contain all our custom data and images.
Then you arranged the post type display in the cafe pro theme to look good inside archive pages.
Next we'll finish the chapter by creating a conditional display widget for the custom fields we're using
in each photograph post and we'll arrange some of our new custom post type content on the scrolling
home page.
See there