Title: Adding Featured Video Functionality To Custom post Types
Last modified: August 20, 2016

---

# Adding Featured Video Functionality To Custom post Types

 *  [sarthakgupta101](https://wordpress.org/support/users/sarthakgupta101/)
 * (@sarthakgupta101)
 * [14 years, 6 months ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/)
 * I have added this to the normal blog posts and it works like a charm, however
   would like to know how to add this feature to **custom post types** say ‘NEWS’.
 * [http://wordpress.org/extend/plugins/featured-video/](http://wordpress.org/extend/plugins/featured-video/)

Viewing 11 replies - 1 through 11 (of 11 total)

 *  Plugin Author [LucP](https://wordpress.org/support/users/towonder/)
 * (@towonder)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438465)
 * I’m afraid you are going to have to go into the code…
    The plugin checks if you
   are trying to add it to a custom post type or just a post..
 * But it’s a good feature request for the future…
 *  [ChristinaHooper](https://wordpress.org/support/users/christinahooper/)
 * (@christinahooper)
 * [14 years ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438479)
 * Has this been added yet, or were you able to accomplish it?
 * If not, I would be happy to modify the code to include these feature… any pointers
   on where to start?
 *  [ChristinaHooper](https://wordpress.org/support/users/christinahooper/)
 * (@christinahooper)
 * [14 years ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438480)
 * Lol… nvm… that was a lot easier to do than I was thinking it would be.
 * For anyone else that needs it, in featured-video.php, in the fv_meta_regiester
   function, it has this:
 * add_meta_box(‘fv_meta’, ‘Featured video’, ‘fv_meta_html’, ‘post’, ‘side’, ‘low’);
 * You just add this for each custom post type you have
    add_meta_box(‘fv_meta’,‘
   Featured video’, ‘fv_meta_html’, ‘CUSTOM POST NAME GOES HERE’, ‘side’, ‘low’);
 *  [ibcreative](https://wordpress.org/support/users/ibcreative/)
 * (@ibcreative)
 * [14 years ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438481)
 * Hi, i was working this too and found that your solution is right but incomplete.
   It only manages to show the form on the custom post admin view but it doesn’t
   actually save the data.
 * I got it working by adding: `if(isset($_GET['customposttypename'])){
    $post_id
   = $_GET['customposttypename']; } to the fv_meta_html function in the plugin file
   just below if(isset($_GET['post'])){ $post_id = $_GET['post']; } and before the
   else part.
 *  [ChristinaHooper](https://wordpress.org/support/users/christinahooper/)
 * (@christinahooper)
 * [14 years ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438482)
 * I was just working on that part… thanks for the help!
 *  [ibcreative](https://wordpress.org/support/users/ibcreative/)
 * (@ibcreative)
 * [14 years ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438483)
 * No problem, please let me know if you find anything else regarding this functionality.
   Thanks
 *  [ChristinaHooper](https://wordpress.org/support/users/christinahooper/)
 * (@christinahooper)
 * [14 years ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438484)
 * I’ve actually run across one thing I can’t seem to fix… I need to add ?wmode=
   transparent to the end of the src url so that the videos will respond to z-index
   settings.
 * Right now I have a gallery with a mix of featured video and image, and I use 
   the lightbox plugin on the images… when I click an image and it comes up in the
   lightbox, the video is on top of the lightbox. So I need to get that transparent
   setting into the src to fix it.
 *  [ibcreative](https://wordpress.org/support/users/ibcreative/)
 * (@ibcreative)
 * [14 years ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438485)
 * well i think i may have found the solution, i just appended the wmode to the 
   link in the line:
 * `echo '<iframe width="'.$width.'" height="'.$height.'" src="http://www.youtube.
   com/embed/'.$id.'?wmode=transparent" frameborder="0" allowfullscreen></iframe
   >';`
 * BUT, the trick is that for some reason i had to make the change in the built 
   in WordPress plugin editor, it didn’t work otherwise…
 *  [ChristinaHooper](https://wordpress.org/support/users/christinahooper/)
 * (@christinahooper)
 * [14 years ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438486)
 * I tried to make that same change over and over and over again in ftp and it wouldn’t
   work. I didn’t think to try the WP editor. I’ll give that a try. Thanks again!
 *  Plugin Author [LucP](https://wordpress.org/support/users/towonder/)
 * (@towonder)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438491)
 * Hey, the new version automatically works with every custom post type. plus the
   wmode can be set now. Thanks for the inspiration!
 *  [ChristinaHooper](https://wordpress.org/support/users/christinahooper/)
 * (@christinahooper)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438492)
 * Awesome! Thank-you!

Viewing 11 replies - 1 through 11 (of 11 total)

The topic ‘Adding Featured Video Functionality To Custom post Types’ is closed to
new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/featured-video.svg)
 * [Featured Video](https://wordpress.org/plugins/featured-video/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/featured-video/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/featured-video/)
 * [Active Topics](https://wordpress.org/support/plugin/featured-video/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/featured-video/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/featured-video/reviews/)

 * 11 replies
 * 4 participants
 * Last reply from: [ChristinaHooper](https://wordpress.org/support/users/christinahooper/)
 * Last activity: [13 years, 11 months ago](https://wordpress.org/support/topic/adding-featured-video-functionality-to-custom-post-types/#post-2438492)
 * Status: not resolved