-
AuthorPosts
-
ozzymanson2 Friend
ozzymanson2
- Join date:
- September 2012
- Posts:
- 75
- Downloads:
- 0
- Uploads:
- 2
- Thanks:
- 6
- Thanked:
- 4 times in 1 posts
December 15, 2012 at 8:35 am #183131how to make twitter posts looks like in demo (com_content) in K2?
com_content http://gyazo.com/493585bab3c0f7433e3f77721d3a6410
K2 http://gyazo.com/6676d7d687fe58662350b0512e1f904bthere are no blue bird, intro text and active links in K2
misteroram01 Friendmisteroram01
- Join date:
- September 2012
- Posts:
- 13
- Downloads:
- 0
- Uploads:
- 0
- Thanked:
- 3 times in 3 posts
December 17, 2012 at 7:23 am #476436Try with K2 twitter button change text
ozzymanson2 Friendozzymanson2
- Join date:
- September 2012
- Posts:
- 75
- Downloads:
- 0
- Uploads:
- 2
- Thanks:
- 6
- Thanked:
- 4 times in 1 posts
December 17, 2012 at 7:37 am #476439<em>@misteroram01 350874 wrote:</em><blockquote>Try with K2 twitter button change text</blockquote>
what are you talking about? i didn’t understand
Wall Crasher DeveloperWall Crasher
- Join date:
- December 2011
- Posts:
- 1113
- Downloads:
- 0
- Uploads:
- 15
- Thanks:
- 66
- Thanked:
- 361 times in 300 posts
December 17, 2012 at 8:47 am #476460Hi
It is easy to show the blue bird in k2 item.
Just add ‘twitter’ as extended class to K2 items.
You can also use this thread http://www.joomlart.com/forums/topic/youtube-extended-classes/#post-476291
and try to copy the function to twitter feeds.
Here are steps:
1. Open pluginssystemjasocial_feedjasocial_feed.xml and this block code at line 118
<field name="twitter_exclass" type="text" default="" label="Extened class" description="Extened class"/>
2. Open pluginssystemjasocial_feedjasocial_feed.php and add this block code at line 315
$twitter_exclass= $this->getProperty($profile, 'twitter_exclass', '');
And this block code at line 389
if($twitter_exclass){
$post['metadata'] = json_encode(array('xclass' => $twitter_exclass));
}Also, add this line code at line
3. Open pluginssystemjasocial_feedtablesjoomla.php and add this block code at line 95 (if you already add, please skip)
$item[‘metadata’] = isset($post[‘metadata’]) ? $post[‘metadata’] : ”;For the text, you can simply remove
$txt .= ‘<p class=”readmore”><a class=”readmore” href=”‘.$post[‘source_url’]. ‘” title=”‘.$post[‘source_url_txt’].'” target=”_blank”>’.$post[‘source_url_txt’].'</a></p>’;in pluginssystemjasocial_feedtablesk2.php
We will try to update new version to fix this problem.
Hope it helps.
Regards
2 users say Thank You to Wall Crasher for this useful post
Wall Crasher DeveloperWall Crasher
- Join date:
- December 2011
- Posts:
- 1113
- Downloads:
- 0
- Uploads:
- 15
- Thanks:
- 66
- Thanked:
- 361 times in 300 posts
December 18, 2012 at 9:34 am #476632Hi,
I make a mistake yesterday.
<blockquote>And this block code at line 389
Code:
if($twitter_exclass){
$post[‘metadata’] = json_encode(array(‘xclass’ => $twitter_exclass));
}
Also, add this line code at line3. Open pluginssystemjasocial_feedtablesjoomla.php and add this block code at line 95 (if you already add, please skip)
$item[‘metadata’] = isset($post[‘metadata’]) ? $post[‘metadata’] : ”;</blockquote>I forgot we are try to use K2, not Joomla Standard content.
It should be like this.if($twitter_exclass){
$post['exclass'] = json_encode(array(array('id' => 1, 'value' => $twitter_exclass)));
}and Open file pluginssystemjasocial_feedtablesk2.php instead of ‘pluginssystemjasocial_feedtablesjoomla.php’
We should add this line code at line 107
$item['extra_fields'] = isset($post['exclass']) ? $post['exclass'] : '';
There is one important note:
json_encode(array(array('id' => 1, 'value' => $twitter_exclass)))
Since we use id value here. This value should be the id of extra field name ‘Extended Class’ of K2 #__k2_extra_fields table.If you have installed our quickstart package, you should get it at id = 1. If you not have Extended Class extra field, you should add it to K2 and change the correct id here.
Hope it helps.
Regards
-
AuthorPosts
This topic contains 5 replies, has 3 voices, and was last updated by Wall Crasher 11 years, 11 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum