Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
What is the array I can find the custom fields in?
How can I get to my custom fields in <txp:php> tags?
Thanks – Jan
TXPDream – A Textpattern Tag Library for Adobe Dreamweaver. (updated for 4.2.0) | jdw_if_ajax – Only serve certain parts of a page when requested with AJAX
Offline
Re: What is the array I can find the custom fields in?
getCustomFields()
returns an indexed array of custom field names. That what you need?
Code is topiary
Offline
Re: What is the array I can find the custom fields in?
Thanks Jeff, but I actually want to get to the value for that custom field for the article in context, rather than its name. How would I do that?
edit: like $thisarticle['title']
grabs the title…
Last edited by JanDW (2010-06-30 20:45:57)
TXPDream – A Textpattern Tag Library for Adobe Dreamweaver. (updated for 4.2.0) | jdw_if_ajax – Only serve certain parts of a page when requested with AJAX
Offline
#4 2010-06-30 20:51:42
- net-carver
- Archived Plugin Author
- Registered: 2006-03-08
- Posts: 1,648
Re: What is the array I can find the custom fields in?
If you already know the name of the field it’s just $thisarticle['cf_name'];
. If I remember correctly.
Edited to add Yes, looks like it.
Last edited by net-carver (2010-06-30 20:54:52)
— Steve
Offline
Re: What is the array I can find the custom fields in?
Great! thanks guys.
TXPDream – A Textpattern Tag Library for Adobe Dreamweaver. (updated for 4.2.0) | jdw_if_ajax – Only serve certain parts of a page when requested with AJAX
Offline