How to Set Up a Portfolio Using Different Custom Post Types

Custom post types are the best addition to WordPress from version 3.0 and the support to custom post types has made it easy for you to manage different kinds of posts. There is no need of adding the custom fields to each and every post. The best thing that can be performed by utilizing distinct custom post types is to modify or build a new striking portfolio.

WordPress make it’s possible to build an attractive portfolio from the scratch. As most of the themes are developed using HTML5 and CSS3, you can feel free to utilize the creativity in revamping a perfect portfolio.

Before starting, you need to think off on the option that you wish to implement while creating custom posts. They can be implemented in two ways that include integrating it to the theme through functions.php file or by utilizing a standalone plugin.

 Setting Up the Portfolio Manually:

Initially you must reach the theme package and access the functions.php file. You have to place the entire code relevant to custom post types in a separate file. Later, you must add two other files to the theme package that include portfolio-type.php and portfolio.css. And the CSS elements that you generate will get added into the portfolio.css.

Setting Up the Portfolio Manually

Before registering the new type images, you must make sure that it supports the feature images as they stand as key elements for any portfolio presentation. You must add the below given code into portfolio-type.php file.

Setting Up the Portfolio Manually1

You must even set the default size of the thumbnail that must be added to the portfolio. The images placed on your site’s portfolio must be in size of 720 x 540.

You must create a new custom post type by adding a small snippet of code. The function that you include in the code will include all the arguments relevant to title and editor fields.

Setting Up the Portfolio Manually

The immediate step after registering a new portfolio type is creating the custom taxonomy and in order to add custom taxonomy, you need to place a single line of code in the portfolio-type.php file.

Setting Up the Portfolio Manually

The next step is creating a new custom field box by adding some code to the portfolio-type.php file. Upon creation of the custom data field boxes, you need to create a new function to save the data. Add the below given lines of code into portfolio-type.php file can help you in saving the data.

Setting Up the Portfolio Manually

Setting Up the Portfolio Manually

You have to customize the admin columns, add few additional display functions and then craft a new template page.

By adding styling elements into the CSS file, you can make the portfolio appear bit more beautiful. WordPress provides endless opportunities to stylize the portfolio until it matches the site’s design.

Leave a Reply

Your email address will not be published. Required fields are marked *

1000's of Wordpress Templates at Great Prices: Visit ThemeForest