PDA

View Full Version : Add-On Releases - vBulletin 2 Twitter - Take Your News Straight To Twitter!


AHealthForum
03-15-2009, 10:00 PM
vBulletin2 Twitter Courtesy A Health Forum http://ahealthforum.com
Special Thanks to Jarvis From http://seovb.com for help
vbtotwitt.php copyright Vojtech Semecky released under the terms of GPL
================================================== =========

This modification will take one of your latest news threads and post it directly to your twitter account. You must have RSS enabled for this modification to work. You can specify a forum to pull the content from using external.php?f=FORUMID

The RSS feed will post your thread title directly into your Twitter account, and then create a link back using TinyURL. The links are automatically converted into tinyurl.com links via the TinyURL API


Install instructions

1. Upload the includes folder into your forum root. This will automatically place the 2 scripts need to operate this into the "includes/cron/" folder
2. Install the product-ahealthforumcomvbtwit.xml file via the Product Manager in your adminCP
3. Navigate to vBulletin Options -> vBulletin Options -> vBulletin 2 Twitter and enter your name and password.
4. Hit Save and Wait 2 minutes
5. View your twitter account to confirm that an update was posted.
6. Enter the URL to your forum feed.

Notice: By default for testing purposes this makes one tweet announcing you've installed vB2Twitter You are free to delete this tweet as it is for testing purposes only!!!!

================================================== =============

vBulletin 2 Twitter Options

1. Twitter Username: This is your Twitter.com username. If you don't have one yet, you can get one for free at http://twitter.com

2. Twitter Password: This is your password for your twitter account. Notice that its not hashed or encypted so anyone with adminCP access can view it. If you can't trust those who have your AdminCP information with such details, then this mod isn't for you sorry.

3. Feed URL: This can be to any sites feed if you want, but I suggest pointing it to your news forum and creating a prefix such as to make the most of this. Your twitter posts will then be prefixed with Thread Title link to thread.

================================================== ===========


Again, this modification will take the latest thread from the forum RSS feed you specify. I don't beleive in spamming on twitter with useless crap, so I've made this modification to only take one thread at a time from your forums RSS feed.


[B][B]Trouble Shooting:

If it does not automatically update to your account. Go into the scheduled tasks manage and run the task manually.

external.php gives a blank page. Enable RSS from your vBulletin Admin Control Panel.

AHealthForum
03-16-2009, 05:40 AM
Reserved

tanand79
03-16-2009, 10:59 AM
not working

hollosch
03-16-2009, 12:25 PM
I'm using zoints-seo, and i get "Error: RSS file not found, dude." when i use the scheduled task...

ericgtr
03-16-2009, 01:26 PM
FYI, this can be done without a modification by placing the RSS feed of your forum into twitterfeed.com I do this myself for one of my more popular forums. It can also do all forums as well.

hollosch
03-16-2009, 01:48 PM
FYI, this can be done without a modification by placing the RSS feed of your forum into twitterfeed.com I do this myself for one of my more popular forums. It can also do all forums as well.

thanx for this.

-1 cron-job in my vB

raaowdot
03-16-2009, 02:35 PM
Won't work for me either. I'm using the RSS feed /external.php?type=RSS2 which displays all open nonrestricted forum posts and this plugin may require the forum code only.

I've resorted to using the twitterfeed.com for now but it only post a maximum of 5 messages every 30mins so at busy time messages will be missed.

Any chance of an update to get this working as the popularity of Twitter is growing fast and my users want this feature.

Note this is my first posts here in 2 years as I've never has the need to ask something that wasn't already answered a million times before but Twitter is pretty new and we need more plugins. The Twitter on Profile pages works brilliantly though.

AHealthForum
03-16-2009, 05:00 PM
Some tips to help get it working.

Make sure your server has cURL installed or it may not work correctly.

After installing and you enter your RSS feed location. Go to the forum where you selected the RSS feed come from and make a fast post in there.

vBulletin Scheduled tasks don't seem to run every minute for some reason, so it may take a few minutes for it to update to twitter

I just uninstalled on my forums, and reinstalled following the instructions and it still works okay: http://twitter.com/healthforum Feel free to register an account at health forums and make a test post to see.

lord_of_chaos
03-16-2009, 05:47 PM
Twitterfeed.com does only run the Cronjob every 30 Minutes...

@AHealthForum:
1. Could you advertise a little bit less inside your product? "HealthForum" everywhere annoys me. ;)

2. This mod always posts the last RSS-item into my Twitter Account. It doesn't care that the item is two weeks old and that it have been posted before.

My Twitter profile looked like that:
- "News from 2.03.09"
- "Some other handmade Twit"
- "News from 2.03.09"

Jasem
03-16-2009, 06:37 PM
not working, thank you :confused:

AHealthForum
03-16-2009, 07:03 PM
Twitterfeed.com does only run the Cronjob every 30 Minutes...

