Okay, this is a little strange. Just did a bit morre troubleshooting, found that: - That IP Address isn't associated with my domain in any way (I emailed my host to confirm) - The client ID is the one I'm using for my local web2py server, not the one I modified it too in "fbappauth.py" - There were .pyc files in my "/modules" folder, which have now been removed - I had forgotten to add "App Domains" and "Site URL" to the Facebook app
Unfortunately I still can't login with facebook, and am still being presented the same error :/ On Mon, Jul 23, 2012 at 6:40 PM, Michele Comitini <[email protected]> wrote: > The simplest thing to do is give a name of choice put that in the > developers.facebook.com configuration panel of you application. > > THEN if you want to test just add a record in you /etc/hosts file > pointing to localhost when testing locally, pointing to your server > when testing production. > > For instance put http://my.facebook.app[:port] in the configuration > panel. Remember the port i.e. if testing locally on port 8000 you > have to put that port in the configuration panel. > > ---8<---- > # hosts file > 127.0.0.1 my.facebook.app > # comment above and uncomment below when testing on remote host > # 1.2.3.4 my.facebook.app > ---8<----- > > Testing is easier is you can use same port locally or on production. > > mic > > > 2012/7/23 howesc <[email protected]>: >> facebook is a picky pain in the *** >> >> in your facebook config you set a single domain name or ip address that is >> associated with the facebook app. all redirects that you specify when >> making calls to the facebook API must be in that domain/ip address. so your >> facebook config would need to have http://58.168.6.57 as the app domain (or >> whatever they call the setting these days) based on the URL above. >> >> this makes testing a PITA. i have a plethora of facebook apps....in real >> life i use 3: 1 for localhost, 1 for test server and 1 for production (with >> a squirrelly if statement to select which set of facebook keys to use based >> on the detected server environment) >> >> if anyone has better suggestions, i'm all ears! >> >> cfh >> >> >> On Sunday, July 22, 2012 6:59:48 AM UTC-7, Alec Taylor wrote: >>> >>> I generated a new application on Facebook—added in the new CLIENT_ID >>> and CLIENT_SECRET—but when I tried to login, the URL said: >>> >>> >>> https://graph.facebook.com/oauth/authorize?scope=user_photos%2Cfriends_photos&redirect_uri=http%3A%2F%2F58.168.6.57%2Fuser%2Flogin&response_type=code&client_id=<my >>> top-secret clientID here> >>> >>> And the page said: >>> >>> { >>> "error": { >>> "message": "Invalid redirect_uri: Given URL is not allowed by >>> the Application configuration.", >>> "type": "OAuthException", >>> "code": 191 >>> } >>> } >>> >>> Here is my db.py: http://pastebin.com/zULTxA7D >>> >>> What is going wrong? — I've tried modifying all my redirects, to no avail. >>> >>> Thanks for all suggestions, >>> >>> Alec Taylor >> >> -- >> >> >> > > -- > > > --

