Welcome to Geeklog, Anonymous Sunday, November 24 2024 @ 01:04 pm EST
Geeklog Forums
using 1.8.0 and the twitter plug installed but no feed updates
Twitter Plug in
Anonymous
I was able to install it with no problem. but even though i put my feed username in there.. biomimetix in user name, the block shows up blank ( ie no feeds). also as a clue perhaps.... even if chose any of the different twitter icons in the configuration they dont show up. Thank in advance for the help. Is this plugin still compatiable with the latest 1.8.0 and twitter?
11
8
Quote
Status: offline
suprsidr
Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
There are definitely some changes I could make to make twitter block 1.8 compatible.
I'll do that tonight, and release an update.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
I'll do that tonight, and release an update.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
12
13
Quote
Status: offline
suprsidr
Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
Update for GL 1.8.x here.
Please try it out and let me know if there are any issues.
@TOM - no thanks.
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
Please try it out and let me know if there are any issues.
@TOM - no thanks.
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
19
17
Quote
middyeasy
Anonymous
Thanks so much for the quick response!
I went ahead and removed the old one then installed this 1.2 version. Is that how i should have upgraded Or should I have did an upload and it would have over written it.. Im a geek log nubie so please excuse my ignorance.
The report ...so on the same machine .... in Safari the twitter feed shows up just fine.. in IE 9 the feed is blank.. even in IE 9 compability mode it is blank.. Possibly this was the issue with the first version and not necessarily a problem with your plugin.
anyway.. Thanks again!
Ken
I went ahead and removed the old one then installed this 1.2 version. Is that how i should have upgraded Or should I have did an upload and it would have over written it.. Im a geek log nubie so please excuse my ignorance.
The report ...so on the same machine .... in Safari the twitter feed shows up just fine.. in IE 9 the feed is blank.. even in IE 9 compability mode it is blank.. Possibly this was the issue with the first version and not necessarily a problem with your plugin.
anyway.. Thanks again!
Ken
13
20
Quote
Status: offline
Laugh
Site Admin
Admin
Registered: 09/27/05
Posts: 1470
Location:Canada
Thanks for the update Suprsidr. I just did a quick hack to add the functionality I wanted
For those of you who want to only allow Twitter Admins to use the twitter autotags you can replace the function plugin_autotags_twitter_block with the one below:
function plugin_autotags_twitter_block($op, $content = '', $autotag = '') {
global $_CONF, $_TW_CONF, $LANG_TWITTER_BLOCK_1, $_GROUPS, $_TABLES;
if ($op == 'tagname') {
return array('twitter_link', 'twitter_block', 'tweet', 'twitter_search');
} elseif ($op == 'permission' || $op == 'nopermission') {
// Autotag Permissions (usually stored in config.php or db)
$_TW_CONF['autotag_permissions_twitter_link'] = array (2, 2, 1, 1);
$_TW_CONF['autotag_permissions_twitter_block'] = array (2, 2, 1, 1);
$_TW_CONF['autotag_permissions_tweet'] = array (2, 2, 1, 1);
$_TW_CONF['autotag_permissions_twitter_search'] = array (2, 2, 1, 1);
if ($op == 'permission') {
$flag = true;
} else {
$flag = false;
}
$tagnames = array();
if (isset($_GROUPS['Twitter Block Admin'])) {
$group_id = $_GROUPS['Twitter Block Admin'];
} else {
$group_id = DB_getItem($_TABLES['groups'], 'grp_id',
"grp_name = 'Twitter Block Admin'");
}
$owner_id = SEC_getDefaultRootUser();
if (COM_getPermTag($owner_id, $group_id, $_TW_CONF['autotag_permissions_twitter_link'][0], $_TW_CONF['autotag_permissions_twitter_link'][1], $_TW_CONF['autotag_permissions_twitter_link'][2], $_TW_CONF['autotag_permissions_twitter_link'][3]) == $flag) {
$tagnames[] = 'twitter_link';
}
if (COM_getPermTag($owner_id, $group_id, $_TW_CONF['autotag_permissions_twitter_block'][0], $_TW_CONF['autotag_permissions_twitter_block'][1], $_TW_CONF['autotag_permissions_twitter_block'][2], $_TW_CONF['autotag_permissions_twitter_block'][3]) == $flag) {
$tagnames[] = 'twitter_block';
}
if (COM_getPermTag($owner_id, $group_id, $_TW_CONF['autotag_permissions_tweet'][0], $_TW_CONF['autotag_permissions_tweet'][1], $_TW_CONF['autotag_permissions_tweet'][2], $_TW_CONF['autotag_permissions_tweet'][3]) == $flag) {
$tagnames[] = 'tweet';
}
if (COM_getPermTag($owner_id, $group_id, $_TW_CONF['autotag_permissions_twitter_search'][0], $_TW_CONF['autotag_permissions_twitter_search'][1], $_TW_CONF['autotag_permissions_twitter_search'][2], $_TW_CONF['autotag_permissions_twitter_search'][3]) == $flag) {
$tagnames[] = 'twitter_search';
}
if (count($tagnames) > 0) {
return $tagnames;
}
} elseif ($op == 'parse') {
if ($autotag['tag'] == 'twitter_block' ) {
$count = (!empty ($autotag['parm1']) && is_numeric($autotag['parm1']))?
COM_applyFilter($autotag['parm1']):$_TW_CONF['number_tweets'];
$class = $twitterUserName = '';
if (!empty ($autotag['parm2'])) {
foreach(explode(' ',trim(COM_applyFilter($autotag['parm2']))) as $pair){
$parts = explode(':', $pair);
if ($parts[0] == 'align'){
switch ($parts[1]) {
case "right";
$class = ' class="float-right"';
break;
case "left";
$class = ' class="float-left"';
break;
case "center";
$class= ' class="float-center"';
break;
default;
$class = '';
break;
}
} else if ($parts[0] == 'username'){
$twitterUserName = $parts[1];
}
}
}
$retval = phpblock_twitter_block('twitter_tag', $twitterUserName, $count, $class);
$content = str_replace ($autotag['tagstr'], $retval, $content);
} else if ($autotag['tag'] == 'twitter_link') {
$linkText = (!empty($autotag['parm1']))?COM_applyFilter($autotag['parm1']):$LANG_TWITTER_BLOCK_1['follow_link_text'];
$linkText = preg_replace('/_/', ' ', $linkText);
$url = 'http://twitter.com/' . $_TW_CONF['twitter_username'];
$link = '<a href="'.$url.'" title="'.$linkText.'" target="_blank">'.$linkText.'</a>';
$content = str_replace($autotag['tagstr'], $link, $content);
} else if ($autotag['tag'] == 'tweet' ) {
$length = (!empty ($autotag['parm1']) && is_numeric($autotag['parm1']))?COM_applyFilter($autotag['parm1']):36;
$twitterUserName = '';
$tid = 0;
if (!empty ($autotag['parm2'])) {
foreach(explode(' ',trim(COM_applyFilter($autotag['parm2']))) as $pair){
$parts = explode(':', $pair);
if ($parts[0] == 'username'){
$twitterUserName = $parts[1];
}
if ($parts[0] == 'tid'){
$tid = $parts[1];
}
}
}
$twitterUserName = ($twitterUserName == '')?$_TW_CONF['twitter_username']:$twitterUserName;
$div = 'autotag-mini-tweet-'.$twitterUserName;
$retval = phpblock_tweet($div, $twitterUserName, $length, $tid);
$content = str_replace ($autotag['tagstr'], $retval, $content);
} else if ($autotag['tag'] == 'twitter_search' ) {
$count = (!empty ($autotag['parm1']) && is_numeric($autotag['parm1']))?$autotag['parm1']:$_TW_CONF['number_tweets'];
$class = $searchTerm = '';
if (!empty ($autotag['parm2'])) {
foreach(explode(' ',trim(COM_applyFilter($autotag['parm2']))) as $pair){
$parts = explode(':', $pair);
if ($parts[0] == 'term'){
$searchTerm = COM_applyFilter($parts[1]);
$searchTerm = preg_replace('/_/', ' ', $searchTerm);
}
if ($parts[0] == 'align'){
switch ($parts[1]) {
case "right";
$class = ' class="float-right"';
break;
case "left";
$class = ' class="float-left"';
break;
case "center";
$class= ' class="float-center"';
break;
default;
$class = '';
break;
}
}
}
}
$retval = phpblock_twitter_search('twitter-search', $searchTerm, $count, $class);
$content = str_replace ($autotag['tagstr'], $retval, $content);
}
return $content;
}
}
One of the Geeklog Core Developers.
For those of you who want to only allow Twitter Admins to use the twitter autotags you can replace the function plugin_autotags_twitter_block with the one below:
Text Formatted Code
function plugin_autotags_twitter_block($op, $content = '', $autotag = '') {
global $_CONF, $_TW_CONF, $LANG_TWITTER_BLOCK_1, $_GROUPS, $_TABLES;
if ($op == 'tagname') {
return array('twitter_link', 'twitter_block', 'tweet', 'twitter_search');
} elseif ($op == 'permission' || $op == 'nopermission') {
// Autotag Permissions (usually stored in config.php or db)
$_TW_CONF['autotag_permissions_twitter_link'] = array (2, 2, 1, 1);
$_TW_CONF['autotag_permissions_twitter_block'] = array (2, 2, 1, 1);
$_TW_CONF['autotag_permissions_tweet'] = array (2, 2, 1, 1);
$_TW_CONF['autotag_permissions_twitter_search'] = array (2, 2, 1, 1);
if ($op == 'permission') {
$flag = true;
} else {
$flag = false;
}
$tagnames = array();
if (isset($_GROUPS['Twitter Block Admin'])) {
$group_id = $_GROUPS['Twitter Block Admin'];
} else {
$group_id = DB_getItem($_TABLES['groups'], 'grp_id',
"grp_name = 'Twitter Block Admin'");
}
$owner_id = SEC_getDefaultRootUser();
if (COM_getPermTag($owner_id, $group_id, $_TW_CONF['autotag_permissions_twitter_link'][0], $_TW_CONF['autotag_permissions_twitter_link'][1], $_TW_CONF['autotag_permissions_twitter_link'][2], $_TW_CONF['autotag_permissions_twitter_link'][3]) == $flag) {
$tagnames[] = 'twitter_link';
}
if (COM_getPermTag($owner_id, $group_id, $_TW_CONF['autotag_permissions_twitter_block'][0], $_TW_CONF['autotag_permissions_twitter_block'][1], $_TW_CONF['autotag_permissions_twitter_block'][2], $_TW_CONF['autotag_permissions_twitter_block'][3]) == $flag) {
$tagnames[] = 'twitter_block';
}
if (COM_getPermTag($owner_id, $group_id, $_TW_CONF['autotag_permissions_tweet'][0], $_TW_CONF['autotag_permissions_tweet'][1], $_TW_CONF['autotag_permissions_tweet'][2], $_TW_CONF['autotag_permissions_tweet'][3]) == $flag) {
$tagnames[] = 'tweet';
}
if (COM_getPermTag($owner_id, $group_id, $_TW_CONF['autotag_permissions_twitter_search'][0], $_TW_CONF['autotag_permissions_twitter_search'][1], $_TW_CONF['autotag_permissions_twitter_search'][2], $_TW_CONF['autotag_permissions_twitter_search'][3]) == $flag) {
$tagnames[] = 'twitter_search';
}
if (count($tagnames) > 0) {
return $tagnames;
}
} elseif ($op == 'parse') {
if ($autotag['tag'] == 'twitter_block' ) {
$count = (!empty ($autotag['parm1']) && is_numeric($autotag['parm1']))?
COM_applyFilter($autotag['parm1']):$_TW_CONF['number_tweets'];
$class = $twitterUserName = '';
if (!empty ($autotag['parm2'])) {
foreach(explode(' ',trim(COM_applyFilter($autotag['parm2']))) as $pair){
$parts = explode(':', $pair);
if ($parts[0] == 'align'){
switch ($parts[1]) {
case "right";
$class = ' class="float-right"';
break;
case "left";
$class = ' class="float-left"';
break;
case "center";
$class= ' class="float-center"';
break;
default;
$class = '';
break;
}
} else if ($parts[0] == 'username'){
$twitterUserName = $parts[1];
}
}
}
$retval = phpblock_twitter_block('twitter_tag', $twitterUserName, $count, $class);
$content = str_replace ($autotag['tagstr'], $retval, $content);
} else if ($autotag['tag'] == 'twitter_link') {
$linkText = (!empty($autotag['parm1']))?COM_applyFilter($autotag['parm1']):$LANG_TWITTER_BLOCK_1['follow_link_text'];
$linkText = preg_replace('/_/', ' ', $linkText);
$url = 'http://twitter.com/' . $_TW_CONF['twitter_username'];
$link = '<a href="'.$url.'" title="'.$linkText.'" target="_blank">'.$linkText.'</a>';
$content = str_replace($autotag['tagstr'], $link, $content);
} else if ($autotag['tag'] == 'tweet' ) {
$length = (!empty ($autotag['parm1']) && is_numeric($autotag['parm1']))?COM_applyFilter($autotag['parm1']):36;
$twitterUserName = '';
$tid = 0;
if (!empty ($autotag['parm2'])) {
foreach(explode(' ',trim(COM_applyFilter($autotag['parm2']))) as $pair){
$parts = explode(':', $pair);
if ($parts[0] == 'username'){
$twitterUserName = $parts[1];
}
if ($parts[0] == 'tid'){
$tid = $parts[1];
}
}
}
$twitterUserName = ($twitterUserName == '')?$_TW_CONF['twitter_username']:$twitterUserName;
$div = 'autotag-mini-tweet-'.$twitterUserName;
$retval = phpblock_tweet($div, $twitterUserName, $length, $tid);
$content = str_replace ($autotag['tagstr'], $retval, $content);
} else if ($autotag['tag'] == 'twitter_search' ) {
$count = (!empty ($autotag['parm1']) && is_numeric($autotag['parm1']))?$autotag['parm1']:$_TW_CONF['number_tweets'];
$class = $searchTerm = '';
if (!empty ($autotag['parm2'])) {
foreach(explode(' ',trim(COM_applyFilter($autotag['parm2']))) as $pair){
$parts = explode(':', $pair);
if ($parts[0] == 'term'){
$searchTerm = COM_applyFilter($parts[1]);
$searchTerm = preg_replace('/_/', ' ', $searchTerm);
}
if ($parts[0] == 'align'){
switch ($parts[1]) {
case "right";
$class = ' class="float-right"';
break;
case "left";
$class = ' class="float-left"';
break;
case "center";
$class= ' class="float-center"';
break;
default;
$class = '';
break;
}
}
}
}
$retval = phpblock_twitter_search('twitter-search', $searchTerm, $count, $class);
$content = str_replace ($autotag['tagstr'], $retval, $content);
}
return $content;
}
}
One of the Geeklog Core Developers.
15
19
Quote
Middyeasy
Anonymous
I'm wondering if there is a update timer for when it goes out and fetches it.. cause suddenly safari isnt working for me.. maybe its a matter of simply waiting?
18
24
Quote
Status: offline
suprsidr
Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
Strange how I'm not getting notifications from this thread(I subscribed)
Are you still having this issue?
Works for me in all major browsers. Although I've moved on to a new twitter plugin in development.
Twitter has a rate limit - something I ran into during initial development.
Let some time pass and try again.
@Tom, thanks for the updated function, I'll add it to the archive.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
Hmm just notice that FF shows a blank Twitter block as well.
I'm wondering if there is a update timer for when it goes out and fetches it.. cause suddenly safari isnt working for me.. maybe its a matter of simply waiting?
Are you still having this issue?
Works for me in all major browsers. Although I've moved on to a new twitter plugin in development.
Twitter has a rate limit - something I ran into during initial development.
Let some time pass and try again.
@Tom, thanks for the updated function, I'll add it to the archive.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
15
10
Quote
Status: offline
suprsidr
Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
Just updated to 1.2.1 simple addition of Tom's permissions and tooltip descriptions in story editor.
Updating is as easy as pointing admin -> plugins to the archive and click upload.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
Updating is as easy as pointing admin -> plugins to the archive and click upload.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
12
14
Quote
Status: offline
suprsidr
Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
url to offending site?
still not getting notifications on this thread.
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
still not getting notifications on this thread.
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
35
18
Quote
Status: offline
suprsidr
Forum User
Full Member
Registered: 12/29/04
Posts: 555
Location:Champaign, Illinois
Just an update, we've identified two issues.
One is in the way the scripts class adds jQuery to the page, and the other is twitter's response that IE does not like.(twitter is working on it)
I'll post another update when all is rectified.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
One is in the way the scripts class adds jQuery to the page, and the other is twitter's response that IE does not like.(twitter is working on it)
I'll post another update when all is rectified.
-s
FlashYourWeb and Your Gallery with the E2 XML Media Player for Gallery2 - http://www.flashyourweb.com
22
14
Quote
All times are EST. The time is now 01:04 pm.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content