Re: [twitter-dev] Re: abraham / twitteroauth

2011-02-07 Thread Archia


Why are you sending users to clearsessions.php if you don't wan't the 
session data cleared? clearsessions.php is essentially a reset to simulate 
logging out of an application.

The library sends users to clearsessions.php out of the box, I was asking if 
not clearing the session data would cause problems in the library. 


-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


Re: [twitter-dev] twitteroauth and multiple domains

2011-02-07 Thread Archia
OK, I'll do so, but something I've done may be causing the following to be 
displayed after authorizing access:

The page isn't redirecting properly

Firefox has detected that the server is redirecting the request for this 
address in a way that will never complete.  

*   This problem can sometimes be caused by disabling or refusing to 
accept
  cookies.

Cookies are not disabled and config.php looks like this:

?php
/**
 * @file
 * A single location to store configuration.
 */

define('CONSUMER_KEY', myconsumerkey');
define('CONSUMER_SECRET', 'myconsumersecret');
define('OAUTH_CALLBACK', 'http://www.mysite.com/twitter/callback.php');

Can you suggest the trouble?

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


Re: [twitter-dev] twitteroauth and multiple domains

2011-02-07 Thread Archia
I think I found the trouble. I had switched the order of the lines below, 
putting config.php first:

require_once('/home/soundser/public_html/includes/twitteroauth/twitteroauth.php');
require_once('/home/soundser/public_html/includes/config.php');

Putting it back fixed the redirect.

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] twitteroauth and multiple domains

2011-02-06 Thread Archia
Hi,

twitteroauth is working under domain A, but is it necessary to reproduce all 
of the code under domain B to get it to work there. I've not been able to 
get things working beyond step 3 of the Flow Overview under domain B. I 
always end up back on connect.php under domain A.

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


Re: [twitter-dev] Re: abraham / twitteroauth

2011-02-03 Thread Archia
The reason my insert code was not inserting the client tokens in my database 
after returning from Twitter and allowing access to my application was that 
clearsessions.php was, of all things, clearing the session variables! I use 
a session variable to identify my client when they log into my site, and 
then use this to know which record in my database to insert the tokens in. 
So, I disabled the call to session_destroy() in clearsessions.php. Are there 
consequences to doing this that I need to know about, or is it OK?

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] Re: abraham / twitteroauth

2011-02-02 Thread Archia
Yes, this will be good. Are the user's oAuth token and oAuth token secret 
retrieved from these lines in index.php?:

/* Get user access tokens out of the session. */
$access_token = $_SESSION['access_token'];
$access_token['oauth_token'];
$access_token['oauth_token_secret'];

Thanks for your reply.

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


Re: [twitter-dev] abraham / twitteroauth

2011-02-02 Thread Archia
You are correct of course. I set it up that way because the only functioning 
library I found for updating a user's Twitter status required them. The 
other libraries seem to be using basic authentication which caused them to 
fail. I'm finding oAuth challenging to use as well.

Thanks

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


Re: [twitter-dev] Re: abraham / twitteroauth

2011-02-02 Thread Archia
On Wednesday, February 2, 2011 1:29:08 PM UTC-5, Abraham Williams wrote:

 callback.php provides a good spot for saving access_tokens to a persistant 
 storage. 

 https://github.com/abraham/twitteroauth/blob/master/callback.php#L34

 Abraham
 -
 Abraham Williams | Hacker Advocate | abrah.am
 @abraham https://twitter.com/abraham | github.com/abraham | 
 blog.abrah.am
 This email is: [ ] shareable [x] ask first [ ] private.



 On Wed, Feb 2, 2011 at 07:15, Archia tomarc...@gmail.com wrote:

 Yes, this will be good. Are the user's oAuth token and oAuth token secret 
 retrieved from these lines in index.php?:

 /* Get user access tokens out of the session. */
 $access_token = $_SESSION['access_token'];
 $access_token['oauth_token'];
 $access_token['oauth_token_secret'];

 Thanks for your reply.

  -- 
 Twitter developer documentation and resources: http://dev.twitter.com/doc
 API updates via Twitter: http://twitter.com/twitterapi
 Issues/Enhancements Tracker: 
 http://code.google.com/p/twitter-api/issues/list
 Change your membership to this group: 
 http://groups.google.com/group/twitter-development-talk



Yes thanks, I found that. I added code to save the access tokens, but didn't 
get it quite right. I know this because I see the Twitter account that I'm 
connecting to has allowed my application access, but the tokens did not get 
inserted in my database. To troubleshoot my insert code, I'd like to restart 
the routine by revoking access to my application for this account at 
Twitter. Will this just prompt the Allow or Deny dialog again, or will it 
permanently revoke the access?

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk


[twitter-dev] abraham / twitteroauth

2011-02-01 Thread Archia
I have a web application to allow clients to update information for their 
recordings (music) which are then listed on another site. I'd like to 
include an area to allow them to update their Twitter status. Given that 
each client already signs in to the current application, and (some of) their 
Twitter usernames and passwords are already in a database, it would be good 
if they did not need to log in to Twitter as well and select 'Allow' each 
time they visit that area of the application. Is it possible to bypass the 
Sign in with Twitter step on connect.php and somehow send their username and 
password, or at least only require this once and store their credentials in 
the database to be used thereafter?

Thanks!

-- 
Twitter developer documentation and resources: http://dev.twitter.com/doc
API updates via Twitter: http://twitter.com/twitterapi
Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list
Change your membership to this group: 
http://groups.google.com/group/twitter-development-talk