Wordpress Themes - WP Forum at BFA
There will be no more development for Atahualpa (or any other theme), and no support. Also no new registrations. I turned off the donation system. I may turn the forum to read only if it gets abused for spam. Unfortunately I have no time for the forum or the themes. Thanks a lot to the people who helped in all these years, especially Larry and of course: Paul. Take care and stay healthy -- Flynn, Atahualpa developer, Sep 2021

Wordpress Themes - WP Forum at BFA » WordPress Themes » Montezuma Theme »

Custom field template tag


 
Prev Previous Post   Next Post Next
  #1  
Old Nov 5, 2012, 03:46 AM
ripz7
 
6 posts · Nov 2012
Options Custom field template tag

Hi,

I have found the template_tags.php include file and I am trying to add a custom template tag that will display custom field data for each post.

Here is what I have for a test:

Code:
function bfa_post_link() {
	$id = get_the_ID();
	
	echo 'This is the current post ID: '.$id;
}
I want to use this in a sub-template, however when I insert my custom template tag ( bfa_post_link(); ), it doesn't display anything. Do I need to declare this function in another file somewhere so it loads with the rest or something similar?

Ps: Is there any other easier way of displaying custom field data for each post in Montezuma's virtual template system?

Any help or advice is much appreciated.

Thanks
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Show custom field in kicker - only IF field value exists jaxon Center area post/pages 13 Feb 6, 2013 01:11 PM
Custom field template - show on posts.. uffehs Atahualpa 3 Wordpress theme 5 Apr 6, 2012 03:31 PM
Using a custom field within an excerpt... or trying to arthurmild Excerpts, Read more, Pagination 4 Jan 5, 2011 04:40 AM
Button with Custom Field Xethon Sidebars & Widgets 0 Sep 17, 2010 04:08 AM
Custom field image with custom field link mbastos Atahualpa 3 Wordpress theme 1 Jul 1, 2010 08:17 AM


All times are GMT -6. The time now is 05:08 AM.


Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.