[ABD] phpBB Twitter

Any abandoned MODs will be moved to this forum.

WARNING: MODs in this forum are not currently being supported or maintained by the original MOD author. Proceed at your own risk.
Forum rules
IMPORTANT: MOD Development Forum rules

WARNING: MODs in this forum are not currently being supported nor updated by the original MOD author. Proceed at your own risk.
User avatar
Sam
Former Team Member
Posts: 2082
Joined: Thu Jan 22, 2009 3:59 am
Location: Sacramento, CA
Name: Sam Thompson
Contact:

[ABD] phpBB Twitter

Postby Sam » Fri Jan 15, 2010 4:38 am

Modification Name: phpBB Twitter
Author: SyntaxError90

Modification Description: This MOD enables a board owner to automatically tweet new posts from a designated forum and manually tweet from directly the ACP
Modification Version: 0.8.1

Requirements: PHP5 or newer (cURL NOT required)

Features:
  • Designate a board to tweet new topics from
  • Support for TinyURL, bit.ly, Tweetburner, cli.gs
  • Plugin support for URL shortening services
  • Tweet from the ACP manually
  • Tweeting API framework for your board

Screenshots:
http://i801.photobucket.com/albums/yy29 ... _mod/9.png
http://i801.photobucket.com/albums/yy29 ... _mod/8.png
http://i801.photobucket.com/albums/yy29 ... _mod/7.png
http://i801.photobucket.com/albums/yy29 ... _mod/6.png
http://i801.photobucket.com/albums/yy29 ... _mod/5.png
http://i801.photobucket.com/albums/yy29 ... _mod/4.png
http://i801.photobucket.com/albums/yy29 ... _mod/3.png
http://i801.photobucket.com/albums/yy29 ... _mod/2.png
http://i801.photobucket.com/albums/yy29 ... _mod/1.png

Modification Download:

[The extension zip has been deactivated and can no longer be displayed.]



Notes: I was playing around with some of the APIs for a website that wants something like this. I have created a Plugin system for the URL shortening services, if someone wants another URL shortener service, just post in this topic.

API Overview:
Twitter:
You can add this API to your own scripts to make it do more than it does already.
  • phpbb_twitter::tweet($message)
    Use this to tweet any message. This does NOT trim the tweet if it is over 140 characters, it will simply return false.
    returns: True on success, false on failure

  • phpbb_twitter::grab_tweets($mode [, $count = 10])
    $mode can be 'user' (meaning just your own tweets), 'friends' (yours and people you are following), or 'mention' (tweets with @<username>). This returns the tweets visible to the twitter account the board holds.
    returns array that can be foreach'ed into block vars.

  • phpbb_twitter::prepare_message($message [, $url = ''])
    Takes any $message, (grabs the short url of $url if applicable), adds twitter prefix (as defined in the acp), and makes it into a tweetable message, that is no greater than 140 characters. If $message is too long, it will cut it off at the end of a word (instead of in the middle) and add "..."
    returns a tweetable message

  • phpbb_twitter::get_short_url($long_url)
    Grabs the $long_url of the board's specified url shortening service
    retunrs short url
More documentation for URL plugin making coming soon, if you would like to make a Plugin, see the ones included in the MOD. It is quite simple.

User avatar
eunaumtenhoid
Registered User
Posts: 328
Joined: Wed Jun 03, 2009 12:46 am
Location: ????

Re: [DEV] phpBB Twitter

Postby eunaumtenhoid » Sat Jan 16, 2010 1:47 pm

nice^^

waiting for download

User avatar
battye
Extensions Team Member
Extensions Team Member
Posts: 10701
Joined: Wed Feb 11, 2004 11:02 am
Location: Australia
Contact:

Re: [DEV] phpBB Twitter

Postby battye » Sat Jan 16, 2010 2:26 pm

Ah, I was wondering what this was http://twitter.com/SyntaxError90/status/7814498088 ;)

User avatar
Sam
Former Team Member
Posts: 2082
Joined: Thu Jan 22, 2009 3:59 am
Location: Sacramento, CA
Name: Sam Thompson
Contact:

Re: [BETA] phpBB Twitter

Postby Sam » Sun Jan 17, 2010 12:51 am

First download up, enjoy ~ :)

Some API documentation added to the first post as well.

Desdenova
Registered User
Posts: 646
Joined: Sat Feb 23, 2008 7:25 pm

Re: [BETA] phpBB Twitter

Postby Desdenova » Sun Jan 17, 2010 3:32 am

Blast you, Syntax, you stole my idea. :lol:

Ather
Registered User
Posts: 1016
Joined: Fri May 08, 2009 9:42 am
Location: Kingdom of Bahrain
Name: Ather Akber

Re: [BETA] phpBB Twitter

Postby Ather » Sun Jan 17, 2010 8:58 pm

coudnt find this last edit in language\en\acp\common.php

Code: Select all

    'FORUM_TOPICS_PAGE_EXPLAIN'            => 'If non-zero this value will override the default topics per page setting.', 

did some code-hunting, found out its in language\en\acp\forums.php :D (~ Line 115 )

other than that, amazing mod :D

Edit : just refreshed my acp page, found another typo :P

it should be

Code: Select all


    
'FORUM_TWEET_TOPICS_EXPLAIN'            => 'If non-zero this value will override the default topics per page setting.',
    
