Add Custom fields to td_block_3

Posted in: Newspaper
Post count: 25

Hi !
Why I Add code
<?php echo get_post_meta($this->post->ID, ‘source’, true); ?>
on Module td_block_3 but it does not work?

Post count: 6600

Hi,

Try it like this:

<?php
$td_post_theme_settings = get_post_meta($post->ID, 'td_post_theme_settings', true);
echo @$td_post_theme_settings['td_source'];
?>

Thanks

Post count: 25

Hi Lucian!
I used your code, but it still does not work
<?php
$gia_ban = get_post_meta($post->ID, ‘gia_ban’, true);
echo @$gia_ban[‘td_source’];
?>
http://www.screencast.com/t/cpBysE7JplSq

Post count: 6600

Hi,

Please replace the content of td_module_3.php file with this one: http://pastebin.com/NwCLhqim
Result: http://screencast.com/t/Ziy9mqgI

Thanks

Post count: 25

Hi Lucian!
You are misunderstanding my question. My idea is that when I create a Custom Fields plugin by ACF for Field Name is ‘nguon’. I want to show ‘nguon’ in td_block_3 whenever a new post, I have tried many ways, it operates at a loop-single but it does not work in td_block_3. Please guide me so that it can work in td_block_3.
http://www.screencast.com/t/zkeHLKRw
http://www.screencast.com/t/uWttWQ1Ejt
ex code not working:
<?php echo get_post_meta($this->post->ID, ‘nguon’, true);?>
$nguon->get_post_meta($this->post->ID, ‘nguon’, true);
or

Thank you!

Post count: 6600

Hi,

I believe that your code is wrong, please read here about this: http://www.advancedcustomfields.com/resources/displaying-custom-field-values-in-your-theme/
You can always get a freelancer from sites like: http://studio.envato.com/ if you don’t know how to do it yourself.

Thanks

Viewing 6 posts - 1 through 6 (of 6 total)
The forum ‘Newspaper’ is closed to new topics and replies.