Ask your WordPress questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

Setup of custom columns and quick edit menu for a post type WordPress

  • SOLVED

We have a custom post type that we need custom columns set up for. The columns pull data from the post's custom meta fields and associated taxonomies. We also need the quick edit menu configured with two additional taxonomies (selected via a pulldown) and two meta fields.

We are looking for a finished solution where we can insert the code and be ready to work.

custom post type: [[LINK href="https://gist.github.com/1bf1b48b70256f904575"]]https://gist.github.com/1bf1b48b70256f904575[[/LINK]]

custom taxonomies: [[LINK href="https://gist.github.com/2188ece19eb6f8a5fa1e"]]https://gist.github.com/2188ece19eb6f8a5fa1e[[/LINK]]

Custom meta fields:
stock number: _dappcf_i_stocknum
vin: _dappcf_i_vin
price/price 1: _dappcf_i_priceone
price 2: _dappcf_i_pricetwo

Custom taxonomies:
year: dappct_i_year
make: dappct_i_make
model: dappct_i_model
trim: dappct_i_trim
status: dappct_i_status

For your convince two related tutorials are below:
[[LINK href="http://shibashake.com/wordpress-theme/add-custom-post-type-columns"]]http://shibashake.com/wordpress-theme/add-custom-post-type-columns[[/LINK]]
[[LINK href="http://shibashake.com/wordpress-theme/expand-the-wordpress-quick-edit-menu"]]http://shibashake.com/wordpress-theme/expand-the-wordpress-quick-edit-menu[[/LINK]]

Answers (2)

2011-03-04

rilwis answers:

Hello Matt,

Here is your code: http://pastebin.com/5ENLAeaY

If you have problem with copy & paste, try download this file (this also contains your code for setting up the custom post types and taxonomies):

http://dl.dropbox.com/u/795417/columns.php

Thank you!

2011-03-03

Vidyut Kale answers:

So what is the post type and what are the meta fields?


Vidyut Kale comments:


Matt Taylor comments:

Added details into the question. :)


Vidyut Kale comments:

Its going to take quite a bit of work, and then testing to give you something plug and play - like a file to include....? I think $30 is too little. It is going to take a lot of time to put together.

Essentially, you want:

register post_type
register taxonomies for it
add meta boxes
do the column code
do the quick edit

Perhaps someone with better skills may not find it so much work.... For me it will take a day almost.

If no one else turns up, I can do this for a better fee.


Matt Taylor comments:

I already have the post types,taxonomies, and meta boxes resisted. Those files are linked too above.


Matt Taylor comments:

and by resisted I mean created. :)


Vidyut Kale comments:

Now that I think of it, [[LINK href="http://wordpress.org/extend/plugins/custom-post-type-ui/"]]Custom Post types UI[[/LINK]] and [[LINK href="http://wordpress.org/extend/plugins/headspace2/"]]Headspace2[[/LINK]] would do all that and far more much better than I could.

Create your post type and taxonomies making sure that the taxonomies support the post type.
Then, configure your meta. From what I remember, it will appear in the columns automatically.

Done.

As a bonus, it will take care of all your tracking, section targeting, inserting formatting to the pages if needed.... whole lot of stuff.


Matt Taylor comments:

Neither of these two plugins are sufficient. GD Post Type does it partially but I don't want to use a plugin here.