@AHealthForum:
1. Could you advertise a little bit less inside your product? "HealthForum" everywhere annoys me. ;)



Its not every where? And sure next time i create a product and share i'll keep your feelings in mind ;)



2. This mod always posts the last RSS-item into my Twitter Account. It doesn't care that the item is two weeks old and that it have been posted before.

My Twitter profile looked like that:
- "News from 2.03.09"
- "Some other handmade Twit"
- "News from 2.03.09"

This is does do, I haven't been able to find a work around, but i haven't actively looked for one yet either as I just use my twitter account to post updates from the forums and this is good enough for that :D

:up:

AHealthForum
03-16-2009, 07:03 PM
not working, thank you :confused:

Your welcome?

wizardan
03-16-2009, 07:55 PM
Didn't work for me either.
Ran the scheduled task manually and got an error message posted to my twitter page.
Uninstalled for now.

AHealthForum
03-16-2009, 08:56 PM
Didn't work for me either.
Ran the scheduled task manually and got an error message posted to my twitter page.
Uninstalled for now.

Make sure your have your RSS enabled on your forums, and cURL support on the server.

This may also only work with PHP5 as i haven't tested on PHP4 yet


I'm in the process of moving to a another hosting company that should let me test this in PHP4 and PHP5 to see if that maybe a problem for some users.

Flep
03-17-2009, 04:42 PM
I get wrong TinyURL.com link.

m0nde
03-18-2009, 10:55 AM
this exported something to twitter, but didn't do it properly.

