- Posts: 7
COMMUNITY FORUM
Get ITEM TITLE
- sortby
- Topic Author
- Offline
- New Member
I need to call the "itemtitle" into a custom php (chronoforms) that is loaded inside a K2 item
get('itemTitle')
I need to display the item title into a form.
I have used different solutions...but seems nothing is working.....
Thanks to all!
Frank
Please Log in or Create an account to join the conversation.
- Rupert Griffiths
- Offline
- Junior Member
- Posts: 30
www.siampropertydirect.com/villa-j-is-located-in-choeng-mon-koh-samui.html
Please Log in or Create an account to join the conversation.
- sortby
- Topic Author
- Offline
- New Member
- Posts: 7
I'm looking for a direct access to itemtitle (possibly without query) a direct access like "Joomla:: "
Any idea how to achieve this?
thanks
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
- Posts: 15920
Without querying the db there is no way of retrieving data in the current version of K2.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- sortby
- Topic Author
- Offline
- New Member
- Posts: 7
But with data layer in v3 it will be possible?
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
- Posts: 15920
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- sortby
- Topic Author
- Offline
- New Member
- Posts: 7
you mean I can integrate this file....mhhhh.....interesting......could you please tell me the short way to get itemtile.
Many thanks!
Please Log in or Create an account to join the conversation.
- Joe Campbell
- Offline
- Platinum Member
- Posts: 438
Try using the following solution:
www.nonumber.nl/forum/contenttemplater/11331
I hope this helps,
Joe Campbell
Please Log in or Create an account to join the conversation.
- Usop Wilcha
- Offline
- Junior Member
- Posts: 29
Joe Campbell wrote: Hello sortby,
Try using the following solution:
www.nonumber.nl/forum/contenttemplater/11331
I hope this helps,
Joe Campbell
Hi Joe
Here's my scenario,
I'm building a K2 based catalog, and on every item there's a booking form placed for the visitor to email back the site admin
At the booking form field, I've created a "Subject" field that visitor should write the K2 items page title then, as a product name
So, I was looking if there's any function of "self titled" for the "subject" field, when i found this thread ..
As i was currently try to understanding the solution here
I was stuck and confused here, what should i put on the subject field?
{source}<?php echo $article->title; ?>{/source}
OR
{article current}{title}{/article}
These lines won't work for me, am i doing something wrong here?
Please advise
Thanks!
Please Log in or Create an account to join the conversation.
- Joe Campbell
- Offline
- Platinum Member
- Posts: 438
Here are two solutions that you can utilize to produce the current K2 title:
{source 0}<?php echo $this->item->title; ?>{/source}
{article k2:current}{title}{/article}
Note: you may want/need to include "0" in your source syntax:
www.nonumber.nl/extensions/sourcerer#not-using-a-wysiwyg-editor
Please let me know which solution you utilize :)
Regards,
Joe
Please Log in or Create an account to join the conversation.