'FORUM_TWEET_TOPICS'                => 'Tweet topics',
 

not

Code: Select all


    
'FORUM_TOPICS_PAGE_EXPLAIN'            => 'If non-zero this value will override the default topics per page setting.',
    
'FORUM_TWEET_TOPICS'                => 'Tweet topics',
 
CPL Syed Ather Akbar
Regional Command Southwest
Camp Leatherneck, Afghanistan

My Mods/Snippets

User avatar
Sam
Former Team Member
Posts: 2082
Joined: Thu Jan 22, 2009 3:59 am
Location: Sacramento, CA
Name: Sam Thompson
Contact:

Re: [BETA] phpBB Twitter

Postby Sam » Mon Jan 18, 2010 12:06 am

Huh, something strange went on there...
Yep, I copy-pasted the wrong two lines, New MODX:
install_mod.xml
(5.4 KiB) Downloaded 186 times

Updated to 0.8.1

User avatar
Mess
Registered User
Posts: 821
Joined: Wed Jul 01, 2009 6:37 am
Name: Kim

Re: [BETA] phpBB Twitter

Postby Mess » Mon Jan 18, 2010 9:38 am

Looking good. :)

User avatar
Anyasha
Registered User
Posts: 704
Joined: Mon Aug 07, 2006 4:02 am
Location: Macon, GA
Name: Anyasha

Re: [BETA] phpBB Twitter

Postby Anyasha » Mon Jan 18, 2010 7:19 pm

This MOD is not working for me at all. Posts do not get tweeted. I set the tweet option to "yes" in the forum I wanted and all the usernames and passwords are correct. I have used other twitter mods on my forum that worked, but I was looking for a friendlier one so I tried this one...and nothing. :(
Kiss me, I'm Polish!

User avatar
Sam
Former Team Member
Posts: 2082
Joined: Thu Jan 22, 2009 3:59 am
Location: Sacramento, CA
Name: Sam Thompson
Contact:

Re: [BETA] phpBB Twitter

Postby Sam » Mon Jan 18, 2010 7:54 pm

Anyasha wrote:This MOD is not working for me at all. Posts do not get tweeted. I set the tweet option to "yes" in the forum I wanted and all the usernames and passwords are correct. I have used other twitter mods on my forum that worked, but I was looking for a friendlier one so I tried this one...and nothing. :(

Did you try tweeting from the ACP? If that works, then the problem lies with an incorrect MOD installation with install.xml. If not, then either you have incorrect login info, or there could be something wrong.

Keep in mind this is in beta and could have some bugs.

User avatar
Anyasha
Registered User
Posts: 704
Joined: Mon Aug 07, 2006 4:02 am
Location: Macon, GA
Name: Anyasha

Re: [BETA] phpBB Twitter

Postby Anyasha » Mon Jan 18, 2010 9:32 pm

I used AutoMOD to install it. The Tweet page gives me a white page with this:

Fatal error: Uncaught exception 'Exception' with message 'String could not be parsed as XML' in /home/***/public_html/y/includes/functions_twitter.php:164 Stack trace: #0 /home/***/public_html/y/includes/functions_twitter.php(164): SimpleXMLElement->__construct('') #1 /home/***/public_html/y/includes/functions_twitter.php(131): phpbb_twitter->parse_xml(false) #2 /home/***/public_html/y/includes/acp/acp_twitter.php(107): phpbb_twitter->grab_tweets('friends', 10) #3 /home/***/public_html/y/includes/functions_module.php(517): acp_twitter->main('twitter', 'tweet') #4 /home/***/public_html/y/adm/index.php(79): p_master->load_active() #5 {main} thrown in /home/***/public_html/y/includes/functions_twitter.php on line 164
Kiss me, I'm Polish!

User avatar
Sam
Former Team Member
Posts: 2082
Joined: Thu Jan 22, 2009 3:59 am
Location: Sacramento, CA
Name: Sam Thompson
Contact:

Re: [BETA] phpBB Twitter

Postby Sam » Mon Jan 18, 2010 10:22 pm

Your login information for twitter is incorrect. I am going to include a check and proper error handling in the next version.

User avatar
Anyasha
Registered User
Posts: 704
Joined: Mon Aug 07, 2006 4:02 am
Location: Macon, GA
Name: Anyasha

Re: [BETA] phpBB Twitter

Postby Anyasha » Tue Jan 19, 2010 12:17 am

I re-typed the password in time and time again and still no go! It is the correct password, I even logged out of Twitter and back in to check. I don't know what's going on. I'll wait for the next version then.
Kiss me, I'm Polish!

Desdenova
Registered User
Posts: 646
Joined: Sat Feb 23, 2008 7:25 pm

Re: [BETA] phpBB Twitter

Postby Desdenova » Tue Jan 19, 2010 12:52 am

By the way, what version is your PHP installation, Anyasha?

User avatar
Anyasha
Registered User
Posts: 704
Joined: Mon Aug 07, 2006 4:02 am
Location: Macon, GA
Name: Anyasha

Re: [BETA] phpBB Twitter

Postby Anyasha » Tue Jan 19, 2010 1:39 am

5.2.11. I even went into the database and looked at the password there and it was correct! :?
Kiss me, I'm Polish!


Return to “[3.0.x] Abandoned MODs”

Who is online

Users browsing this forum: No registered users and 5 guests