what was tweeted was
<![CDATA[BostonLove News: Version Upgrade, Database Optimization

is there something i can do to fix that?

AHealthForum
03-18-2009, 03:05 PM
this exported something to twitter, but didn't do it properly.

what was tweeted was
<![CDATA[BostonLove News: Version Upgrade, Database Optimization

is there something i can do to fix that?

I'm not sure, i've never seen it include that.

Try viewing your RSS feed in the browser and see if thats the title.

If not, try deleting the tweet, and then waiting for it to update again.

Xencored
03-18-2009, 03:15 PM
sorry for my dumbness but how do i "Enable RSS from your vBulletin Admin Control Panel." i cant find it

Thanks

AHealthForum
03-18-2009, 03:21 PM
sorry for my dumbness but how do i "Enable RSS from your vBulletin Admin Control Panel." i cant find it

Thanks

AdminCP -> vBulletin Options -> External Data provider

Xencored
03-18-2009, 03:33 PM
AdminCP -> vBulletin Options -> External Data provider

Nice one thanks works Ace <3:up:

AHealthForum
03-18-2009, 09:19 PM
Nice one thanks works Ace <3:up:

Thanks, glad to hear its working for others, thought i was going crazy and it only worked for me. :rolleyes:

Xencored
03-19-2009, 12:49 AM
Thanks, glad to hear its working for others, thought i was going crazy and it only worked for me. :rolleyes:

Well am no pro but this is my twitter page >>> http://twitter.com/animeisland <<<
Looks good to me Thanks

m0nde
03-19-2009, 07:45 AM
I'm not sure, i've never seen it include that.

Try viewing your RSS feed in the browser and see if thats the title.

If not, try deleting the tweet, and then waiting for it to update again.Thanks for the prompt reply.

I've set it up to just read my news forum. When I view what is in that feed, I see the following:

http://www.bostonlove.org/forums/external.php?f=28

There's no sign of that "cdata" code in there.

Here's the actual twitter feed:

http://twitter.com/bostonlove

rinkrat
03-19-2009, 03:37 PM
FYI, this can be done without a modification by placing the RSS feed of your forum into twitterfeed.com I do this myself for one of my more popular forums. It can also do all forums as well.

Wow! Thanks for the tip!

Brandon Sheley
03-19-2009, 04:22 PM
nice idea, I'll have to check this out sometime

puregraf
03-20-2009, 06:46 PM
it does work with PHP4 i have it working on my site, it only posted 1 post though and i put the main RSS feed for the entire forum, there should be more posts posted though.. well see

ZGeek
03-20-2009, 11:46 PM
I just set it up for my site and it works perfectly. Much better than twitterfeed.

Thanks so much for this!!

AHealthForum
03-21-2009, 06:10 AM
it does work with PHP4 i have it working on my site, it only posted 1 post though and i put the main RSS feed for the entire forum, there should be more posts posted though.. well see

It only takes your latest forum post one at a time. So whatever the last RSS feed post is, this will be your tweet when the RSS updates.

AHealthForum
03-21-2009, 06:13 AM
I just set it up for my site and it works perfectly. Much better than twitterfeed.

Thanks so much for this!!

Great glad to hear! I have to agree as well since this will let you do an unlimited amount by setting the cron to constantly run. A lot more flexibility imo by setting different cron times

AHealthForum
03-23-2009, 02:25 AM
Update: I've been using this mod since released here, which was the same day I created the Twitter account and I have 62 followers and my traffic has increased about 40%. And i've only posted 3-4 tweets myself :D

ManagerJosh
03-24-2009, 09:34 AM
Does this support multiple forum ids?

Brandon Sheley
03-25-2009, 12:47 AM
btw, how is this different than using twitfeed?
http://twitterfeed.com/

cheers

nhlchuck
03-26-2009, 10:41 PM
It only takes your latest forum post one at a time. So whatever the last RSS feed post is, this will be your tweet when the RSS updates.

What I am seeing is it is posting the same thread over and over even if there is no new post there since the last RSS update. I am doing something wrong?

http://twitter.com/DomainNameForum

AHealthForum
03-27-2009, 04:28 AM
btw, how is this different than using twitfeed?
http://twitterfeed.com/

cheers

This doesn't limit you to X amount per hour.

Doesn't rely on 3rd party site that could go down

Cheers

AHealthForum
03-27-2009, 04:30 AM
Does this support multiple forum ids?

Yes, you can put whatever forum ID you want in the RSS feed URL

AHealthForum
03-27-2009, 04:30 AM
What I am seeing is it is posting the same thread over and over even if there is no new post there since the last RSS update. I am doing something wrong?

http://twitter.com/DomainNameForum

Change the time in between the task.

AdminCP -> Scheduled Tasks -> vBulletin 2 Twitter

nhlchuck
03-27-2009, 11:45 AM
Thank you!

nhlchuck
03-28-2009, 10:28 PM
One more question, using on a different site than mentioned above. If I manually run it from scheduled tasks it works. If I don't, it never pulls the feed on it's own. Any thoughts?

motowebmaster
03-29-2009, 05:37 PM
Thanks For This.

AHealthForum
03-29-2009, 09:23 PM
One more question, using on a different site than mentioned above. If I manually run it from scheduled tasks it works. If I don't, it never pulls the feed on it's own. Any thoughts?

make sure you're getting visitors to your site and that $cronimage is in your footer.

You could also try to edit the cron times so it only runs once every 10 minutes or so rather then once a minute.

ZGeek
04-07-2009, 08:17 AM
Thanks for the prompt reply.

I've set it up to just read my news forum. When I view what is in that feed, I see the following:

http://www.bostonlove.org/forums/external.php?f=28

There's no sign of that "cdata" code in there.

Here's the actual twitter feed:

http://twitter.com/bostonlove
Any fix for this? I am also getting it. My feed http://twitter.com/zgeek

Linux123
04-07-2009, 02:35 PM
I cant find the RSS feed url

Where do I go for this.

Brandon Sheley
04-07-2009, 03:16 PM
This doesn't limit you to X amount per hour.

Doesn't rely on 3rd party site that could go down

Cheers

ah I see, I've never ran into the limit on my site.
it seems like it would just be spamming twitter if your posting to many

and twitterfeed has never gone done for me, I don't know why anyone would want to make things more complicated :p
cheers dave

Spinball
04-07-2009, 06:54 PM
I would rather use this mod than twitterfeed because I don't trust anyone with our twitter login details.
However, I would like it to check for new posts in several of our news forums every hour and post them to twitter. We would end up with maybe one new twitter update every couple of days tops, so it wouldn't be spamming.
If your mod can take the new posts from several forums and not create duplicate twitter updates, I would install it.
I appreciate the mod does what you need so you're not particularly motivated to amend it. But a simple table of posted thread ids would prevent duplicates.
Thanks.

skylab
04-08-2009, 11:58 AM
This increased my traffic by SO much. Coming close to 1000 followers by using this and many many new registers. Thanks for the mod!!!

demojames
04-09-2009, 03:10 AM
I'm using zoints-seo, and i get "Error: RSS file not found, dude." when i use the scheduled task...

I'm using vBSEO and getting the same error. :o

Did a test post and nothing. Looked at the RSS feed in a browser it's there, but no updates to Twitter.

AzH
04-09-2009, 01:24 PM
Installed and working fine. Thanks!!

Just a couple of questions though. How do I get it to pull from more than one, but not all forums. Currently I'm using .com/forums/external.php?f=4 as my feed, and I want it to be .com/forums/external.php?f=4 + 6, 7, 8, etc (but not all).

Ahh, just one question then. :)

skooby
04-09-2009, 03:39 PM
Hey,
I was "sorta" able to get this working...

I did one update yesterday in the forum it is tracking and it worked. Then today I made 3 new topics, and out of the three, two showed up in Twitter. One was the same topic I did yesterday (so it posted that twice on Twitter), and one of the topics I had just made. So out of the 3 topics I made in the forum it is tracking today, 1 showed up, 1 was out of date, and 1 didn't show at all.

All 3 show if I go directly to the RSS feed page (and are the newest in the feed).

Any idea how I can troubleshoot? This tool is great, thanks for working on it.

skylab
04-16-2009, 12:38 AM
<a href="https://twitter.com/nightlifevibe" target="_blank">http://twitter.com/nightlifevibe</a>
Getting a few issues
<![CDATA[ error comes up every now and then.
and sometimes duplicate twitter posts some with errors and some not. you can take a look at my twitter to see whats going on.

Flep
04-17-2009, 11:25 AM
I get CDATA issue too

A825F933D42B
04-19-2009, 03:41 PM
my server does not support curl. Is there a no-curl option?

skylab
04-21-2009, 12:32 PM
It's not a huge issue but hopefully the CDATA gets fixed sooner or later.

SBlueman
05-02-2009, 05:35 PM
Will this work at all for v3.6.12? I tried it and got the CDATA issue too. Might it have something to do with thread prefixes?

beachinxj
05-03-2009, 02:04 PM
Is there any way to make it not do duplicate threads other than increasing the time between script runs?

fbriceno97
05-04-2009, 03:05 AM
Got same error:

Error: RSS file not found, dude, when using the scheduled task... external.php is perfectly working as we have it on viigo, php5.... everything is ok, but that error is present.

How do i solve it?

kalliey
05-07-2009, 09:21 PM
Hy thanks for this great Hack! :-)

I´ve only one problem, my letters Ö,Ü,Ä dont´t send to twitter, how can i fix this?

sevkotr
05-13-2009, 12:59 PM
turkish characters can not be sent to twitter via this mod. is there anything which i can do to fix this?

i changed utf-8 to latin5 but did not worked.

just77me
05-14-2009, 09:09 AM
i get many duplicate threads to twitter - whats going wrong there? if there is no solution - i have to uninstall this twitter tool because i dont want to flood twitter with duplicate content and delete ist manual.

any ideas?

thank you

Vanjezi
05-15-2009, 03:34 PM
Can u make to all rss?

Its missing a lot threads posts

gordietbh
05-16-2009, 05:27 PM
here is the code I've implemented to get around the duplicate issue.

The issue arose when the latest thread was not the current status of the twitter account, so I updated the code to search the entire feed page for the thread title. It now checks the contents of your twitter page and looks for a match with the title of the first item in the RSS feed, if it finds it it does not try to repost. If it does not find a match it will call the twitter API and submit the message.

I then had an issue where it was posting <![CDATA[thread title]]. I discovered that this only occurred when there was an apostrophe in the thread title, so I added a replace command to strip out the CDATA text.

There was also an issue where if your server did not receive a response from the twitter page in a timely fashion the script would not find a match for the latest title thread and would repost. I added a line in the script to search for your account name in the page, and if it finds it then call the twitter API. This ensures that there is no more double posting.

You need to replace the contents of the twitask.php file in the includes\cron folder with the script below. You need to replace the ACCOUNTNAME text in the line http://twitter.com/ACCOUNTNAME with the name of your twitter account. this needs to be in the same case as the account name appears on your twitter page.


<?php
// vBulletin2Twitter Provided Via http://ahealthforum.com
// Inspiration from Reuqests and various free open source scripts
// twitask.php may not be reproduced without prior written permission
// See vbtotwitt.php for open source script usage
//
// Set error status
error_reporting(E_ALL & ~E_NOTICE);

// Check database connection
if (!is_object($vbulletin->db))
{
exit;
}
include_once('vbtotwitt.php');
$u = $vbulletin->options['vb2twitter_u'];
$p = $vbulletin->options['vb2twitter_p'];
$twurl = 'http://twitter.com/statuses/update.xml';
$f = $vbulletin->options['vb2twitter_f'];
$rss = new lastRSS;
if ($rs = $rss->get($f)){
$title = $rs[items][0][title];
$url = $rs[items][0][link];
} else { die('Error: RSS file not found, dude.'); }

$title = str_replace("<![CDATA[", "", "$title");
$title = str_replace("]]>", "", "$title");
$title = str_replace("&", "and", "$title");

$tiny_url = file_get_contents("http://tinyurl.com/api-create.php?url=" . $url);
$status = $title . " " . $tiny_url;
echo $status; //just for status if you are directly viewing the script

$twitterfeed = file_get_contents("http://twitter.com/ACCOUNTNAME");

$stringtocheckfor = $title;
if(strstr($twitterfeed,$stringtocheckfor)) {
echo "<br />status update already exists";
} else {

$accountstring = $vbulletin->options['vb2twitter_u'];
if(strstr($twitterfeed,$accountstring)) {

$curl_handle = curl_init();
curl_setopt($curl_handle,CURLOPT_URL,"$twurl");
curl_setopt($curl_handle,CURLOPT_CONNECTTIMEOUT,2) ;
curl_setopt($curl_handle,CURLOPT_RETURNTRANSFER,1) ;
curl_setopt($curl_handle,CURLOPT_POST,1);
curl_setopt($curl_handle,CURLOPT_POSTFIELDS,"status=$status");
curl_setopt($curl_handle,CURLOPT_USERPWD,"$u:$p");
$buffer = curl_exec($curl_handle);
curl_close($curl_handle);
if (empty($buffer)){echo '<br/>message';}else{echo '<br/>success';}

// log message
$logmsg = 'Twitter Update';

// Output Log Status
log_cron_action($logmsg, $nextitem);
} else {
echo '<br />twitter page not found';
}
}


?>



If you have $cronimage in your footer template and have the twitter scheduled task set to run every minute each time a new thread is started the title will be updated. You will also need to set the refresh time on your RSS feed in vboptions to 0 if you want to ensure that every new thread is updated to your twitted feed. If the refresh time is 60 minutes you will only have the latest thread submitted every hour when the RSS cache is refreshed.

I've been running with the above script and options for the last several days and have eliminated the duplicate posting issues.

chatzworld
05-17-2009, 11:50 AM
i have installed but twitter comes up with ERROR int he updates?

Ohiosweetheart
05-22-2009, 02:48 PM
This is a good idea. I'll be trying it out over the weekend.

BackSideSA
05-25-2009, 04:12 AM
worked for me!

GrossKopf
05-25-2009, 12:25 PM
Well, other people have posted this, but there's been no reply, so I'll post it too.

My RSS feed is correct: http://flotgaming.net/forums/external.php?f=43

If I run the task manually, I get the error: Error: RSS file not found, dude

Any fix for this?

BackSideSA
06-02-2009, 04:00 AM
correction... only works some of the times... i sometimes find that a single thread is posted up to 15 times in a row... most of the time it works, just not as frequent as i hoped.

Kolbi
06-06-2009, 07:24 AM
When i manually do the cron, I?m getting this failure message:
vBulletin to Twitter Task
ASS Stellmotor defekt ? http://tinyurl.com/o25xch
Fatal error: Call to undefined function curl_init() in /mnt/web5/32/91/5940491/htdocs/includes/cron/twitask.php on line 28

SegWayne
06-06-2009, 02:31 PM
First, thanks for the mod.

My question is this.. I have 10 different "news forums" segmented by category (see http://www.amiga.org).

ie:
----
Amiga News and Community Announcements (http://amiga.org/forums/external.php?f=2)
- Amiga Events (http://amiga.org/forums/external.php?f=35)
- Amiga.org site announcements (http://amiga.org/forums/external.php?f=16)

.... and so forth.

The problem is that the primary (container) forum is #2, but http://www.amiga.org/forums/external.php?f=2 does not show any of the RSS feeds for its sub-forums.

I need a way to select multiple forum feeds for broadcast to twitter, but NOT have to show all of the forums on the site, since all other forums are used for general discussion.

Thanks,

Wayne Hunt
Amiga.org

SegWayne
06-06-2009, 02:41 PM
I've resorted to using the twitterfeed.com

Sorry for the off topic here, but I am running 3.8.2 with RSS enabled. That part works, but no matter what I do, I cannot get twitterfeed to "parse the RSS URL". It refuses, no matter whether I use;

http://www.amiga.org/forums/external.php?f=38&type=rss
http://www.amiga.org/forums/external.php?f=38&type=rss2
http://www.amiga.org/forums/external.php?f=38&type=xml

or even

http://www.amiga.org/forums/external.php

Says something about "netscape stopped supporting this DTD in 2007" when I use RSS, otherwise, gives no ideas WHY it won't validate.

If I can't submit multiples through the request above this one, I sure would appreciate some help trying to figure out why twitterfeed hates me :)

Thanks,

Wayne Hunt
Amiga.org

Kolbi
06-08-2009, 11:46 AM
vBulletin to Twitter Task
ASS Stellmotor defekt ? http://tinyurl.com/o25xch
Fatal error: Call to undefined function curl_init() in /mnt/web5/32/91/5940491/htdocs/includes/cron/twitask.php on line 28
My problem isn?t solved yet.

SegWayne
06-09-2009, 10:43 AM
First, thanks for the mod.

My question is this.. I have 10 different "news forums" segmented by category (see http://www.amiga.org).

ie:
----
Amiga News and Community Announcements (http://amiga.org/forums/external.php?f=2)
- Amiga Events (http://amiga.org/forums/external.php?f=35)
- Amiga.org site announcements (http://amiga.org/forums/external.php?f=16)

.... and so forth.

The problem is that the primary (container) forum is #2, but http://www.amiga.org/forums/external.php?f=2 does not show any of the RSS feeds for its sub-forums.

I need a way to select multiple forum feeds for broadcast to twitter, but NOT have to show all of the forums on the site, since all other forums are used for general discussion.

Thanks,

Wayne Hunt
Amiga.org
:bump:

SBlueman
06-10-2009, 11:05 AM
You will also need to set the refresh time on your RSS feed in vboptions to 0 if you want to ensure that every new thread is updated to your twitted feed. If the refresh time is 60 minutes you will only have the latest thread submitted every hour when the RSS cache is refreshed.

How do you set this to 0?

Bram H
06-11-2009, 07:11 AM
Pretty annoying that this message pops up for so many people:
Error: RSS file not found, dude
If this mod is supported why isnt there any reply from the dev in months? Don't want to sound ungrateful or something, i respect all that can create such fantastic vB mods, but this sounds like a graveyard modification to me, sorry

***uninstalled***

SBlueman
06-12-2009, 12:59 AM
When i manually do the cron, I?m getting this failure message:

I am getting the same kind of error:
vBulletin to Twitter Task
[Rams] Rams Pass On RB's Edgerrin James, Warrick Dunn? http://tinyurl.com/l4laoz
Fatal error: Call to undefined function curl_init() in /home/sblueman/public_html/forums/includes/cron/twitask.php on line 44

***UPDATE***

I was able to fix this error by adding cURL to apache.

SBlueman
06-12-2009, 03:15 AM
I do have another question.....right now the cron job runs once a minute on my site....but it will only post 1 story per minute. There are times on my site that we may break multiple NFL news stories in that time span (we have a staff of news hounds). Is there a way for this modification to make sure it posts ALL missing stories in that minute span?

FYI....I am using the twitask.php file that gordietbh posted on page four (https://vborg.vbsupport.ru/showpost.php?p=1811982&postcount=61) of this thread.

Kolbi
06-12-2009, 10:23 AM
I was able to fix this error by adding cURL to apache.

The problem is that i?m running my board on a hostet package.

A825F933D42B
06-12-2009, 08:39 PM
I added the following code:
$title = utf8_encode ($title); //for the bloody umlaute
just after the lines fixing the CDATA-issue. Now, all Umlaute and special characters will be submitted to Twitter. Just if it helps someone else too

Kolbi
06-13-2009, 06:27 AM
I added the following code:
$title = utf8_encode ($title); //for the bloody umlaute
just after the lines fixing the CDATA-issue. Now, all Umlaute and special characters will be submitted to Twitter. Just if it helps someone else too

Bist deutsch oder? :)
Welche Datei und welche Zeile?
Ja die Umlaute sind wohl das Problem.

ade5675
06-13-2009, 10:11 PM
It works for me so far ...... but I will keep an eye for all those mentioned issues in the next few days.

Nice mod !

ryancooper
06-17-2009, 12:48 PM
You will also need to set the refresh time on your RSS feed in vboptions to 0 if you want to ensure that every new thread is updated to your twitted feed. If the refresh time is 60 minutes you will only have the latest thread submitted every hour when the RSS cache is refreshed.

Do you mean the Cache Lifespan? I didn't see a refresh... :confused:

SBlueman
06-18-2009, 12:48 PM
Well, other people have posted this, but there's been no reply, so I'll post it too.

My RSS feed is correct: http://flotgaming.net/forums/external.php?f=43

If I run the task manually, I get the error: Error: RSS file not found, dude

Any fix for this?

I moved to a new box and all the setting are completely the same. However, I am now also getting the same error message.

SBlueman
06-19-2009, 01:32 AM
Is this modification now dead? Is there anyone who can help solve the issues people are having?

SBlueman
06-19-2009, 03:25 AM
BTW, it looks like this modification is a re-write of some sorts of this open source modification:

http://paulstamatiou.com/stammy-script-rss-to-twitter-using-php

Don't know if that helps out to any of the php-saavy people out there who might be using this modification and would be willing to help us in need.

SBlueman
06-20-2009, 11:02 AM
This is now beyond frustrating....this was the perfect modification for my site's needs and now it has stopped working out of the blue and the mod author is completely AWOL even though this is marked as a supported modification.

SBlueman
06-23-2009, 09:18 AM
No support....

***uninstalled***

A825F933D42B
07-18-2009, 09:07 PM
Bist deutsch oder? :)
Welche Datei und welche Zeile?
Ja die Umlaute sind wohl das Problem.
Ja, aber ich schreib trotzdem in Englisch, f?r die anderen ;-)
Just write on line 24, of twitask.php, just where the error message of the add-on occures:
} else { die('Error: RSS file not found, dude.'); }

$title = str_replace("<![CDATA[", "", "$title");
$title = str_replace("]]>", "", "$title");
$title = str_replace("&", "and", "$title");

$title = utf8_encode ($title); //for the bloody umlaute

m2006
07-20-2009, 04:32 AM
Thank you for nice mods

Daisyboo
08-03-2009, 07:21 AM
What is the url I use to use more than one forum for Tweets?
Not sure I have this working.

hoangzu
09-23-2009, 11:10 PM
I added the following code:
$title = utf8_encode ($title); //for the bloody umlaute
just after the lines fixing the CDATA-issue. Now, all Umlaute and special characters will be submitted to Twitter. Just if it helps someone else too

Can you PL tell me where I can add this code into?
Thank you

Brandon Sheley
09-23-2009, 11:16 PM
This is now beyond frustrating....this was the perfect modification for my site's needs and now it has stopped working out of the blue and the mod author is completely AWOL even though this is marked as a supported modification.

there are several mods that do this but much better.. This one (vBulletin Tweet Poster! (https://vborg.vbsupport.ru/showthread.php?t=216346)) will even link back to your site as the source link :up:
and it works prefect ;)

SomeDude-GP
09-24-2009, 04:11 PM
rss not found.. DUDE

TurkeySub
10-25-2009, 04:31 AM
Hi,

Any chance you might consider adding the ability to monitor multiple RSS feeds? Reason being, I have news posted in various sections on the site and not all in one and having the ability to track multiple would be awesome!

Xencored
11-07-2009, 02:54 PM
vBulletin to Twitter Task
300 Video with Rammstein http://tinyurl.com/yjr2qw9
Fatal error: Call to undefined function curl_init() in /home/*********/public_html/includes/cron/twitask.php on line 28

:(

JαρŘα?σoζ
11-07-2009, 04:43 PM
Every time I click the tiny URL that linked to my forum thread it shows me an error message.

"No Thread specified. If you followed a valid link, please notify the administrator"

Can someone help me with this? Thanks before...

JαρŘα?σoζ
11-07-2009, 05:29 PM
Every time I click the tiny URL that linked to my forum thread it shows me an error message.

"No Thread specified. If you followed a valid link, please notify the administrator"

Can someone help me with this? Thanks before...

Now it works... Wew... So confused... Sometimes it works, sometimes it doesn't work !!!

LbR
11-12-2009, 04:42 PM
Just Installed Works great thanks a bunch :)

sailnet
11-19-2009, 05:51 PM
I get RSS file not found even though I am pointed properly to my external.php and have supplied a correct forumid on ?f=

sailnet
11-19-2009, 06:37 PM
this mod totally sucks. the vb people should remove the thread.

the problem with the other tweet posted is that is requires 5.2 and that sucks too

I'll jyst be satisfied with letting people post tweet individual posts for now until someone comes along with a reliable tweet poster that doesn't require everything and the kitchen sink too.

vietdjclub
01-05-2010, 11:27 PM
it's working fine on vbb4

BBR-APBT
01-18-2010, 07:38 AM
Seems to post over and over on vB 4.0.1

Reverted to twitterfeed.com

luket79
01-23-2010, 06:01 AM
Any reason why the cron runs every minute? It was making my server crawl because the cron is set to run every minute. Can there be an option for this in a future release?

MotMann
01-31-2010, 02:38 PM
AdminCP -> vBulletin Options -> External Data provider

WExternal Dat provider? I don't found that.. just "Feed- RSS, Java" Feeds settings

And what i can do, that linkbacks still be working? if i click ob linkback, then the URL goes back to my Forum.

dd009
02-16-2010, 03:28 AM
thanx for this.

-1 cron-job in my vB

I am not able to download this

KDawg08
04-03-2010, 07:34 PM
Any reason it is doing this?

<![CDATA[BTN IE/FF Toolbar 2 minutes ago via API

It shows the TITLE of the update, but the title was "BTN IE/FF Toolbar" not the <!CDATA[ part...

A825F933D42B
04-23-2010, 07:59 PM
use my updated code so it checks if the post has already been tweeted.

sweetguy2004
05-18-2010, 10:32 AM
Thanks interesting but i cannot use it coz posting adult twits i can get ban

Nano_
06-13-2010, 10:51 PM
Works in 4.0.3PL1?

NAZIA
07-15-2010, 04:59 AM
Any reason it is doing this?

<![CDATA[BTN IE/FF Toolbar 2 minutes ago via API

It shows the TITLE of the update, but the title was "BTN IE/FF Toolbar" not the <!CDATA[ part...
same problem is here with me.. is there any solution for this?:confused:

lol
even this bug is also there in the developer twitter

http://twitter.com/healthforum

NAZIA
07-15-2010, 05:45 AM
here is the code I've implemented to get around the duplicate issue.

The issue arose when the latest thread was not the current status of the twitter account, so I updated the code to search the entire feed page for the thread title. It now checks the contents of your twitter page and looks for a match with the title of the first item in the RSS feed, if it finds it it does not try to repost. If it does not find a match it will call the twitter API and submit the message.

I then had an issue where it was posting <![CDATA[thread title]]. I discovered that this only occurred when there was an apostrophe in the thread title, so I added a replace command to strip out the CDATA text.

There was also an issue where if your server did not receive a response from the twitter page in a timely fashion the script would not find a match for the latest title thread and would repost. I added a line in the script to search for your account name in the page, and if it finds it then call the twitter API. This ensures that there is no more double posting.

You need to replace the contents of the twitask.php file in the includes\cron folder with the script below. You need to replace the ACCOUNTNAME text in the line http://twitter.com/ACCOUNTNAME with the name of your twitter account. this needs to be in the same case as the account name appears on your twitter page.


<?php
// vBulletin2Twitter Provided Via http://ahealthforum.com
// Inspiration from Reuqests and various free open source scripts
// twitask.php may not be reproduced without prior written permission
// See vbtotwitt.php for open source script usage
//
// Set error status
error_reporting(E_ALL & ~E_NOTICE);

// Check database connection
if (!is_object($vbulletin->db))
{
exit;
}
include_once('vbtotwitt.php');
$u = $vbulletin->options['vb2twitter_u'];
$p = $vbulletin->options['vb2twitter_p'];
$twurl = 'http://twitter.com/statuses/update.xml';
$f = $vbulletin->options['vb2twitter_f'];
$rss = new lastRSS;
if ($rs = $rss->get($f)){
$title = $rs[items][0][title];
$url = $rs[items][0][link];
} else { die('Error: RSS file not found, dude.'); }

$title = str_replace("<![CDATA[", "", "$title");
$title = str_replace("]]>", "", "$title");
$title = str_replace("&", "and", "$title");

$tiny_url = file_get_contents("http://tinyurl.com/api-create.php?url=" . $url);
$status = $title . " " . $tiny_url;
echo $status; //just for status if you are directly viewing the script

$twitterfeed = file_get_contents("http://twitter.com/ACCOUNTNAME");

$stringtocheckfor = $title;
if(strstr($twitterfeed,$stringtocheckfor)) {
echo "<br />status update already exists";
} else {

$accountstring = $vbulletin->options['vb2twitter_u'];
if(strstr($twitterfeed,$accountstring)) {

$curl_handle = curl_init();
curl_setopt($curl_handle,CURLOPT_URL,"$twurl");
curl_setopt($curl_handle,CURLOPT_CONNECTTIMEOUT,2) ;
curl_setopt($curl_handle,CURLOPT_RETURNTRANSFER,1) ;
curl_setopt($curl_handle,CURLOPT_POST,1);
curl_setopt($curl_handle,CURLOPT_POSTFIELDS,"status=$status");
curl_setopt($curl_handle,CURLOPT_USERPWD,"$u:$p");
$buffer = curl_exec($curl_handle);
curl_close($curl_handle);
if (empty($buffer)){echo '<br/>message';}else{echo '<br/>success';}

// log message
$logmsg = 'Twitter Update';

// Output Log Status
log_cron_action($logmsg, $nextitem);
} else {
echo '<br />twitter page not found';
}
}


?>

If you have $cronimage in your footer template and have the twitter scheduled task set to run every minute each time a new thread is started the title will be updated. You will also need to set the refresh time on your RSS feed in vboptions to 0 if you want to ensure that every new thread is updated to your twitted feed. If the refresh time is 60 minutes you will only have the latest thread submitted every hour when the RSS cache is refreshed.

I've been running with the above script and options for the last several days and have eliminated the duplicate posting issues.

Nice work... working fine for me...
thanks a lot.. :)

do you have any idea about the plain text password?
why we can not use

<input type="password">in Admin Cp.
Any idea please

NAZIA
09-13-2010, 12:23 AM
btw, how is this different than using twitfeed?
http://twitterfeed.com/

cheers
:) good idea. just added my feed here... :) hope will work,, :)

:mad:Actually this mod stopped publishing feeds on twitter by 1st September. may be due to change in Twitter policies, what ever i dont know :)

Smitty
09-13-2010, 02:36 AM
btw, how is this different than using twitfeed?
http://twitterfeed.com/

cheers Been using twiterfeed for quite a while now. It works. Not every post is tweeted in big, active forums, but it is a very good automatic twitter feed. I have no use for twitter, but for 'SEO' purposes one should have a twitter account.

Dr.osamA
03-14-2011, 03:50 AM
Works in 4.1.2????

hope yes

vvdven
03-24-2011, 02:54 PM
Hi There,

I have this mod installed but it seems to also post the rss feeds from our rss widget (with external rss feeds) to our twitter account.

Is there any way to turn this off?

Thanks.

c0der
04-11-2011, 06:41 PM
thx
can u make another one for fb and other network sites

Uberguilds
05-31-2011, 10:14 PM
This move is a direct assault on services like TwitPic and yFrog. With Twitter Pictures, you’ll be able to upload from Twitter.com and the clients and you’ll get a nice, tidy URL that links to your picture (and a small thumbnail may now appear in your stream).


Threads to twitter.

Now

Forum images to twitter.



plz?
http://techcrunch.com/2011/05/31/twitter-pictures-ios5/

Bonjax
07-23-2011, 03:29 PM
If you want another option... TwitterFeed.com accomplishes this same thing and is solid as a rock. Easy to set up with some nice features. Grabs the RSS and posts thread titles to your Twitter account.

AK47-
02-22-2013, 10:02 PM
does this work on vb4.2.0?

GhostHunter2010
05-07-2020, 12:27 AM
pss this doesnt work at all