Skip to main content
16 events
when toggle format what by license comment
Sep 17, 2014 at 17:18 vote accept dmoz
Sep 12, 2014 at 1:31 answer added dmoz timeline score: 0
Sep 12, 2014 at 1:27 comment added dmoz Ok! So I figured out why the documentary and corporate page templates weren't pulling the post meta: my meta fields id's in functions.php had a variable @prefix applied before the name. I added that prefix and, voilá! My question still, though, is why the homepage template was working at all?
Sep 12, 2014 at 1:20 comment added dmoz Yes sir, @vancoder. I left the thegallerymusic.com/test/documentary page up with it if you want to see. What's great is that videos actually show up when I added your code, but without it they're gone completely :/
Sep 11, 2014 at 23:49 comment added vancoder Probably a stupid question, but those meta fields (film_embed, film_textarea) are actually populated for posts that have the documentary term applied - right? If you do $custom_fields = get_post_custom($post_id); print_r($custom_fields); you actually get something back?
Sep 11, 2014 at 23:26 history edited dmoz CC BY-SA 3.0
deleted 36 characters in body
Sep 11, 2014 at 23:25 comment added dmoz @TomásCot - I've updated the code with more of the header and replaced $post_id->ID with get_the_ID(). @vancoder - When I var_dump($post_id); it returns the correct id's of the posts.
Sep 11, 2014 at 23:18 history edited dmoz CC BY-SA 3.0
more code
Sep 11, 2014 at 23:16 comment added vancoder Is $post_id actually populated in those other 2 templates? Output it - my guess is it's empty.
Sep 11, 2014 at 23:13 comment added Tomás Cot you can get the post id with get_the_ID() function. Can you add the header where the name of the templates is?
Sep 11, 2014 at 22:53 comment added dmoz Okay, I added the rest of the loop. It's identical for both pages, and, again, the homepage one shows every video in the correct category, while the documentary one (and corporate.php) does not.
Sep 11, 2014 at 22:52 history edited dmoz CC BY-SA 3.0
updated with more code
Sep 11, 2014 at 22:20 comment added vancoder I think you need to show the code that is supposed to output the meta that you speak of.
Sep 11, 2014 at 21:39 comment added dmoz Yea, on the corporate and documentary pages nothing shows up. The names of the template files are: homepage.php, corporate.php, and documentary.php. What's also interesting is that the archive page for the custom post type (thegallerymusic.com/test/films) populates only six of the posts(two on page 2), out of twelve total. It's generating the containing divs for each post, but the custom_post_meta (the actual video embed, title, description) is not being loaded within those...
Sep 11, 2014 at 20:59 comment added Tomás Cot what doesn't work? It doesn't show anything? Also, can you add the names of the files?
Sep 11, 2014 at 19:37 history asked dmoz CC BY-SA 3.0