Re:Include content item and Joomlaworks k2 (1 viewing) (1) Guest
Favoured: 0
|
|
|
TOPIC: Re:Include content item and Joomlaworks k2
|
manukat (User)
Fresh Boarder
Posts: 5
|
|
Include content item and Joomlaworks k2 10 Months, 4 Weeks ago
|
Karma: 0
|
|
Anyone know if this can display K2 item or how it can be modified to pick up K2 content instead of com_content?
Any help would be appreciated.
Thanks
|
|
|
|
|
|
|
The administrator has disabled public write access.
|
kksou (Admin)
Admin
Posts: 1240
|
|
Re:Include content item and Joomlaworks k2 10 Months, 3 Weeks ago
|
Karma: 20
|
|
The Include content item plugin is written for use with the display of a standard article, which uses com_content.
If the K2 is written following the standard joomla framework, then theoretically any standard plugin should work with K2, as long as appropriate trigger is being added at the right places to so that the plugins are being triggered.
Every component is different, so I won't be able to know where to add the triggers.
You might want to check direct with the author of K2. He is the best person to know where to add those triggers. Alternatively, you can also check the joomla forum. Someone might have done it before for the popular components.
Regards,
/kksou
|
|
|
|
|
|
|
The administrator has disabled public write access.
|
manukat (User)
Fresh Boarder
Posts: 5
|
|
Re:Include content item and Joomlaworks k2 10 Months, 1 Week ago
|
Karma: 0
|
|
Thanks for the reply. I don't I explained my question correctly.
Your plugin works great in a K2 article but can only pull the item id from com_content. What I was asking is, since K2 displays articles like com_content and has IDs like com_content, can it be changed to pick it up in the database from K2 instead of com_content.
From what I have been reading from the Joomlaworks website, they made it easy to do this for plugin developers. Rockettheme managed to have their modules display either com_content articles or K2.
I just love your plugin and would love it even more if it could do this. I wouldn't even know where to begin to modify your plugin but hope that you could. Thanks in advance.
|
|
|
|
|
|
|
The administrator has disabled public write access.
|
kksou (Admin)
Admin
Posts: 1240
|
|
Re:Include content item and Joomlaworks k2 10 Months, 1 Week ago
|
Karma: 20
|
|
Hi,
Yes, you're right. It will be a simple thing to do if you know the database structure of K2.
I'm not familiar with K2. So I might not be able to help you here.
I would suggest you check it at the Joomla forum. Maybe someone has done it before.
Regards,
/kksou
|
|
|
|
|
|
|
The administrator has disabled public write access.
|
manukat (User)
Fresh Boarder
Posts: 5
|
|
Re:Include content item and Joomlaworks k2 8 Months ago
|
Karma: 0
|
Thanks for your response. I am not sure about the database structure but took a snapshot in phpmyadmin. Hopefully this helps.
Please help me use this great plugin with Joomlaworks K2
here is the screenshot:

|
|
|
|
|
|
|
The administrator has disabled public write access.
|
kksou (Admin)
Admin
Posts: 1240
|
|
Re:Include content item and Joomlaworks k2 8 Months ago
|
Karma: 20
|
|
Hi,
I do not want to pretend that I know everything.
I know PHP-GTK2. I know a bit of Joomla and google tools
such a google search and google maps. But I am really
not familiar with K2.
Looking at what you mentioned, it seems that Joomlaworks
has a lot of plugin developers.
Have you tried their forum? I'm sure there will be many
helpful people who will be able to help you in this.
Regards,
/kksou
|
|
|
|
|
|
|
The administrator has disabled public write access.
|
manukat (User)
Fresh Boarder
Posts: 5
|
|
Re:Include content item and Joomlaworks k2 5 Months, 1 Week ago
|
Karma: 0
|
|
After playing around and some luck, I figured out how to have include_content_item pull text from a k2 article instead of com_content. Now I just want to point out that this is a simple change which only displays intro text and full text in one shot. I do not have the skills to edit further to allow for all the options available such as title, readmore etc...
Hopefully this can help point kksou in the right direction hopefully get a full update to allow for all things K2.
I edited this file: /plugins/content/include_content_item/include_content_item.lib.php
on line 173 to 175, I replaced:
$query = "SELECT sectionid, catid, title, introtext,`fulltext`"
. "\n FROM #__content"
. "\n WHERE id=$content_id";$query = "SELECT sectionid, catid, title, introtext,`fulltext`"
. "\n FROM #__content"
with:
$query = "SELECT catid, title, introtext,`fulltext`"
. "\n FROM #__k2_items"
|
|
|
|
|
|
|
The administrator has disabled public write access.
|
manukat (User)
Fresh Boarder
Posts: 5
|
|
Re:Include content item and Joomlaworks k2 5 Months, 1 Week ago
|
Karma: 0
|
|
CORRECTIN
on line 173 to 174, I replaced:
$query = "SELECT sectionid, catid, title, introtext,`fulltext`"
. "\n FROM #__content"
with:
$query = "SELECT catid, title, introtext,`fulltext`"
. "\n FROM #__k2_items"
|
|
|
|
|
|
|
The administrator has disabled public write access.
|
|
|
|
|