From bjclark at scidept.com Thu Jan 3 22:26:54 2008 From: bjclark at scidept.com (BJ Clark) Date: Thu, 3 Jan 2008 20:26:54 -0700 Subject: [Facebooker-talk] Nested Routes + Facebook Resources Message-ID: Does anyone have nested routes working with the facebook_resources method? My routes.rb has: map.facebook_resources :users do |users| users.facebook_resources :images users.facebook_resources :connections end but user_connections_url won't generate. "rake routes" gives me: new_user POST /users/new {:action=>"new", :controller=>"users"} users POST /users/index {:action=>"index", :controller=>"users"} show_user POST /users/:id/show {:action=>"show", :controller=>"users"} create_user POST /users/create {:action=>"create", :controller=>"users"} edit_user POST /users/:id/edit {:action=>"edit", :controller=>"users"} update_user POST /users/:id/update {:action=>"update", :controller=>"users"} destroy_user POST /users/:id/destroy {:action=>"destroy", :controller=>"users"} /:controller/:action/:id.:format /:controller/:action/:id / {:action=>"index", :controller=>"main"} And that's it. Am I missing something obvious here or does the current implementation just not work for nested routes? Thanks everyone! P.S. I'm new. Love facebooker. I was fighting with rFacebook for a week and I found facebooker and it was love at first POST request. ----- BJ Clark the science department bjclark at scidept.com www.scidept.com From heavysixer at gmail.com Thu Jan 3 23:16:11 2008 From: heavysixer at gmail.com (Heavy Sixer) Date: Thu, 3 Jan 2008 22:16:11 -0600 Subject: [Facebooker-talk] Nested Routes + Facebook Resources In-Reply-To: References: Message-ID: <7E6F2439-4E5B-4EC5-9167-F26F0CFC4F12@gmail.com> Hi BJ, My suggestion would be to do "rake routes". It will print out all the routes that are dynamically generated for you. It is very helpful in tracking things down. In my app i ended up not even using the map.facebook_resources and it worked great for me. I did however map some "top level" actions that are convenient for the facebook app like this: map.connect 'installed', :controller => 'users', :action => 'installed' map.connect 'uninstalled', :controller => 'users', :action => 'uninstalled' map.connect 'about', :controller => 'users', :action => 'about' map.connect 'help', :controller => 'users', :action => 'help' map.connect 'privacy', :controller => 'users', :action => 'privacy' Hope that helps, Mark On Jan 3, 2008, at 9:26 PM, BJ Clark wrote: > Does anyone have nested routes working with the facebook_resources > method? > My routes.rb has: > > map.facebook_resources :users do |users| > users.facebook_resources :images > users.facebook_resources :connections > end > > but user_connections_url won't generate. > "rake routes" gives me: > new_user POST /users/new > {:action=>"new", :controller=>"users"} > users POST /users/index > {:action=>"index", :controller=>"users"} > show_user POST /users/:id/show > {:action=>"show", :controller=>"users"} > create_user POST /users/create > {:action=>"create", :controller=>"users"} > edit_user POST /users/:id/edit > {:action=>"edit", :controller=>"users"} > update_user POST /users/:id/update > {:action=>"update", :controller=>"users"} > destroy_user POST /users/:id/destroy > {:action=>"destroy", :controller=>"users"} > /:controller/:action/:id.:format > /:controller/:action/:id > / > {:action=>"index", :controller=>"main"} > > And that's it. > Am I missing something obvious here or does the current implementation > just not work for nested routes? > Thanks everyone! > > P.S. I'm new. Love facebooker. I was fighting with rFacebook for a > week and I found facebooker and it was love at first POST request. > ----- > BJ Clark > the science department > bjclark at scidept.com > www.scidept.com > > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From shanev at gmail.com Fri Jan 4 10:59:23 2008 From: shanev at gmail.com (Shane Vitarana) Date: Fri, 4 Jan 2008 15:59:23 +0000 Subject: [Facebooker-talk] Nested Routes + Facebook Resources In-Reply-To: References: Message-ID: <4ab757a40801040759g21a7fb2djc6ccd1653745e44@mail.gmail.com> BJ- facebook_resources doesn't work with nested routes yet. It will most likely be replaced with with just map.resources. I suggest just creating named routes manually for now. Shane On Jan 4, 2008 3:26 AM, BJ Clark wrote: > Does anyone have nested routes working with the facebook_resources > method? > My routes.rb has: > > map.facebook_resources :users do |users| > users.facebook_resources :images > users.facebook_resources :connections > end > > but user_connections_url won't generate. > "rake routes" gives me: > new_user POST /users/new > {:action=>"new", :controller=>"users"} > users POST /users/index > {:action=>"index", :controller=>"users"} > show_user POST /users/:id/show > {:action=>"show", :controller=>"users"} > create_user POST /users/create > {:action=>"create", :controller=>"users"} > edit_user POST /users/:id/edit > {:action=>"edit", :controller=>"users"} > update_user POST /users/:id/update > {:action=>"update", :controller=>"users"} > destroy_user POST /users/:id/destroy > {:action=>"destroy", :controller=>"users"} > /:controller/:action/:id.:format > /:controller/:action/:id > / > {:action=>"index", :controller=>"main"} > > And that's it. > Am I missing something obvious here or does the current implementation > just not work for nested routes? > Thanks everyone! > > P.S. I'm new. Love facebooker. I was fighting with rFacebook for a > week and I found facebooker and it was love at first POST request. > ----- > BJ Clark > the science department > bjclark at scidept.com > www.scidept.com > > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From mmangino at elevatedrails.com Thu Jan 10 11:07:12 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Thu, 10 Jan 2008 10:07:12 -0600 Subject: [Facebooker-talk] A best practices question Message-ID: <413A5C47-7740-4A04-984E-9E20A8B7DD2D@elevatedrails.com> Hey everyone. I've got a best practices question. How are you guys rendering newsfeeds? We have a couple of apps where we send newsfeed items from a backend process. As such, we aren't in the context of a controller and can't use the rails template rendering. We've tried about 3 different ways to make that bearable, but aren't having much luck. Is anyone using a cool trick to get access to all of our great rails helpers? Mike -- Mike Mangino http://www.elevatedrails.com From heavysixer at gmail.com Thu Jan 10 11:13:20 2008 From: heavysixer at gmail.com (Heavy Sixer) Date: Thu, 10 Jan 2008 10:13:20 -0600 Subject: [Facebooker-talk] A best practices question In-Reply-To: <413A5C47-7740-4A04-984E-9E20A8B7DD2D@elevatedrails.com> References: <413A5C47-7740-4A04-984E-9E20A8B7DD2D@elevatedrails.com> Message-ID: hey Mike, I am using render_to_string and that seems to work well for me. Would that work ok for your situation? message_text = render_to_string(:template => 'facebook_accounts/ send_to_friend_message', :layout => false) facebook_session.send_notification(@ids, message_text) unless @ids.empty? Later, Mark On Jan 10, 2008, at 10:07 AM, Mike Mangino wrote: > Hey everyone. I've got a best practices question. How are you guys > rendering newsfeeds? We have a couple of apps where we send newsfeed > items from a backend process. As such, we aren't in the context of a > controller and can't use the rails template rendering. We've tried > about 3 different ways to make that bearable, but aren't having much > luck. Is anyone using a cool trick to get access to all of our great > rails helpers? > > Mike > -- > Mike Mangino > http://www.elevatedrails.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From david.g.clements at gmail.com Thu Jan 10 12:03:48 2008 From: david.g.clements at gmail.com (David Clements) Date: Thu, 10 Jan 2008 10:03:48 -0700 Subject: [Facebooker-talk] A best practices question In-Reply-To: References: <413A5C47-7740-4A04-984E-9E20A8B7DD2D@elevatedrails.com> Message-ID: I have a two pronged approach to this. My situation is a little unique since we are integrating a free standing site into Facebook, so I have a lot of code that I don't want to rewrite. 1) I am actually using ActionMailer rendering. The first thing I did was to create ActionMailer template for text/fbml. Then I hacked ARMailer to pull out any part that was 'text/fbml' and use that content to send out. 2) I created a background Facebook communication process that works is a similar way to ar_mailer. It provides an API for create Stories, Actions and Emails to be sent to facebook. Then a background process , running from cron, pops these off the queue and uses Facebooker API to send them to facebook. I am not sure if the code is generally useful but let me know if you want to look at it and I will put it out on svn somewhere. Dave On Jan 10, 2008 9:13 AM, Heavy Sixer wrote: > hey Mike, > I am using render_to_string and that seems to work well for me. Would > that work ok for your situation? > > message_text = render_to_string(:template => 'facebook_accounts/ > send_to_friend_message', :layout => false) > facebook_session.send_notification(@ids, message_text) unless > @ids.empty? > > Later, > Mark > > > On Jan 10, 2008, at 10:07 AM, Mike Mangino wrote: > > > Hey everyone. I've got a best practices question. How are you guys > > rendering newsfeeds? We have a couple of apps where we send newsfeed > > items from a backend process. As such, we aren't in the context of a > > controller and can't use the rails template rendering. We've tried > > about 3 different ways to make that bearable, but aren't having much > > luck. Is anyone using a cool trick to get access to all of our great > > rails helpers? > > > > Mike > > -- > > Mike Mangino > > http://www.elevatedrails.com > > > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From digidigo at gmail.com Thu Jan 10 17:21:50 2008 From: digidigo at gmail.com (David Clements) Date: Thu, 10 Jan 2008 15:21:50 -0700 Subject: [Facebooker-talk] A best practices question In-Reply-To: References: <413A5C47-7740-4A04-984E-9E20A8B7DD2D@elevatedrails.com> Message-ID: I have a two pronged approach to this. My situation is a little unique since we are integrating a free standing site into Facebook, so I have a lot of code that I don't want to rewrite. 1) I am actually using ActionMailer rendering. The first thing I did was to create ActionMailer template for text/fbml. Then I hacked ARMailer to pull out any part that was 'text/fbml' and use that content to send out. 2) I created a background Facebook communication process that works is a similar way to ar_mailer. It provides an API for create Stories, Actions and Emails to be sent to facebook. Then a background process , running from cron, pops these off the queue and uses Facebooker API to send them to facebook. I am not sure if the code is generally useful but let me know if you want to look at it and I will put it out on svn somewhere. Dave On Jan 10, 2008 9:13 AM, Heavy Sixer wrote: > hey Mike, > I am using render_to_string and that seems to work well for me. Would > that work ok for your situation? > > message_text = render_to_string(:template => 'facebook_accounts/ > send_to_friend_message', :layout => false) > facebook_session.send_notification(@ids, message_text) unless > @ids.empty? > > Later, > Mark > > > On Jan 10, 2008, at 10:07 AM, Mike Mangino wrote: > > > Hey everyone. I've got a best practices question. How are you guys > > rendering newsfeeds? We have a couple of apps where we send newsfeed > > items from a backend process. As such, we aren't in the context of a > > controller and can't use the rails template rendering. We've tried > > about 3 different ways to make that bearable, but aren't having much > > luck. Is anyone using a cool trick to get access to all of our great > > rails helpers? > > > > Mike > > -- > > Mike Mangino > > http://www.elevatedrails.com > > > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From barooo at gmail.com Fri Jan 11 11:34:03 2008 From: barooo at gmail.com (John Richardson) Date: Fri, 11 Jan 2008 10:34:03 -0600 Subject: [Facebooker-talk] couple of newbie questions about redirects Message-ID: <3f4b08d0801110834g7efb61eau70e9c832c3918ab1@mail.gmail.com> I'm working on an app, and am new to both ruby and facebooker. Here is my current area of confusion: What should happen on a user's initial visit to my app? When I hit apps.facebook.com/ for the first time with no cookies or sessions or anything, I'm asked if I want to log into the app, etc., and am then redirected to my callback url outside of facebook. This raises Facebooker::Session::IncorrectSignature. Once I get this error, however, if I then go back to the canvas page, it pulls in the fbml from my controller just fine, and everything works. Should my app immediately go to the canvas page when a user authenticates to it, or is there a convention for what the base callback page should look like? And what is missing in my configuration such that I have to be in the canvas to avoid the errors? Currently all of my routes live in the same controller. From digidigo at gmail.com Fri Jan 11 14:19:38 2008 From: digidigo at gmail.com (David Clements) Date: Fri, 11 Jan 2008 12:19:38 -0700 Subject: [Facebooker-talk] Bebo at 100% Message-ID: http://www.readwriteweb.com/archives/bebo_opens_up_100_percent.php Bebo Opens Up 100% in Bid For More Third Party Apps Written by Richard MacManus / January 10, 2008 6:50 PM / 2 Comments Following the December announcement that social network Bebo was aligning itself to the Facebook platform, the company announced today that the Bebo Open Application Platform is "100% open" ? meaning that any 3rd party developer can deploy their applications on Bebo. Anyone working on this yet? I don't have the thumbs up from my client yet, but might jump on it soon. Dave From digidigo at gmail.com Fri Jan 11 15:26:30 2008 From: digidigo at gmail.com (David Clements) Date: Fri, 11 Jan 2008 13:26:30 -0700 Subject: [Facebooker-talk] couple of newbie questions about redirects In-Reply-To: <3f4b08d0801110834g7efb61eau70e9c832c3918ab1@mail.gmail.com> References: <3f4b08d0801110834g7efb61eau70e9c832c3918ab1@mail.gmail.com> Message-ID: Hey John, What do you mean by callback url outside of facebook? The user doesn't leave facebook do they? This is how I understand the authentication flow. 1) User clicks on your app 2) Facebook makes a call to the callback url a) This controller requires that either the user is authenticated to facebook or that the application is added by the user b) Facebook shows the appropriate "log in" or "add this app" form c) User clicks okay 3) Facebook makes a call to the callback url again and now your before filter lets the request pass through to your controller. I have ensure_application_is_installed_by_facebook_user at the top of application.rb Are you using IFrames? I had that error yesterday with IFRames. Dave On Jan 11, 2008 9:34 AM, John Richardson wrote: > I'm working on an app, and am new to both ruby and facebooker. Here > is my current area of confusion: > > What should happen on a user's initial visit to my app? When I hit > apps.facebook.com/ for the first time with no cookies or > sessions or anything, I'm asked if I want to log into the app, etc., > and am then redirected to my callback url outside of facebook. This > raises Facebooker::Session::IncorrectSignature. Once I get this > error, however, if I then go back to the canvas page, it pulls in the > fbml from my controller just fine, and everything works. Should my > app immediately go to the canvas page when a user authenticates to it, > or is there a convention for what the base callback page should look > like? And what is missing in my configuration such that I have to be > in the canvas to avoid the errors? > > Currently all of my routes live in the same controller. > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From barooo at gmail.com Fri Jan 11 15:37:45 2008 From: barooo at gmail.com (John Richardson) Date: Fri, 11 Jan 2008 14:37:45 -0600 Subject: [Facebooker-talk] couple of newbie questions about redirects In-Reply-To: References: <3f4b08d0801110834g7efb61eau70e9c832c3918ab1@mail.gmail.com> Message-ID: <3f4b08d0801111237o6f76f729na4b8167d977e5c91@mail.gmail.com> I meant that after logging in to my app, the user was being sent to http://my.server/callback/path, as configured in facebook, instead of http://apps.facebook.com/myapp, as seems to be required to use the library. I am not using iframes, although I was at one point so I could use localhost for hosting, but now I have a publically accessible host. I changed the facebook configuration to ask/require that the user install the app and was given extra configuration options to specify a post-install URL (which I set to my canvas URL) and now it's working as I expected. I still can't use any controller in the app, even if no filters are given, outside of the canvas, not even an empty one created by: script/generate foo index hitting /foo raises the same invalid signature error as mentioned before. Progress is being made, though! On Jan 11, 2008 2:26 PM, David Clements wrote: > Hey John, > > What do you mean by callback url outside of facebook? The user > doesn't leave facebook do they? > > This is how I understand the authentication flow. > > 1) User clicks on your app > 2) Facebook makes a call to the callback url > a) This controller requires that either the user is authenticated > to facebook or that the application is added by the user > b) Facebook shows the appropriate "log in" or "add this app" form > c) User clicks okay > 3) Facebook makes a call to the callback url again and now your before > filter lets the request pass through to your controller. > > > I have ensure_application_is_installed_by_facebook_user at the top of > application.rb > > Are you using IFrames? I had that error yesterday with IFRames. > > > Dave > > > > > > On Jan 11, 2008 9:34 AM, John Richardson wrote: > > I'm working on an app, and am new to both ruby and facebooker. Here > > is my current area of confusion: > > > > What should happen on a user's initial visit to my app? When I hit > > apps.facebook.com/ for the first time with no cookies or > > sessions or anything, I'm asked if I want to log into the app, etc., > > and am then redirected to my callback url outside of facebook. This > > raises Facebooker::Session::IncorrectSignature. Once I get this > > error, however, if I then go back to the canvas page, it pulls in the > > fbml from my controller just fine, and everything works. Should my > > app immediately go to the canvas page when a user authenticates to it, > > or is there a convention for what the base callback page should look > > like? And what is missing in my configuration such that I have to be > > in the canvas to avoid the errors? > > > > Currently all of my routes live in the same controller. > > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From digidigo at gmail.com Fri Jan 11 15:53:42 2008 From: digidigo at gmail.com (David Clements) Date: Fri, 11 Jan 2008 13:53:42 -0700 Subject: [Facebooker-talk] couple of newbie questions about redirects In-Reply-To: <3f4b08d0801111237o6f76f729na4b8167d977e5c91@mail.gmail.com> References: <3f4b08d0801110834g7efb61eau70e9c832c3918ab1@mail.gmail.com> <3f4b08d0801111237o6f76f729na4b8167d977e5c91@mail.gmail.com> Message-ID: Okay cool, sounds like we have a similar setup now. In order to hit a controller outside of facebook you will need to skip the before filters that require facebook authentication. Or alternately move ensure_application_is_installed_by_facebook_user to just the controllers that are facebook specific. One caveat to this , that I have noticed, is that there is a before_filter for set_fbml_format that I have had to skip as well when calling actions without the facebook authentication params. Dave On Jan 11, 2008 1:37 PM, John Richardson wrote: > I meant that after logging in to my app, the user was being sent to > http://my.server/callback/path, as configured in facebook, instead of > http://apps.facebook.com/myapp, as seems to be required to use the > library. I am not using iframes, although I was at one point so I > could use localhost for hosting, but now I have a publically > accessible host. > > I changed the facebook configuration to ask/require that the user > install the app and was given extra configuration options to specify a > post-install URL (which I set to my canvas URL) and now it's working > as I expected. > > I still can't use any controller in the app, even if no filters are > given, outside of the canvas, not even an empty one created by: > script/generate foo index > > hitting /foo raises the same invalid signature error as mentioned before. > > Progress is being made, though! > > > On Jan 11, 2008 2:26 PM, David Clements wrote: > > Hey John, > > > > What do you mean by callback url outside of facebook? The user > > doesn't leave facebook do they? > > > > This is how I understand the authentication flow. > > > > 1) User clicks on your app > > 2) Facebook makes a call to the callback url > > a) This controller requires that either the user is authenticated > > to facebook or that the application is added by the user > > b) Facebook shows the appropriate "log in" or "add this app" form > > c) User clicks okay > > 3) Facebook makes a call to the callback url again and now your before > > filter lets the request pass through to your controller. > > > > > > I have ensure_application_is_installed_by_facebook_user at the top of > > application.rb > > > > Are you using IFrames? I had that error yesterday with IFRames. > > > > > > Dave > > > > > > > > > > > > On Jan 11, 2008 9:34 AM, John Richardson wrote: > > > I'm working on an app, and am new to both ruby and facebooker. Here > > > is my current area of confusion: > > > > > > What should happen on a user's initial visit to my app? When I hit > > > apps.facebook.com/ for the first time with no cookies or > > > sessions or anything, I'm asked if I want to log into the app, etc., > > > and am then redirected to my callback url outside of facebook. This > > > raises Facebooker::Session::IncorrectSignature. Once I get this > > > error, however, if I then go back to the canvas page, it pulls in the > > > fbml from my controller just fine, and everything works. Should my > > > app immediately go to the canvas page when a user authenticates to it, > > > or is there a convention for what the base callback page should look > > > like? And what is missing in my configuration such that I have to be > > > in the canvas to avoid the errors? > > > > > > Currently all of my routes live in the same controller. > > > > > _______________________________________________ > > > Facebooker-talk mailing list > > > Facebooker-talk at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > > > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > > From mmangino at elevatedrails.com Sat Jan 12 10:17:31 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Sat, 12 Jan 2008 09:17:31 -0600 Subject: [Facebooker-talk] couple of newbie questions about redirects In-Reply-To: References: <3f4b08d0801110834g7efb61eau70e9c832c3918ab1@mail.gmail.com> <3f4b08d0801111237o6f76f729na4b8167d977e5c91@mail.gmail.com> Message-ID: <87FCC2C1-1AFA-436A-97AD-42A28608551F@elevatedrails.com> Good catch David. I have a fix for this in one of my local facebooker repos. I have a bunch of fixes for little things like this and some new helpers to add. I'll try to get all of that committed tomorrow. If anyone is doing both Facebook and non-facebook in the same app and having troubles, please speak up. I'd love to hear what the gotchas are so that we can fix them. I'd love to hear of any issues with nested controllers as well. On Jan 11, 2008, at 2:53 PM, David Clements wrote: > Okay cool, sounds like we have a similar setup now. > > In order to hit a controller outside of facebook you will need to skip > the before filters that require facebook authentication. Or > alternately move ensure_application_is_installed_by_facebook_user to > just the controllers that are facebook specific. > > One caveat to this , that I have noticed, is that there is a > before_filter for set_fbml_format that I have had to skip as well when > calling actions without the facebook authentication params. > > > Dave > > On Jan 11, 2008 1:37 PM, John Richardson wrote: >> I meant that after logging in to my app, the user was being sent to >> http://my.server/callback/path, as configured in facebook, instead of >> http://apps.facebook.com/myapp, as seems to be required to use the >> library. I am not using iframes, although I was at one point so I >> could use localhost for hosting, but now I have a publically >> accessible host. >> >> I changed the facebook configuration to ask/require that the user >> install the app and was given extra configuration options to >> specify a >> post-install URL (which I set to my canvas URL) and now it's working >> as I expected. >> >> I still can't use any controller in the app, even if no filters are >> given, outside of the canvas, not even an empty one created by: >> script/generate foo index >> >> hitting /foo raises the same invalid signature error as mentioned >> before. >> >> Progress is being made, though! >> >> >> On Jan 11, 2008 2:26 PM, David Clements wrote: >>> Hey John, >>> >>> What do you mean by callback url outside of facebook? The user >>> doesn't leave facebook do they? >>> >>> This is how I understand the authentication flow. >>> >>> 1) User clicks on your app >>> 2) Facebook makes a call to the callback url >>> a) This controller requires that either the user is >>> authenticated >>> to facebook or that the application is added by the user >>> b) Facebook shows the appropriate "log in" or "add this app" >>> form >>> c) User clicks okay >>> 3) Facebook makes a call to the callback url again and now your >>> before >>> filter lets the request pass through to your controller. >>> >>> >>> I have ensure_application_is_installed_by_facebook_user at the top >>> of >>> application.rb >>> >>> Are you using IFrames? I had that error yesterday with IFRames. >>> >>> >>> Dave >>> >>> >>> >>> >>> >>> On Jan 11, 2008 9:34 AM, John Richardson wrote: >>>> I'm working on an app, and am new to both ruby and facebooker. >>>> Here >>>> is my current area of confusion: >>>> >>>> What should happen on a user's initial visit to my app? When I hit >>>> apps.facebook.com/ for the first time with no cookies or >>>> sessions or anything, I'm asked if I want to log into the app, >>>> etc., >>>> and am then redirected to my callback url outside of facebook. >>>> This >>>> raises Facebooker::Session::IncorrectSignature. Once I get this >>>> error, however, if I then go back to the canvas page, it pulls in >>>> the >>>> fbml from my controller just fine, and everything works. Should my >>>> app immediately go to the canvas page when a user authenticates >>>> to it, >>>> or is there a convention for what the base callback page should >>>> look >>>> like? And what is missing in my configuration such that I have >>>> to be >>>> in the canvas to avoid the errors? >>>> >>>> Currently all of my routes live in the same controller. >>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >> > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From mmangino at elevatedrails.com Sat Jan 12 10:22:40 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Sat, 12 Jan 2008 09:22:40 -0600 Subject: [Facebooker-talk] Bebo at 100% In-Reply-To: References: Message-ID: <3CF85054-2897-404C-B80C-8C07AE3E34D0@elevatedrails.com> I'm incredibly excited about this. It looks like we can very easily support the basics. We're doing a really big application release for a client in about a week, after that, I'll try to get started on this. I would like to start by allowing you to run your app either in Facebook mode or Beebo mode. Once we have them both working, we can look at allowing one code base to run both at the same time. Does that sound sane? Mike On Jan 11, 2008, at 1:19 PM, David Clements wrote: > http://www.readwriteweb.com/archives/bebo_opens_up_100_percent.php > > > Bebo Opens Up 100% in Bid For More Third Party Apps > Written by Richard MacManus / January 10, 2008 6:50 PM / 2 Comments > > > > Following the December announcement that social network Bebo was > aligning itself to the Facebook platform, the company announced today > that the Bebo Open Application Platform is "100% open" ? meaning that > any 3rd party developer can deploy their applications on Bebo. > > > > > Anyone working on this yet? I don't have the thumbs up from my client > yet, but might jump on it soon. > > Dave > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From heavysixer at gmail.com Sat Jan 12 10:36:25 2008 From: heavysixer at gmail.com (Heavy Sixer) Date: Sat, 12 Jan 2008 09:36:25 -0600 Subject: [Facebooker-talk] couple of newbie questions about redirects In-Reply-To: <87FCC2C1-1AFA-436A-97AD-42A28608551F@elevatedrails.com> References: <3f4b08d0801110834g7efb61eau70e9c832c3918ab1@mail.gmail.com> <3f4b08d0801111237o6f76f729na4b8167d977e5c91@mail.gmail.com> <87FCC2C1-1AFA-436A-97AD-42A28608551F@elevatedrails.com> Message-ID: <26DF361B-472F-41F8-A0A6-9E215C4E80E6@gmail.com> Hi Mike, I am speaking up like you asked :-) I am still having problems with the facebook app name being appended to non-facebook controllers i.e. i have an app "my_app" i'll get something like this from an action new_sessions_path '/my_app/ sessions/new', even though the sessions controller is outside of the context of the facebook controller. I tracked this down to the url_rewriter methods but have been unable to isolate it because of how deep the rewriters hook into rails. The second problem i've noticed (and this might be facebook and not facebooker related) is that when you give someone access to the app in a login context (i.e. they don't have to install the application) the first time they are granted access to the app facebook redirects them to the naked callback url, which again happens outside of those facebook apps that are nestled into just a controller. Do you know any way around that? BTW, I am working on a skeleton app, which I could provide as a replacement for the kitchen sink app if anyone is interested. Later, Mark On Jan 12, 2008, at 9:17 AM, Mike Mangino wrote: > Good catch David. I have a fix for this in one of my local facebooker > repos. I have a bunch of fixes for little things like this and some > new helpers to add. I'll try to get all of that committed tomorrow. > > If anyone is doing both Facebook and non-facebook in the same app and > having troubles, please speak up. I'd love to hear what the gotchas > are so that we can fix them. I'd love to hear of any issues with > nested controllers as well. > > On Jan 11, 2008, at 2:53 PM, David Clements wrote: > >> Okay cool, sounds like we have a similar setup now. >> >> In order to hit a controller outside of facebook you will need to >> skip >> the before filters that require facebook authentication. Or >> alternately move ensure_application_is_installed_by_facebook_user to >> just the controllers that are facebook specific. >> >> One caveat to this , that I have noticed, is that there is a >> before_filter for set_fbml_format that I have had to skip as well >> when >> calling actions without the facebook authentication params. >> >> >> Dave >> >> On Jan 11, 2008 1:37 PM, John Richardson wrote: >>> I meant that after logging in to my app, the user was being sent to >>> http://my.server/callback/path, as configured in facebook, >>> instead of >>> http://apps.facebook.com/myapp, as seems to be required to use the >>> library. I am not using iframes, although I was at one point so I >>> could use localhost for hosting, but now I have a publically >>> accessible host. >>> >>> I changed the facebook configuration to ask/require that the user >>> install the app and was given extra configuration options to >>> specify a >>> post-install URL (which I set to my canvas URL) and now it's working >>> as I expected. >>> >>> I still can't use any controller in the app, even if no filters are >>> given, outside of the canvas, not even an empty one created by: >>> script/generate foo index >>> >>> hitting /foo raises the same invalid signature error as mentioned >>> before. >>> >>> Progress is being made, though! >>> >>> >>> On Jan 11, 2008 2:26 PM, David Clements wrote: >>>> Hey John, >>>> >>>> What do you mean by callback url outside of facebook? The user >>>> doesn't leave facebook do they? >>>> >>>> This is how I understand the authentication flow. >>>> >>>> 1) User clicks on your app >>>> 2) Facebook makes a call to the callback url >>>> a) This controller requires that either the user is >>>> authenticated >>>> to facebook or that the application is added by the user >>>> b) Facebook shows the appropriate "log in" or "add this app" >>>> form >>>> c) User clicks okay >>>> 3) Facebook makes a call to the callback url again and now your >>>> before >>>> filter lets the request pass through to your controller. >>>> >>>> >>>> I have ensure_application_is_installed_by_facebook_user at the top >>>> of >>>> application.rb >>>> >>>> Are you using IFrames? I had that error yesterday with IFRames. >>>> >>>> >>>> Dave >>>> >>>> >>>> >>>> >>>> >>>> On Jan 11, 2008 9:34 AM, John Richardson wrote: >>>>> I'm working on an app, and am new to both ruby and facebooker. >>>>> Here >>>>> is my current area of confusion: >>>>> >>>>> What should happen on a user's initial visit to my app? When I >>>>> hit >>>>> apps.facebook.com/ for the first time with no cookies or >>>>> sessions or anything, I'm asked if I want to log into the app, >>>>> etc., >>>>> and am then redirected to my callback url outside of facebook. >>>>> This >>>>> raises Facebooker::Session::IncorrectSignature. Once I get this >>>>> error, however, if I then go back to the canvas page, it pulls in >>>>> the >>>>> fbml from my controller just fine, and everything works. >>>>> Should my >>>>> app immediately go to the canvas page when a user authenticates >>>>> to it, >>>>> or is there a convention for what the base callback page should >>>>> look >>>>> like? And what is missing in my configuration such that I have >>>>> to be >>>>> in the canvas to avoid the errors? >>>>> >>>>> Currently all of my routes live in the same controller. >>>> >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From geraldbauer2007 at gmail.com Sat Jan 12 13:03:15 2008 From: geraldbauer2007 at gmail.com (Gerald Bauer) Date: Sat, 12 Jan 2008 10:03:15 -0800 Subject: [Facebooker-talk] couple of newbie questions about redirects In-Reply-To: <26DF361B-472F-41F8-A0A6-9E215C4E80E6@gmail.com> References: <3f4b08d0801110834g7efb61eau70e9c832c3918ab1@mail.gmail.com> <3f4b08d0801111237o6f76f729na4b8167d977e5c91@mail.gmail.com> <87FCC2C1-1AFA-436A-97AD-42A28608551F@elevatedrails.com> <26DF361B-472F-41F8-A0A6-9E215C4E80E6@gmail.com> Message-ID: <7e7cb8940801121003q29474452sa7695841efd3a7eb@mail.gmail.com> Hello, > BTW, I am working on a skeleton app, which I could provide as a > replacement for the kitchen sink app if anyone is interested. I'd definitely be interested. If you make your skeleton app public, I will update my "How-To: Tutorial on developing a Facebook application using Ruby on Rails (Part I)" (*) using Facebooker instead of rfacebook. Currently I'm a little lost on how to set everything up and get started with Facebooker. Cheers. (*) http://rfacebook.wordpress.com/2008/01/10/tutorial/ -- Gerald Bauer - Internet Professional - http://geraldbauer.wordpress.com From digidigo at gmail.com Mon Jan 14 12:10:37 2008 From: digidigo at gmail.com (David Clements) Date: Mon, 14 Jan 2008 10:10:37 -0700 Subject: [Facebooker-talk] Bebo at 100% In-Reply-To: <3CF85054-2897-404C-B80C-8C07AE3E34D0@elevatedrails.com> References: <3CF85054-2897-404C-B80C-8C07AE3E34D0@elevatedrails.com> Message-ID: Yeah, That sounds like a decent approach, as long as we don't dupe a bunch of code along the way. It looks like a lot of the FBML is the same just the tags are different right? Is the authentication api the same? I think I will have some cycles to help out on this as well in February. Dave On Jan 12, 2008 8:22 AM, Mike Mangino wrote: > I'm incredibly excited about this. It looks like we can very easily > support the basics. > > We're doing a really big application release for a client in about a > week, after that, I'll try to get started on this. > > I would like to start by allowing you to run your app either in > Facebook mode or Beebo mode. Once we have them both working, we can > look at allowing one code base to run both at the same time. > > Does that sound sane? > > Mike > > > On Jan 11, 2008, at 1:19 PM, David Clements wrote: > > > http://www.readwriteweb.com/archives/bebo_opens_up_100_percent.php > > > > > > Bebo Opens Up 100% in Bid For More Third Party Apps > > Written by Richard MacManus / January 10, 2008 6:50 PM / 2 Comments > > > > > > > > Following the December announcement that social network Bebo was > > aligning itself to the Facebook platform, the company announced today > > that the Bebo Open Application Platform is "100% open" ? meaning that > > any 3rd party developer can deploy their applications on Bebo. > > > > > > > > > > Anyone working on this yet? I don't have the thumbs up from my client > > yet, but might jump on it soon. > > > > Dave > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > From digidigo at gmail.com Mon Jan 14 17:03:59 2008 From: digidigo at gmail.com (David Clements) Date: Mon, 14 Jan 2008 15:03:59 -0700 Subject: [Facebooker-talk] Setting profile FBML for a Facebook Page Message-ID: Had a user add our app to a Facebook Page, http://www.facebook.com/business/?pages. Facebook Pages act like users but are more for businesses and Bands. It looks like the current Facebooker API doesn't currently support setting the Profile FBML for a Page. The current code for setting the proflie is this: def profile_fbml=(markup) session.post('facebook.profile.setFBML', :uid => @id, :markup => markup) end The UID is actually hard coded to be the authenticated User. This is more restrictive than the Facebook API allows. You can actually pass in any User ID. And Facebook pages act like users so get around this I changed it around a little. def profile_fbml=(markup) update_profile_fbml_for_user(markup, @id) end def update_profile_fbml_for_user(markup, user_id) session.post('facebook.profile.setFBML', :uid => user_id, :markup => markup) end Hope this helps some people out, I didn't really even understand Facebook Pages until I got the support request. Let me know if I am missing something here, and if not I will upload a patch. Dave From svicalifornia at gmail.com Tue Jan 15 15:17:58 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 15 Jan 2008 12:17:58 -0800 Subject: [Facebooker-talk] getting started Message-ID: <20080115121758273680.199f6e87@gmail.com> Please help me get up and running. If successful, we can turn this thread into a Getting Started guide to Facebooker. Here's what I have: #ENV['FACEBOOK_API_KEY'] = 'xxxxx' # actual keys here, x'd out for security #ENV['FACEBOOK_SECRET_KEY'] = 'xxxxx' class FacebookController < ApplicationController ensure_application_is_installed_by_facebook_user def index session = Facebooker::Session.create(ENV['FACEBOOK_API_KEY'],ENV['FACEBOOK_SECRET_KEY']) @user = session.user() # line 12 - Exception here: Facebooker::Session::MissingOrInvalidParameter # ... end end Here's the trace: Facebooker::Session::MissingOrInvalidParameter (Invalid parameter): .//vendor/plugins/facebooker/lib/facebooker/parser.rb:322:in `process' .//vendor/plugins/facebooker/lib/facebooker/parser.rb:15:in `parse' .//vendor/plugins/facebooker/lib/facebooker/service.rb:13:in `post' .//vendor/plugins/facebooker/lib/facebooker/session.rb:328:in `post' .//vendor/plugins/facebooker/lib/facebooker/session.rb:135:in `secure!' .//vendor/plugins/facebooker/lib/facebooker/session.rb:361:in `uid' .//vendor/plugins/facebooker/lib/facebooker/session.rb:165:in `user' .//app/controllers/facebook_controller.rb:12:in `index' What am I doing wrong? Thanks, Shawn From digidigo at gmail.com Tue Jan 15 15:25:25 2008 From: digidigo at gmail.com (David Clements) Date: Tue, 15 Jan 2008 13:25:25 -0700 Subject: [Facebooker-talk] getting started In-Reply-To: <20080115121758273680.199f6e87@gmail.com> References: <20080115121758273680.199f6e87@gmail.com> Message-ID: Hey Shawn, You don't actually need to create your own session. The before filter will do that for you. In your example you could do @user = session[:facebook_session].user Dave On Jan 15, 2008 1:17 PM, Shawn Van Ittersum wrote: > Please help me get up and running. If successful, we can turn this thread into a Getting Started guide to Facebooker. > > Here's what I have: > > #ENV['FACEBOOK_API_KEY'] = 'xxxxx' # actual keys here, x'd out for security > #ENV['FACEBOOK_SECRET_KEY'] = 'xxxxx' > > class FacebookController < ApplicationController > ensure_application_is_installed_by_facebook_user > > def index > > session = Facebooker::Session.create(ENV['FACEBOOK_API_KEY'],ENV['FACEBOOK_SECRET_KEY']) > @user = session.user() # line 12 - Exception here: Facebooker::Session::MissingOrInvalidParameter > # ... > end > end > > Here's the trace: > > Facebooker::Session::MissingOrInvalidParameter (Invalid parameter): > .//vendor/plugins/facebooker/lib/facebooker/parser.rb:322:in `process' > .//vendor/plugins/facebooker/lib/facebooker/parser.rb:15:in `parse' > .//vendor/plugins/facebooker/lib/facebooker/service.rb:13:in `post' > .//vendor/plugins/facebooker/lib/facebooker/session.rb:328:in `post' > .//vendor/plugins/facebooker/lib/facebooker/session.rb:135:in `secure!' > .//vendor/plugins/facebooker/lib/facebooker/session.rb:361:in `uid' > .//vendor/plugins/facebooker/lib/facebooker/session.rb:165:in `user' > .//app/controllers/facebook_controller.rb:12:in `index' > > What am I doing wrong? > > Thanks, > Shawn > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From svicalifornia at gmail.com Tue Jan 15 16:19:12 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 15 Jan 2008 13:19:12 -0800 Subject: [Facebooker-talk] strange routing problem Message-ID: <20080115131912422666.aad14e06@gmail.com> Now when I try to use facebooker, I get routing problems on all controllers except the default route: ActionController::RoutingError (no route found to match "facebook" with {:method=>:get}) This affects all app controllers, not just the facebook one, even app controllers with no Facebooker code. When I remove the facebooker plugin, the routing problems go away and the routing works properly. When I install it again, the problem returns. Has anyone else experienced this? Shawn From svicalifornia at gmail.com Tue Jan 15 16:37:09 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 15 Jan 2008 13:37:09 -0800 Subject: [Facebooker-talk] Fwd: strange routing problem Message-ID: <20080115133709525629.c599eebe@gmail.com> Figured it out. I had commented the environment lines for testing something. So if anyone has that routing error, then you're missing your config lines in the environment. :) Shawn ----- Begin forwarded message ----- From: Shawn Van Ittersum Date: Tue, 15 Jan 2008 13:19:12 -0800 To: facebooker-talk at rubyforge.org Subject: strange routing problem Now when I try to use facebooker, I get routing problems on all controllers except the default route: ActionController::RoutingError (no route found to match "facebook" with {:method=>:get}) This affects all app controllers, not just the facebook one, even app controllers with no Facebooker code. When I remove the facebooker plugin, the routing problems go away and the routing works properly. When I install it again, the problem returns. Has anyone else experienced this? Shawn From svicalifornia at gmail.com Tue Jan 15 18:52:34 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 15 Jan 2008 15:52:34 -0800 Subject: [Facebooker-talk] getting started In-Reply-To: References: <20080115121758273680.199f6e87@gmail.com> Message-ID: <20080115155234955462.41e4dc3b@gmail.com> Thanks, Dave! Shawn On Tue, 15 Jan 2008 13:25:25 -0700, David Clements wrote: > Hey Shawn, > > You don't actually need to create your own session. The before filter > will do that for you. > In your example you could do > > @user = session[:facebook_session].user > > > Dave > > On Jan 15, 2008 1:17 PM, Shawn Van Ittersum wrote: >> Please help me get up and running. If successful, we can turn this >> thread into a Getting Started guide to Facebooker. >> >> Here's what I have: >> >> #ENV['FACEBOOK_API_KEY'] = 'xxxxx' # actual keys here, x'd out for security >> #ENV['FACEBOOK_SECRET_KEY'] = 'xxxxx' >> >> class FacebookController < ApplicationController >> ensure_application_is_installed_by_facebook_user >> >> def index >> >> session = >> Facebooker::Session.create(ENV['FACEBOOK_API_KEY'],ENV['FACEBOOK_SECRET_KEY']) >> @user = session.user() # line 12 - Exception here: >> Facebooker::Session::MissingOrInvalidParameter >> # ... >> end >> end >> >> Here's the trace: >> >> Facebooker::Session::MissingOrInvalidParameter (Invalid parameter): >> .//vendor/plugins/facebooker/lib/facebooker/parser.rb:322:in `process' >> .//vendor/plugins/facebooker/lib/facebooker/parser.rb:15:in `parse' >> .//vendor/plugins/facebooker/lib/facebooker/service.rb:13:in `post' >> .//vendor/plugins/facebooker/lib/facebooker/session.rb:328:in `post' >> .//vendor/plugins/facebooker/lib/facebooker/session.rb:135:in `secure!' >> .//vendor/plugins/facebooker/lib/facebooker/session.rb:361:in `uid' >> .//vendor/plugins/facebooker/lib/facebooker/session.rb:165:in `user' >> .//app/controllers/facebook_controller.rb:12:in `index' >> >> What am I doing wrong? >> >> Thanks, >> Shawn >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> From mmangino at elevatedrails.com Wed Jan 16 18:35:29 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Wed, 16 Jan 2008 17:35:29 -0600 Subject: [Facebooker-talk] Towards a 1.0 release Message-ID: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> Hey everybody. I've been using Facebooker on several projects over the last few months and feel like it is really starting to mature. I'd like to push towards a 1.0 release within the next month. I'd really like everybody's input on what still needs to be done, as well as some help in wrapping things up. I've created a list of things that still need to be done on Facebooker. Can you guys take a look and send me any additions? I plan on spending next week looking at projects with both Facebook and non-facebook sections. I'll try to clean up the outstanding issues in that area. Before a 1.0 release, I think we need to: 1) Document all helpers and major methods. Most helpers have documentation, but it is a little sparse. I'd love some help adding rdoc to our helper methods along with any other method that is externally usable. 2) Implement object creation for all FQL types. Right now, we can only handle FQL queries for a few different types. We should support all of the available types. You can add support for new types by editing parser.rb. Search for Fql there to see how that works. 3) Create a website for Facebooker I registered Facebooker-api.com and am willing to provide hosting hardware and bandwidth (through Elevated Rails) I would like to use Rubyforge for the issue tracker and mailing lists, but I can create a Radiant or Mephisto instance for hosting the main website. Is anyone interested in helping out here? I have no UI development skills, so a nice UI would be appreciated as well. 4) Create a getting started tutorial Unfortunately, there is no good tutorial for how to setup a Facebook app with Facebooker. It would be nice to have at least a basic getting started guide. So what have I missed? Is there anything else that we need to do? Does anyone have any preferences about how to run the website? We (Elevated Rails) are using Radiant already, so that is easy for me to setup. I'm open to other options. Thanks for your help and suggestions. Mike -- Mike Mangino http://www.elevatedrails.com From shanev at gmail.com Wed Jan 16 20:42:18 2008 From: shanev at gmail.com (Shane Vitarana) Date: Wed, 16 Jan 2008 19:42:18 -0600 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> Message-ID: <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> Hey Mike- I can help with getting it working with apps with non-facebook sections. I'm working on fixing the issue with the facebook relative root being appended to non-facebook assets. I'd like to fix up routing before a 1.0 release as well. I think I might be able to get a designer for the site. I'll keep you posted. Shane On Jan 16, 2008 5:35 PM, Mike Mangino wrote: > Hey everybody. > > I've been using Facebooker on several projects over the last few > months and feel like it is really starting to mature. I'd like to push > towards a 1.0 release within the next month. I'd really like > everybody's input on what still needs to be done, as well as some help > in wrapping things up. I've created a list of things that still need > to be done on Facebooker. Can you guys take a look and send me any > additions? I plan on spending next week looking at projects with both > Facebook and non-facebook sections. I'll try to clean up the > outstanding issues in that area. > > Before a 1.0 release, I think we need to: > > 1) Document all helpers and major methods. > > Most helpers have documentation, but it is a little sparse. I'd love > some help adding rdoc to our helper methods along with any other > method that is externally usable. > > 2) Implement object creation for all FQL types. > > Right now, we can only handle FQL queries for a few different types. > We should support all of the available types. You can add support for > new types by editing parser.rb. Search for Fql there to see how that > works. > > 3) Create a website for Facebooker > > I registered Facebooker-api.com and am willing to provide hosting > hardware and bandwidth (through Elevated Rails) I would like to use > Rubyforge for the issue tracker and mailing lists, but I can create a > Radiant or Mephisto instance for hosting the main website. Is anyone > interested in helping out here? I have no UI development skills, so a > nice UI would be appreciated as well. > > 4) Create a getting started tutorial > > Unfortunately, there is no good tutorial for how to setup a Facebook > app with Facebooker. It would be nice to have at least a basic getting > started guide. > > > So what have I missed? Is there anything else that we need to do? Does > anyone have any preferences about how to run the website? We (Elevated > Rails) are using Radiant already, so that is easy for me to setup. I'm > open to other options. > > Thanks for your help and suggestions. > > > Mike > > > -- > Mike Mangino > http://www.elevatedrails.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From digidigo at gmail.com Thu Jan 17 23:38:51 2008 From: digidigo at gmail.com (David Clements) Date: Thu, 17 Jan 2008 21:38:51 -0700 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> Message-ID: I can jump in and do some documentation if no one else is on it yet? Dave On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: > Hey Mike- > > I can help with getting it working with apps with non-facebook > sections. I'm working on fixing the issue with the facebook relative > root being appended to non-facebook assets. I'd like to fix up > routing before a 1.0 release as well. I think I might be able to get > a designer for the site. I'll keep you posted. > > Shane > > > On Jan 16, 2008 5:35 PM, Mike Mangino wrote: > > Hey everybody. > > > > I've been using Facebooker on several projects over the last few > > months and feel like it is really starting to mature. I'd like to push > > towards a 1.0 release within the next month. I'd really like > > everybody's input on what still needs to be done, as well as some help > > in wrapping things up. I've created a list of things that still need > > to be done on Facebooker. Can you guys take a look and send me any > > additions? I plan on spending next week looking at projects with both > > Facebook and non-facebook sections. I'll try to clean up the > > outstanding issues in that area. > > > > Before a 1.0 release, I think we need to: > > > > 1) Document all helpers and major methods. > > > > Most helpers have documentation, but it is a little sparse. I'd love > > some help adding rdoc to our helper methods along with any other > > method that is externally usable. > > > > 2) Implement object creation for all FQL types. > > > > Right now, we can only handle FQL queries for a few different types. > > We should support all of the available types. You can add support for > > new types by editing parser.rb. Search for Fql there to see how that > > works. > > > > 3) Create a website for Facebooker > > > > I registered Facebooker-api.com and am willing to provide hosting > > hardware and bandwidth (through Elevated Rails) I would like to use > > Rubyforge for the issue tracker and mailing lists, but I can create a > > Radiant or Mephisto instance for hosting the main website. Is anyone > > interested in helping out here? I have no UI development skills, so a > > nice UI would be appreciated as well. > > > > 4) Create a getting started tutorial > > > > Unfortunately, there is no good tutorial for how to setup a Facebook > > app with Facebooker. It would be nice to have at least a basic getting > > started guide. > > > > > > So what have I missed? Is there anything else that we need to do? Does > > anyone have any preferences about how to run the website? We (Elevated > > Rails) are using Radiant already, so that is easy for me to setup. I'm > > open to other options. > > > > Thanks for your help and suggestions. > > > > > > Mike > > > > > > -- > > Mike Mangino > > http://www.elevatedrails.com > > > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > > > > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From david.newbury at gmail.com Fri Jan 18 11:32:28 2008 From: david.newbury at gmail.com (David Newbury) Date: Fri, 18 Jan 2008 10:32:28 -0600 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> Message-ID: Hey, Y'all. I'm Shane's designer friend, David. I am willing to work on a design and user interface for the site. I am currently using Radiant for a small project--i'm comfortable enough with it that I think it's a good choice for the site. Let me know what the next steps are. - David Newbury (773)-547-2272 www.workergnome.com On Jan 17, 2008, at 10:38 PM, "David Clements" wrote: > I can jump in and do some documentation if no one else is on it yet? > > Dave > > > On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: >> Hey Mike- >> >> I can help with getting it working with apps with non-facebook >> sections. I'm working on fixing the issue with the facebook relative >> root being appended to non-facebook assets. I'd like to fix up >> routing before a 1.0 release as well. I think I might be able to get >> a designer for the site. I'll keep you posted. >> >> Shane >> >> >> On Jan 16, 2008 5:35 PM, Mike Mangino >> wrote: >>> Hey everybody. >>> >>> I've been using Facebooker on several projects over the last few >>> months and feel like it is really starting to mature. I'd like to >>> push >>> towards a 1.0 release within the next month. I'd really like >>> everybody's input on what still needs to be done, as well as some >>> help >>> in wrapping things up. I've created a list of things that still need >>> to be done on Facebooker. Can you guys take a look and send me any >>> additions? I plan on spending next week looking at projects with >>> both >>> Facebook and non-facebook sections. I'll try to clean up the >>> outstanding issues in that area. >>> >>> Before a 1.0 release, I think we need to: >>> >>> 1) Document all helpers and major methods. >>> >>> Most helpers have documentation, but it is a little sparse. I'd love >>> some help adding rdoc to our helper methods along with any other >>> method that is externally usable. >>> >>> 2) Implement object creation for all FQL types. >>> >>> Right now, we can only handle FQL queries for a few different types. >>> We should support all of the available types. You can add support >>> for >>> new types by editing parser.rb. Search for Fql there to see how that >>> works. >>> >>> 3) Create a website for Facebooker >>> >>> I registered Facebooker-api.com and am willing to provide hosting >>> hardware and bandwidth (through Elevated Rails) I would like to use >>> Rubyforge for the issue tracker and mailing lists, but I can >>> create a >>> Radiant or Mephisto instance for hosting the main website. Is anyone >>> interested in helping out here? I have no UI development skills, >>> so a >>> nice UI would be appreciated as well. >>> >>> 4) Create a getting started tutorial >>> >>> Unfortunately, there is no good tutorial for how to setup a Facebook >>> app with Facebooker. It would be nice to have at least a basic >>> getting >>> started guide. >>> >>> >>> So what have I missed? Is there anything else that we need to do? >>> Does >>> anyone have any preferences about how to run the website? We >>> (Elevated >>> Rails) are using Radiant already, so that is easy for me to setup. >>> I'm >>> open to other options. >>> >>> Thanks for your help and suggestions. >>> >>> >>> Mike >>> >>> >>> -- >>> Mike Mangino >>> http://www.elevatedrails.com >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >> >> >> >> -- >> http://myfitbuddy.com | http://shanesbrain.net | http:// >> crimsonjet.com >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From digidigo at gmail.com Fri Jan 18 16:46:52 2008 From: digidigo at gmail.com (David Clements) Date: Fri, 18 Jan 2008 14:46:52 -0700 Subject: [Facebooker-talk] faceboooker_mq Message-ID: Hey Mike and the rest of the Gang, I just finished packaging up a plugin for backgrounding many of the Facebook API calls so that they don't take up the request cycle. Hopefully you will find it useful, once I started to package it up I realized that there was a much simpler approach so I don't have this in production yet but it will be soon. It turned out to be simple enough that maybe we could actually put it , or something like it into the Facebooker Codebase? If not I will setup a rubyforge project for it to live , currently it lives at: script/plugin install http://daveonrails.svnrepository.com/svn/projects/facebooker_mq Let me know if you can't get it, the guys told me that the set anonymous access. Here is the README as it stands now, Copyright (c) 2008 David Clements, released under the MIT license Updated: 1/18/2008 Purpose: The of FacebookerMQ is to provide an async method for performing time consuming Facebook API requests. The Facebook platform is very sensitive to long running requests, and as such it becomes important to offload some of these requests to a background process. As the name suggests this plugin relies on the facebooker api ( gem install facebooker ). Overview: FacebookerMQ intercepts Facebooker calls into session.publish(method, params) and saves all the relevant data to the database. This is inspired by the ar_mailer project which does the same for ActionMailer. In order to process the queue you can setup a cron job to run script/runner FacebookerMqRunner.work(). What you need: 1) script/plugin install http://daveonrails.svnrepository.com/svn/projects/facebooker_mq 2) You will need a migration to create the table that holds the messages. You can think if this table as the queue class CreateFacebookMessages < ActiveRecord::Migration def self.up create_table :facebook_messages do |t| t.column(:session_key, :string, :null => false) t.column(:expires, :string, :null => false, :default => "0") t.column(:uid, :integer, :null => false) t.column(:method, :string, :null => false) t.column(:params, :text, :null => false ) # Always a hash. t.column(:state, :string, :null => false, :default => 'new' ) t.column(:send_after, :datetime, :null => false, :default => Time.at(0)) # Optional date time to wait until you send t.column( :last_send_attempt, :datetime ) t.column( :send_attempts, :integer, :default => 0 , :null => false ) t.timestamps end end def self.down drop_table :facebook_messages end end 3) Cronjob or some other way to fire off FacebookerMqRunner.work() Misc: Look in facebooker_session_override.rb and you will see all the api methods that are currently offloaded to the queue. This can be added to or removed from by calling Facebooker::Session.async_method or Facebooker::Session.sync_method I am kinda hoping to get this pushed into the Facebooker source so that it can be a config option. If not I will setup a rubyforge project and change the URL This is a work in progress and any comments or code is totally welcome. It has been developed from a couple of projects that I am currently working on. TODO: 1) I think some of the options such as the max number of failure, which methods to intercept and table name should be configurable. 2) I think that it would be good to work out some admin view of the queue. 3) Make sure that it works well with multiple runner instances. 4) Remove the need to run this within the RAILS_ENV 5) Create a gem like ar_mailer has. From svicalifornia at gmail.com Sat Jan 19 21:23:48 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Sat, 19 Jan 2008 18:23:48 -0800 Subject: [Facebooker-talk] relative root Message-ID: <20080119182348238505.eca1866a@gmail.com> Hey guys, In rfacebook, the callback_path variable allows the developer to strip part of the URL off of auto-generated links (link_to). For example, if an app's canvas pages lead to a certain controller: http://apps.facebook.com/appname/index -> http://appserver.com/controller/index I want the link_to method to prefix the action with 'http://apps.facebook.com/appname/', automatically stripping out the app server and controller. The rfacebook config variables allows this with callback_path set to '/controller/'. Is there an equivalent behavior/config for Facebooker? Thanks, Shawn From digidigo at gmail.com Sat Jan 19 22:46:29 2008 From: digidigo at gmail.com (David Clements) Date: Sat, 19 Jan 2008 20:46:29 -0700 Subject: [Facebooker-talk] relative root In-Reply-To: <20080119182348238505.eca1866a@gmail.com> References: <20080119182348238505.eca1866a@gmail.com> Message-ID: Hey Shawn, Are you saying that you basically only want one controller to handle all your facebook requests? And that appname == controller? I looked into this scenario and it looks like maybe the code would need to change to handle it. Basically you don't want to have any relative_root_url and you set the Callback Url in your facebook application settings to the same name as your controller. Something like http://appserver.com/facebook_handler Then create a facebook_handler_controller. And then change the code in facebook_url_rewriting to this def relative_url_root "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" if (parameters['fb_sig'] && (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) ) end This will effectively remove the relative url root. But maybe I am wrong as to what you are trying to do. Dave On Jan 19, 2008 7:23 PM, Shawn Van Ittersum wrote: > Hey guys, > > In rfacebook, the callback_path variable allows the developer to strip part of the URL off of auto-generated links (link_to). For example, if an app's canvas pages lead to a certain controller: > > http://apps.facebook.com/appname/index > -> http://appserver.com/controller/index > > I want the link_to method to prefix the action with 'http://apps.facebook.com/appname/', automatically stripping out the app server and controller. The rfacebook config variables allows this with callback_path set to '/controller/'. > > Is there an equivalent behavior/config for Facebooker? > > Thanks, > Shawn > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From jon at professionalnerd.com Sun Jan 20 06:06:36 2008 From: jon at professionalnerd.com (Jon Gilbraith) Date: Sun, 20 Jan 2008 11:06:36 +0000 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> Message-ID: Hey folks, Re: tutorials, I had planned to try and put together something a while back but since then had to reprioritise my projects so haven't been able to keep up on things. If nobody else is able to help out in this area before then, I hope to be able to give it some time in late Feb / early March latest and would be happy to help out then. Cheers, Jon On 18 Jan 2008, at 16:32, David Newbury wrote: > Hey, Y'all. > > I'm Shane's designer friend, David. I am willing to work on a design > and user interface for the site. I am currently using Radiant for a > small project--i'm comfortable enough with it that I think it's a good > choice for the site. > > Let me know what the next steps are. > > - David Newbury > (773)-547-2272 > www.workergnome.com > > On Jan 17, 2008, at 10:38 PM, "David Clements" > wrote: > >> I can jump in and do some documentation if no one else is on it yet? >> >> Dave >> >> >> On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: >>> Hey Mike- >>> >>> I can help with getting it working with apps with non-facebook >>> sections. I'm working on fixing the issue with the facebook >>> relative >>> root being appended to non-facebook assets. I'd like to fix up >>> routing before a 1.0 release as well. I think I might be able to >>> get >>> a designer for the site. I'll keep you posted. >>> >>> Shane >>> >>> >>> On Jan 16, 2008 5:35 PM, Mike Mangino >>> wrote: >>>> Hey everybody. >>>> >>>> I've been using Facebooker on several projects over the last few >>>> months and feel like it is really starting to mature. I'd like to >>>> push >>>> towards a 1.0 release within the next month. I'd really like >>>> everybody's input on what still needs to be done, as well as some >>>> help >>>> in wrapping things up. I've created a list of things that still >>>> need >>>> to be done on Facebooker. Can you guys take a look and send me any >>>> additions? I plan on spending next week looking at projects with >>>> both >>>> Facebook and non-facebook sections. I'll try to clean up the >>>> outstanding issues in that area. >>>> >>>> Before a 1.0 release, I think we need to: >>>> >>>> 1) Document all helpers and major methods. >>>> >>>> Most helpers have documentation, but it is a little sparse. I'd >>>> love >>>> some help adding rdoc to our helper methods along with any other >>>> method that is externally usable. >>>> >>>> 2) Implement object creation for all FQL types. >>>> >>>> Right now, we can only handle FQL queries for a few different >>>> types. >>>> We should support all of the available types. You can add support >>>> for >>>> new types by editing parser.rb. Search for Fql there to see how >>>> that >>>> works. >>>> >>>> 3) Create a website for Facebooker >>>> >>>> I registered Facebooker-api.com and am willing to provide hosting >>>> hardware and bandwidth (through Elevated Rails) I would like to use >>>> Rubyforge for the issue tracker and mailing lists, but I can >>>> create a >>>> Radiant or Mephisto instance for hosting the main website. Is >>>> anyone >>>> interested in helping out here? I have no UI development skills, >>>> so a >>>> nice UI would be appreciated as well. >>>> >>>> 4) Create a getting started tutorial >>>> >>>> Unfortunately, there is no good tutorial for how to setup a >>>> Facebook >>>> app with Facebooker. It would be nice to have at least a basic >>>> getting >>>> started guide. >>>> >>>> >>>> So what have I missed? Is there anything else that we need to do? >>>> Does >>>> anyone have any preferences about how to run the website? We >>>> (Elevated >>>> Rails) are using Radiant already, so that is easy for me to setup. >>>> I'm >>>> open to other options. >>>> >>>> Thanks for your help and suggestions. >>>> >>>> >>>> Mike >>>> >>>> >>>> -- >>>> Mike Mangino >>>> http://www.elevatedrails.com >>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>> >>> >>> >>> -- >>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>> crimsonjet.com >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > > !DSPAM:4790d4bc212744243410844! > > From svicalifornia at gmail.com Sun Jan 20 17:35:39 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Sun, 20 Jan 2008 14:35:39 -0800 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> Message-ID: <20080120143539934325.5c4b16a3@gmail.com> I can contribute to a tutorial. We just need a web site / CMS to publish the text... :) The most important thing missing from the current docs is how to access the current session, which David Clements showed me how to do last week. The rest is pretty easy to grasp from the RDoc, but I can contribute usage examples for the common functions. Shawn On Sun, 20 Jan 2008 11:06:36 +0000, Jon Gilbraith wrote: > Hey folks, > > Re: tutorials, I had planned to try and put together something a while > back but since then had to reprioritise my projects so haven't been > able to keep up on things. If nobody else is able to help out in this > area before then, I hope to be able to give it some time in late Feb / > early March latest and would be happy to help out then. > > Cheers, > > Jon > > On 18 Jan 2008, at 16:32, David Newbury wrote: > >> Hey, Y'all. >> >> I'm Shane's designer friend, David. I am willing to work on a design >> and user interface for the site. I am currently using Radiant for a >> small project--i'm comfortable enough with it that I think it's a good >> choice for the site. >> >> Let me know what the next steps are. >> >> - David Newbury >> (773)-547-2272 >> www.workergnome.com >> >> On Jan 17, 2008, at 10:38 PM, "David Clements" >> wrote: >> >>> I can jump in and do some documentation if no one else is on it yet? >>> >>> Dave >>> >>> >>> On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: >>>> Hey Mike- >>>> >>>> I can help with getting it working with apps with non-facebook >>>> sections. I'm working on fixing the issue with the facebook >>>> relative >>>> root being appended to non-facebook assets. I'd like to fix up >>>> routing before a 1.0 release as well. I think I might be able to >>>> get >>>> a designer for the site. I'll keep you posted. >>>> >>>> Shane >>>> >>>> >>>> On Jan 16, 2008 5:35 PM, Mike Mangino >>>> wrote: >>>>> Hey everybody. >>>>> >>>>> I've been using Facebooker on several projects over the last few >>>>> months and feel like it is really starting to mature. I'd like to >>>>> push >>>>> towards a 1.0 release within the next month. I'd really like >>>>> everybody's input on what still needs to be done, as well as some >>>>> help >>>>> in wrapping things up. I've created a list of things that still >>>>> need >>>>> to be done on Facebooker. Can you guys take a look and send me any >>>>> additions? I plan on spending next week looking at projects with >>>>> both >>>>> Facebook and non-facebook sections. I'll try to clean up the >>>>> outstanding issues in that area. >>>>> >>>>> Before a 1.0 release, I think we need to: >>>>> >>>>> 1) Document all helpers and major methods. >>>>> >>>>> Most helpers have documentation, but it is a little sparse. I'd >>>>> love >>>>> some help adding rdoc to our helper methods along with any other >>>>> method that is externally usable. >>>>> >>>>> 2) Implement object creation for all FQL types. >>>>> >>>>> Right now, we can only handle FQL queries for a few different >>>>> types. >>>>> We should support all of the available types. You can add support >>>>> for >>>>> new types by editing parser.rb. Search for Fql there to see how >>>>> that >>>>> works. >>>>> >>>>> 3) Create a website for Facebooker >>>>> >>>>> I registered Facebooker-api.com and am willing to provide hosting >>>>> hardware and bandwidth (through Elevated Rails) I would like to use >>>>> Rubyforge for the issue tracker and mailing lists, but I can >>>>> create a >>>>> Radiant or Mephisto instance for hosting the main website. Is >>>>> anyone >>>>> interested in helping out here? I have no UI development skills, >>>>> so a >>>>> nice UI would be appreciated as well. >>>>> >>>>> 4) Create a getting started tutorial >>>>> >>>>> Unfortunately, there is no good tutorial for how to setup a >>>>> Facebook >>>>> app with Facebooker. It would be nice to have at least a basic >>>>> getting >>>>> started guide. >>>>> >>>>> >>>>> So what have I missed? Is there anything else that we need to do? >>>>> Does >>>>> anyone have any preferences about how to run the website? We >>>>> (Elevated >>>>> Rails) are using Radiant already, so that is easy for me to setup. >>>>> I'm >>>>> open to other options. >>>>> >>>>> Thanks for your help and suggestions. >>>>> >>>>> >>>>> Mike >>>>> >>>>> >>>>> -- >>>>> Mike Mangino >>>>> http://www.elevatedrails.com >>>>> >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>> >>>> >>>> >>>> >>>> -- >>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>> crimsonjet.com >>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> !DSPAM:4790d4bc212744243410844! >> >> > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From bjclark at scidept.com Sun Jan 20 17:40:30 2008 From: bjclark at scidept.com (BJ Clark) Date: Sun, 20 Jan 2008 15:40:30 -0700 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: <20080120143539934325.5c4b16a3@gmail.com> References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> <20080120143539934325.5c4b16a3@gmail.com> Message-ID: <631618CA-1342-41EB-9132-E7E1C921C030@scidept.com> I'll reiterate, I'd be happy to get a copy of radiant up and going if Mike(or anyone else) wants to provide the hosting. ----- BJ Clark the science department bjclark at scidept.com www.scidept.com On Jan 20, 2008, at 3:35 PM, Shawn Van Ittersum wrote: > I can contribute to a tutorial. We just need a web site / CMS to > publish the text... :) The most important thing missing from the > current docs is how to access the current session, which David > Clements showed me how to do last week. The rest is pretty easy to > grasp from the RDoc, but I can contribute usage examples for the > common functions. > > Shawn > > On Sun, 20 Jan 2008 11:06:36 +0000, Jon Gilbraith wrote: >> Hey folks, >> >> Re: tutorials, I had planned to try and put together something a >> while >> back but since then had to reprioritise my projects so haven't been >> able to keep up on things. If nobody else is able to help out in >> this >> area before then, I hope to be able to give it some time in late >> Feb / >> early March latest and would be happy to help out then. >> >> Cheers, >> >> Jon >> >> On 18 Jan 2008, at 16:32, David Newbury wrote: >> >>> Hey, Y'all. >>> >>> I'm Shane's designer friend, David. I am willing to work on a >>> design >>> and user interface for the site. I am currently using Radiant for a >>> small project--i'm comfortable enough with it that I think it's a >>> good >>> choice for the site. >>> >>> Let me know what the next steps are. >>> >>> - David Newbury >>> (773)-547-2272 >>> www.workergnome.com >>> >>> On Jan 17, 2008, at 10:38 PM, "David Clements" >>> wrote: >>> >>>> I can jump in and do some documentation if no one else is on it >>>> yet? >>>> >>>> Dave >>>> >>>> >>>> On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: >>>>> Hey Mike- >>>>> >>>>> I can help with getting it working with apps with non-facebook >>>>> sections. I'm working on fixing the issue with the facebook >>>>> relative >>>>> root being appended to non-facebook assets. I'd like to fix up >>>>> routing before a 1.0 release as well. I think I might be able to >>>>> get >>>>> a designer for the site. I'll keep you posted. >>>>> >>>>> Shane >>>>> >>>>> >>>>> On Jan 16, 2008 5:35 PM, Mike Mangino >>>>> wrote: >>>>>> Hey everybody. >>>>>> >>>>>> I've been using Facebooker on several projects over the last few >>>>>> months and feel like it is really starting to mature. I'd like to >>>>>> push >>>>>> towards a 1.0 release within the next month. I'd really like >>>>>> everybody's input on what still needs to be done, as well as some >>>>>> help >>>>>> in wrapping things up. I've created a list of things that still >>>>>> need >>>>>> to be done on Facebooker. Can you guys take a look and send me >>>>>> any >>>>>> additions? I plan on spending next week looking at projects with >>>>>> both >>>>>> Facebook and non-facebook sections. I'll try to clean up the >>>>>> outstanding issues in that area. >>>>>> >>>>>> Before a 1.0 release, I think we need to: >>>>>> >>>>>> 1) Document all helpers and major methods. >>>>>> >>>>>> Most helpers have documentation, but it is a little sparse. I'd >>>>>> love >>>>>> some help adding rdoc to our helper methods along with any other >>>>>> method that is externally usable. >>>>>> >>>>>> 2) Implement object creation for all FQL types. >>>>>> >>>>>> Right now, we can only handle FQL queries for a few different >>>>>> types. >>>>>> We should support all of the available types. You can add support >>>>>> for >>>>>> new types by editing parser.rb. Search for Fql there to see how >>>>>> that >>>>>> works. >>>>>> >>>>>> 3) Create a website for Facebooker >>>>>> >>>>>> I registered Facebooker-api.com and am willing to provide hosting >>>>>> hardware and bandwidth (through Elevated Rails) I would like to >>>>>> use >>>>>> Rubyforge for the issue tracker and mailing lists, but I can >>>>>> create a >>>>>> Radiant or Mephisto instance for hosting the main website. Is >>>>>> anyone >>>>>> interested in helping out here? I have no UI development skills, >>>>>> so a >>>>>> nice UI would be appreciated as well. >>>>>> >>>>>> 4) Create a getting started tutorial >>>>>> >>>>>> Unfortunately, there is no good tutorial for how to setup a >>>>>> Facebook >>>>>> app with Facebooker. It would be nice to have at least a basic >>>>>> getting >>>>>> started guide. >>>>>> >>>>>> >>>>>> So what have I missed? Is there anything else that we need to do? >>>>>> Does >>>>>> anyone have any preferences about how to run the website? We >>>>>> (Elevated >>>>>> Rails) are using Radiant already, so that is easy for me to >>>>>> setup. >>>>>> I'm >>>>>> open to other options. >>>>>> >>>>>> Thanks for your help and suggestions. >>>>>> >>>>>> >>>>>> Mike >>>>>> >>>>>> >>>>>> -- >>>>>> Mike Mangino >>>>>> http://www.elevatedrails.com >>>>>> >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>> >>>>> >>>>> >>>>> >>>>> -- >>>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>>> crimsonjet.com >>>>> >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >>> !DSPAM:4790d4bc212744243410844! >>> >>> >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From svicalifornia at gmail.com Sun Jan 20 17:55:26 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Sun, 20 Jan 2008 14:55:26 -0800 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: <631618CA-1342-41EB-9132-E7E1C921C030@scidept.com> References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> <20080120143539934325.5c4b16a3@gmail.com> <631618CA-1342-41EB-9132-E7E1C921C030@scidept.com> Message-ID: <20080120145526461181.de0d4e9c@gmail.com> Can we have some more comments for 1.0? I'm looking at facebook_url_rewriting.rb, and it's not clear what's going on. Shawn On Sun, 20 Jan 2008 15:40:30 -0700, BJ Clark wrote: > I'll reiterate, I'd be happy to get a copy of radiant up and going if > Mike(or anyone else) wants to provide the hosting. > > ----- > BJ Clark > the science department > bjclark at scidept.com > www.scidept.com > > > On Jan 20, 2008, at 3:35 PM, Shawn Van Ittersum wrote: > >> I can contribute to a tutorial. We just need a web site / CMS to >> publish the text... :) The most important thing missing from the >> current docs is how to access the current session, which David >> Clements showed me how to do last week. The rest is pretty easy to >> grasp from the RDoc, but I can contribute usage examples for the >> common functions. >> >> Shawn >> >> On Sun, 20 Jan 2008 11:06:36 +0000, Jon Gilbraith wrote: >>> Hey folks, >>> >>> Re: tutorials, I had planned to try and put together something a >>> while >>> back but since then had to reprioritise my projects so haven't been >>> able to keep up on things. If nobody else is able to help out in >>> this >>> area before then, I hope to be able to give it some time in late >>> Feb / >>> early March latest and would be happy to help out then. >>> >>> Cheers, >>> >>> Jon >>> >>> On 18 Jan 2008, at 16:32, David Newbury wrote: >>> >>>> Hey, Y'all. >>>> >>>> I'm Shane's designer friend, David. I am willing to work on a >>>> design >>>> and user interface for the site. I am currently using Radiant for a >>>> small project--i'm comfortable enough with it that I think it's a >>>> good >>>> choice for the site. >>>> >>>> Let me know what the next steps are. >>>> >>>> - David Newbury >>>> (773)-547-2272 >>>> www.workergnome.com >>>> >>>> On Jan 17, 2008, at 10:38 PM, "David Clements" >>>> wrote: >>>> >>>>> I can jump in and do some documentation if no one else is on it >>>>> yet? >>>>> >>>>> Dave >>>>> >>>>> >>>>> On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: >>>>>> Hey Mike- >>>>>> >>>>>> I can help with getting it working with apps with non-facebook >>>>>> sections. I'm working on fixing the issue with the facebook >>>>>> relative >>>>>> root being appended to non-facebook assets. I'd like to fix up >>>>>> routing before a 1.0 release as well. I think I might be able to >>>>>> get >>>>>> a designer for the site. I'll keep you posted. >>>>>> >>>>>> Shane >>>>>> >>>>>> >>>>>> On Jan 16, 2008 5:35 PM, Mike Mangino >>>>>> wrote: >>>>>>> Hey everybody. >>>>>>> >>>>>>> I've been using Facebooker on several projects over the last few >>>>>>> months and feel like it is really starting to mature. I'd like to >>>>>>> push >>>>>>> towards a 1.0 release within the next month. I'd really like >>>>>>> everybody's input on what still needs to be done, as well as some >>>>>>> help >>>>>>> in wrapping things up. I've created a list of things that still >>>>>>> need >>>>>>> to be done on Facebooker. Can you guys take a look and send me >>>>>>> any >>>>>>> additions? I plan on spending next week looking at projects with >>>>>>> both >>>>>>> Facebook and non-facebook sections. I'll try to clean up the >>>>>>> outstanding issues in that area. >>>>>>> >>>>>>> Before a 1.0 release, I think we need to: >>>>>>> >>>>>>> 1) Document all helpers and major methods. >>>>>>> >>>>>>> Most helpers have documentation, but it is a little sparse. I'd >>>>>>> love >>>>>>> some help adding rdoc to our helper methods along with any other >>>>>>> method that is externally usable. >>>>>>> >>>>>>> 2) Implement object creation for all FQL types. >>>>>>> >>>>>>> Right now, we can only handle FQL queries for a few different >>>>>>> types. >>>>>>> We should support all of the available types. You can add support >>>>>>> for >>>>>>> new types by editing parser.rb. Search for Fql there to see how >>>>>>> that >>>>>>> works. >>>>>>> >>>>>>> 3) Create a website for Facebooker >>>>>>> >>>>>>> I registered Facebooker-api.com and am willing to provide hosting >>>>>>> hardware and bandwidth (through Elevated Rails) I would like to >>>>>>> use >>>>>>> Rubyforge for the issue tracker and mailing lists, but I can >>>>>>> create a >>>>>>> Radiant or Mephisto instance for hosting the main website. Is >>>>>>> anyone >>>>>>> interested in helping out here? I have no UI development skills, >>>>>>> so a >>>>>>> nice UI would be appreciated as well. >>>>>>> >>>>>>> 4) Create a getting started tutorial >>>>>>> >>>>>>> Unfortunately, there is no good tutorial for how to setup a >>>>>>> Facebook >>>>>>> app with Facebooker. It would be nice to have at least a basic >>>>>>> getting >>>>>>> started guide. >>>>>>> >>>>>>> >>>>>>> So what have I missed? Is there anything else that we need to do? >>>>>>> Does >>>>>>> anyone have any preferences about how to run the website? We >>>>>>> (Elevated >>>>>>> Rails) are using Radiant already, so that is easy for me to >>>>>>> setup. >>>>>>> I'm >>>>>>> open to other options. >>>>>>> >>>>>>> Thanks for your help and suggestions. >>>>>>> >>>>>>> >>>>>>> Mike >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> Mike Mangino >>>>>>> http://www.elevatedrails.com >>>>>>> >>>>>>> _______________________________________________ >>>>>>> Facebooker-talk mailing list >>>>>>> Facebooker-talk at rubyforge.org >>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>> >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>>>> crimsonjet.com >>>>>> >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>> >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>>> !DSPAM:4790d4bc212744243410844! >>>> >>>> >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From bjclark at scidept.com Sun Jan 20 18:27:25 2008 From: bjclark at scidept.com (BJ Clark) Date: Sun, 20 Jan 2008 16:27:25 -0700 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: <20080120145526461181.de0d4e9c@gmail.com> References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> <20080120143539934325.5c4b16a3@gmail.com> <631618CA-1342-41EB-9132-E7E1C921C030@scidept.com> <20080120145526461181.de0d4e9c@gmail.com> Message-ID: I think routing might need some upgrading before 1.0 (IMO). It would be nice to figure out a way to make map.resources work out of the box. I took at look at it and didn't see an easy way to accomplish this, but maybe someone else has a better idea. The current facebook_resources is not idea because it doesn't use standard naming conventions (i.e. show_foos_path instead of foo_path (singular)). It also only works for POSTs, where GET is necessary/more useful in some cases. Anyone have any thoughts or have this working already? BJ ----- BJ Clark the science department bjclark at scidept.com www.scidept.com On Jan 20, 2008, at 3:55 PM, Shawn Van Ittersum wrote: > Can we have some more comments for 1.0? I'm looking at > facebook_url_rewriting.rb, and it's not clear what's going on. > > Shawn > > On Sun, 20 Jan 2008 15:40:30 -0700, BJ Clark wrote: >> I'll reiterate, I'd be happy to get a copy of radiant up and going if >> Mike(or anyone else) wants to provide the hosting. >> >> ----- >> BJ Clark >> the science department >> bjclark at scidept.com >> www.scidept.com >> >> >> On Jan 20, 2008, at 3:35 PM, Shawn Van Ittersum wrote: >> >>> I can contribute to a tutorial. We just need a web site / CMS to >>> publish the text... :) The most important thing missing from the >>> current docs is how to access the current session, which David >>> Clements showed me how to do last week. The rest is pretty easy to >>> grasp from the RDoc, but I can contribute usage examples for the >>> common functions. >>> >>> Shawn >>> >>> On Sun, 20 Jan 2008 11:06:36 +0000, Jon Gilbraith wrote: >>>> Hey folks, >>>> >>>> Re: tutorials, I had planned to try and put together something a >>>> while >>>> back but since then had to reprioritise my projects so haven't been >>>> able to keep up on things. If nobody else is able to help out in >>>> this >>>> area before then, I hope to be able to give it some time in late >>>> Feb / >>>> early March latest and would be happy to help out then. >>>> >>>> Cheers, >>>> >>>> Jon >>>> >>>> On 18 Jan 2008, at 16:32, David Newbury wrote: >>>> >>>>> Hey, Y'all. >>>>> >>>>> I'm Shane's designer friend, David. I am willing to work on a >>>>> design >>>>> and user interface for the site. I am currently using Radiant >>>>> for a >>>>> small project--i'm comfortable enough with it that I think it's a >>>>> good >>>>> choice for the site. >>>>> >>>>> Let me know what the next steps are. >>>>> >>>>> - David Newbury >>>>> (773)-547-2272 >>>>> www.workergnome.com >>>>> >>>>> On Jan 17, 2008, at 10:38 PM, "David Clements" >>>>> >>>>> wrote: >>>>> >>>>>> I can jump in and do some documentation if no one else is on it >>>>>> yet? >>>>>> >>>>>> Dave >>>>>> >>>>>> >>>>>> On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: >>>>>>> Hey Mike- >>>>>>> >>>>>>> I can help with getting it working with apps with non-facebook >>>>>>> sections. I'm working on fixing the issue with the facebook >>>>>>> relative >>>>>>> root being appended to non-facebook assets. I'd like to fix up >>>>>>> routing before a 1.0 release as well. I think I might be able >>>>>>> to >>>>>>> get >>>>>>> a designer for the site. I'll keep you posted. >>>>>>> >>>>>>> Shane >>>>>>> >>>>>>> >>>>>>> On Jan 16, 2008 5:35 PM, Mike Mangino >>>>>> > >>>>>>> wrote: >>>>>>>> Hey everybody. >>>>>>>> >>>>>>>> I've been using Facebooker on several projects over the last >>>>>>>> few >>>>>>>> months and feel like it is really starting to mature. I'd >>>>>>>> like to >>>>>>>> push >>>>>>>> towards a 1.0 release within the next month. I'd really like >>>>>>>> everybody's input on what still needs to be done, as well as >>>>>>>> some >>>>>>>> help >>>>>>>> in wrapping things up. I've created a list of things that still >>>>>>>> need >>>>>>>> to be done on Facebooker. Can you guys take a look and send me >>>>>>>> any >>>>>>>> additions? I plan on spending next week looking at projects >>>>>>>> with >>>>>>>> both >>>>>>>> Facebook and non-facebook sections. I'll try to clean up the >>>>>>>> outstanding issues in that area. >>>>>>>> >>>>>>>> Before a 1.0 release, I think we need to: >>>>>>>> >>>>>>>> 1) Document all helpers and major methods. >>>>>>>> >>>>>>>> Most helpers have documentation, but it is a little sparse. I'd >>>>>>>> love >>>>>>>> some help adding rdoc to our helper methods along with any >>>>>>>> other >>>>>>>> method that is externally usable. >>>>>>>> >>>>>>>> 2) Implement object creation for all FQL types. >>>>>>>> >>>>>>>> Right now, we can only handle FQL queries for a few different >>>>>>>> types. >>>>>>>> We should support all of the available types. You can add >>>>>>>> support >>>>>>>> for >>>>>>>> new types by editing parser.rb. Search for Fql there to see how >>>>>>>> that >>>>>>>> works. >>>>>>>> >>>>>>>> 3) Create a website for Facebooker >>>>>>>> >>>>>>>> I registered Facebooker-api.com and am willing to provide >>>>>>>> hosting >>>>>>>> hardware and bandwidth (through Elevated Rails) I would like to >>>>>>>> use >>>>>>>> Rubyforge for the issue tracker and mailing lists, but I can >>>>>>>> create a >>>>>>>> Radiant or Mephisto instance for hosting the main website. Is >>>>>>>> anyone >>>>>>>> interested in helping out here? I have no UI development >>>>>>>> skills, >>>>>>>> so a >>>>>>>> nice UI would be appreciated as well. >>>>>>>> >>>>>>>> 4) Create a getting started tutorial >>>>>>>> >>>>>>>> Unfortunately, there is no good tutorial for how to setup a >>>>>>>> Facebook >>>>>>>> app with Facebooker. It would be nice to have at least a basic >>>>>>>> getting >>>>>>>> started guide. >>>>>>>> >>>>>>>> >>>>>>>> So what have I missed? Is there anything else that we need to >>>>>>>> do? >>>>>>>> Does >>>>>>>> anyone have any preferences about how to run the website? We >>>>>>>> (Elevated >>>>>>>> Rails) are using Radiant already, so that is easy for me to >>>>>>>> setup. >>>>>>>> I'm >>>>>>>> open to other options. >>>>>>>> >>>>>>>> Thanks for your help and suggestions. >>>>>>>> >>>>>>>> >>>>>>>> Mike >>>>>>>> >>>>>>>> >>>>>>>> -- >>>>>>>> Mike Mangino >>>>>>>> http://www.elevatedrails.com >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> Facebooker-talk mailing list >>>>>>>> Facebooker-talk at rubyforge.org >>>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>>>>> crimsonjet.com >>>>>>> >>>>>>> _______________________________________________ >>>>>>> Facebooker-talk mailing list >>>>>>> Facebooker-talk at rubyforge.org >>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>> >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>> >>>>> !DSPAM:4790d4bc212744243410844! >>>>> >>>>> >>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk From shanev at gmail.com Sun Jan 20 18:45:46 2008 From: shanev at gmail.com (Shane Vitarana) Date: Sun, 20 Jan 2008 17:45:46 -0600 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> <20080120143539934325.5c4b16a3@gmail.com> <631618CA-1342-41EB-9132-E7E1C921C030@scidept.com> <20080120145526461181.de0d4e9c@gmail.com> Message-ID: <4ab757a40801201545j4c2983c1o6a156f158af06bdf@mail.gmail.com> BJ- All requests from Facebook are POSTs, although with the recent addition of fb_sig_request_method, we can tell if the orignal request type was a GET or POST. I'm working on improving routing using this change and making it closer to Rails standards. Shane On Jan 20, 2008 5:27 PM, BJ Clark wrote: > I think routing might need some upgrading before 1.0 (IMO). > > It would be nice to figure out a way to make map.resources work out of > the box. I took at look at it and didn't see an easy way to accomplish > this, but maybe someone else has a better idea. The current > facebook_resources is not idea because it doesn't use standard naming > conventions (i.e. show_foos_path instead of foo_path (singular)). It > also only works for POSTs, where GET is necessary/more useful in some > cases. > > Anyone have any thoughts or have this working already? > > BJ > ----- > BJ Clark > the science department > bjclark at scidept.com > www.scidept.com > > > > On Jan 20, 2008, at 3:55 PM, Shawn Van Ittersum wrote: > > > Can we have some more comments for 1.0? I'm looking at > > facebook_url_rewriting.rb, and it's not clear what's going on. > > > > Shawn > > > > On Sun, 20 Jan 2008 15:40:30 -0700, BJ Clark wrote: > >> I'll reiterate, I'd be happy to get a copy of radiant up and going if > >> Mike(or anyone else) wants to provide the hosting. > >> > >> ----- > >> BJ Clark > >> the science department > >> bjclark at scidept.com > >> www.scidept.com > >> > >> > >> On Jan 20, 2008, at 3:35 PM, Shawn Van Ittersum wrote: > >> > >>> I can contribute to a tutorial. We just need a web site / CMS to > >>> publish the text... :) The most important thing missing from the > >>> current docs is how to access the current session, which David > >>> Clements showed me how to do last week. The rest is pretty easy to > >>> grasp from the RDoc, but I can contribute usage examples for the > >>> common functions. > >>> > >>> Shawn > >>> > >>> On Sun, 20 Jan 2008 11:06:36 +0000, Jon Gilbraith wrote: > >>>> Hey folks, > >>>> > >>>> Re: tutorials, I had planned to try and put together something a > >>>> while > >>>> back but since then had to reprioritise my projects so haven't been > >>>> able to keep up on things. If nobody else is able to help out in > >>>> this > >>>> area before then, I hope to be able to give it some time in late > >>>> Feb / > >>>> early March latest and would be happy to help out then. > >>>> > >>>> Cheers, > >>>> > >>>> Jon > >>>> > >>>> On 18 Jan 2008, at 16:32, David Newbury wrote: > >>>> > >>>>> Hey, Y'all. > >>>>> > >>>>> I'm Shane's designer friend, David. I am willing to work on a > >>>>> design > >>>>> and user interface for the site. I am currently using Radiant > >>>>> for a > >>>>> small project--i'm comfortable enough with it that I think it's a > >>>>> good > >>>>> choice for the site. > >>>>> > >>>>> Let me know what the next steps are. > >>>>> > >>>>> - David Newbury > >>>>> (773)-547-2272 > >>>>> www.workergnome.com > >>>>> > >>>>> On Jan 17, 2008, at 10:38 PM, "David Clements" > >>>>> > >>>>> wrote: > >>>>> > >>>>>> I can jump in and do some documentation if no one else is on it > >>>>>> yet? > >>>>>> > >>>>>> Dave > >>>>>> > >>>>>> > >>>>>> On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: > >>>>>>> Hey Mike- > >>>>>>> > >>>>>>> I can help with getting it working with apps with non-facebook > >>>>>>> sections. I'm working on fixing the issue with the facebook > >>>>>>> relative > >>>>>>> root being appended to non-facebook assets. I'd like to fix up > >>>>>>> routing before a 1.0 release as well. I think I might be able > >>>>>>> to > >>>>>>> get > >>>>>>> a designer for the site. I'll keep you posted. > >>>>>>> > >>>>>>> Shane > >>>>>>> > >>>>>>> > >>>>>>> On Jan 16, 2008 5:35 PM, Mike Mangino >>>>>>> > > >>>>>>> wrote: > >>>>>>>> Hey everybody. > >>>>>>>> > >>>>>>>> I've been using Facebooker on several projects over the last > >>>>>>>> few > >>>>>>>> months and feel like it is really starting to mature. I'd > >>>>>>>> like to > >>>>>>>> push > >>>>>>>> towards a 1.0 release within the next month. I'd really like > >>>>>>>> everybody's input on what still needs to be done, as well as > >>>>>>>> some > >>>>>>>> help > >>>>>>>> in wrapping things up. I've created a list of things that still > >>>>>>>> need > >>>>>>>> to be done on Facebooker. Can you guys take a look and send me > >>>>>>>> any > >>>>>>>> additions? I plan on spending next week looking at projects > >>>>>>>> with > >>>>>>>> both > >>>>>>>> Facebook and non-facebook sections. I'll try to clean up the > >>>>>>>> outstanding issues in that area. > >>>>>>>> > >>>>>>>> Before a 1.0 release, I think we need to: > >>>>>>>> > >>>>>>>> 1) Document all helpers and major methods. > >>>>>>>> > >>>>>>>> Most helpers have documentation, but it is a little sparse. I'd > >>>>>>>> love > >>>>>>>> some help adding rdoc to our helper methods along with any > >>>>>>>> other > >>>>>>>> method that is externally usable. > >>>>>>>> > >>>>>>>> 2) Implement object creation for all FQL types. > >>>>>>>> > >>>>>>>> Right now, we can only handle FQL queries for a few different > >>>>>>>> types. > >>>>>>>> We should support all of the available types. You can add > >>>>>>>> support > >>>>>>>> for > >>>>>>>> new types by editing parser.rb. Search for Fql there to see how > >>>>>>>> that > >>>>>>>> works. > >>>>>>>> > >>>>>>>> 3) Create a website for Facebooker > >>>>>>>> > >>>>>>>> I registered Facebooker-api.com and am willing to provide > >>>>>>>> hosting > >>>>>>>> hardware and bandwidth (through Elevated Rails) I would like to > >>>>>>>> use > >>>>>>>> Rubyforge for the issue tracker and mailing lists, but I can > >>>>>>>> create a > >>>>>>>> Radiant or Mephisto instance for hosting the main website. Is > >>>>>>>> anyone > >>>>>>>> interested in helping out here? I have no UI development > >>>>>>>> skills, > >>>>>>>> so a > >>>>>>>> nice UI would be appreciated as well. > >>>>>>>> > >>>>>>>> 4) Create a getting started tutorial > >>>>>>>> > >>>>>>>> Unfortunately, there is no good tutorial for how to setup a > >>>>>>>> Facebook > >>>>>>>> app with Facebooker. It would be nice to have at least a basic > >>>>>>>> getting > >>>>>>>> started guide. > >>>>>>>> > >>>>>>>> > >>>>>>>> So what have I missed? Is there anything else that we need to > >>>>>>>> do? > >>>>>>>> Does > >>>>>>>> anyone have any preferences about how to run the website? We > >>>>>>>> (Elevated > >>>>>>>> Rails) are using Radiant already, so that is easy for me to > >>>>>>>> setup. > >>>>>>>> I'm > >>>>>>>> open to other options. > >>>>>>>> > >>>>>>>> Thanks for your help and suggestions. > >>>>>>>> > >>>>>>>> > >>>>>>>> Mike > >>>>>>>> > >>>>>>>> > >>>>>>>> -- > >>>>>>>> Mike Mangino > >>>>>>>> http://www.elevatedrails.com > >>>>>>>> > >>>>>>>> _______________________________________________ > >>>>>>>> Facebooker-talk mailing list > >>>>>>>> Facebooker-talk at rubyforge.org > >>>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>>>>> > >>>>>>> > >>>>>>> > >>>>>>> > >>>>>>> -- > >>>>>>> http://myfitbuddy.com | http://shanesbrain.net | http:// > >>>>>>> crimsonjet.com > >>>>>>> > >>>>>>> _______________________________________________ > >>>>>>> Facebooker-talk mailing list > >>>>>>> Facebooker-talk at rubyforge.org > >>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>>>> > >>>>>> _______________________________________________ > >>>>>> Facebooker-talk mailing list > >>>>>> Facebooker-talk at rubyforge.org > >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>> _______________________________________________ > >>>>> Facebooker-talk mailing list > >>>>> Facebooker-talk at rubyforge.org > >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>> > >>>>> !DSPAM:4790d4bc212744243410844! > >>>>> > >>>>> > >>>> > >>>> _______________________________________________ > >>>> Facebooker-talk mailing list > >>>> Facebooker-talk at rubyforge.org > >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>> _______________________________________________ > >>> Facebooker-talk mailing list > >>> Facebooker-talk at rubyforge.org > >>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >> > >> _______________________________________________ > >> Facebooker-talk mailing list > >> Facebooker-talk at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From svicalifornia at gmail.com Sun Jan 20 19:50:35 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Sun, 20 Jan 2008 16:50:35 -0800 Subject: [Facebooker-talk] relative root In-Reply-To: References: <20080119182348238505.eca1866a@gmail.com> Message-ID: <20080120165035662986.1b6922e8@gmail.com> Hi David, What rfacebook does is perform substitute the controller part of the URL with the app name with a wrapper function around ActionController::Base::url_for. See this file: http://files.rubypub.com/rfacebook-0.9.7/lib/rfacebook_on_rails/controller_extensions.rb if path.starts_with?(self.facebook_callback_path) path.sub!(self.facebook_callback_path, self.facebook_canvas_path) path = "http://apps.facebook.com#{path}" elsif ... Thus it can ensure that any URL's generated by link_to will point to the facebook app and not include any portion of the server path that is already included in the facebook callback path. We need something like this in Facebooker, too. Shawn On Sat, 19 Jan 2008 20:46:29 -0700, David Clements wrote: > Hey Shawn, > > Are you saying that you basically only want one controller to handle > all your facebook requests? And that appname == controller? > > I looked into this scenario and it looks like maybe the code would > need to change to handle it. Basically you don't want to have any > relative_root_url and you set the Callback Url in your facebook > application settings to the same name as your controller. > > Something like http://appserver.com/facebook_handler > > Then create a facebook_handler_controller. > > And then change the code in facebook_url_rewriting to this > > def relative_url_root > "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" > if (parameters['fb_sig'] && > (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) > ) > end > > > This will effectively remove the relative url root. > > But maybe I am wrong as to what you are trying to do. > > > Dave > > > > On Jan 19, 2008 7:23 PM, Shawn Van Ittersum wrote: >> Hey guys, >> >> In rfacebook, the callback_path variable allows the developer to >> strip part of the URL off of auto-generated links (link_to). For >> example, if an app's canvas pages lead to a certain controller: >> >> http://apps.facebook.com/appname/index >> -> http://appserver.com/controller/index >> >> I want the link_to method to prefix the action with >> 'http://apps.facebook.com/appname/', automatically stripping out the >> app server and controller. The rfacebook config variables allows >> this with callback_path set to '/controller/'. >> >> Is there an equivalent behavior/config for Facebooker? >> >> Thanks, >> Shawn >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> From svicalifornia at gmail.com Sun Jan 20 20:15:34 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Sun, 20 Jan 2008 17:15:34 -0800 Subject: [Facebooker-talk] relative root In-Reply-To: References: <20080119182348238505.eca1866a@gmail.com> Message-ID: <20080120171534019268.73817541@gmail.com> How does Facebooker alter the ActionController::Base class? I see that rfacebook uses an include: ActionController::Base.send(:include, RFacebook::Rails::ControllerExtensions) ActionController::Base.send(:include, RFacebook::Rails::Plugin::ControllerExtensions) I need to do something similar to write the url_for wrapper, so I can rewrite the path returned by url_for. But I want to include the new function in the "right" Facebooker way. Shawn On Sat, 19 Jan 2008 20:46:29 -0700, David Clements wrote: > Hey Shawn, > > Are you saying that you basically only want one controller to handle > all your facebook requests? And that appname == controller? > > I looked into this scenario and it looks like maybe the code would > need to change to handle it. Basically you don't want to have any > relative_root_url and you set the Callback Url in your facebook > application settings to the same name as your controller. > > Something like http://appserver.com/facebook_handler > > Then create a facebook_handler_controller. > > And then change the code in facebook_url_rewriting to this > > def relative_url_root > "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" > if (parameters['fb_sig'] && > (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) > ) > end > > > This will effectively remove the relative url root. > > But maybe I am wrong as to what you are trying to do. > > > Dave > > > > On Jan 19, 2008 7:23 PM, Shawn Van Ittersum wrote: >> Hey guys, >> >> In rfacebook, the callback_path variable allows the developer to >> strip part of the URL off of auto-generated links (link_to). For >> example, if an app's canvas pages lead to a certain controller: >> >> http://apps.facebook.com/appname/index >> -> http://appserver.com/controller/index >> >> I want the link_to method to prefix the action with >> 'http://apps.facebook.com/appname/', automatically stripping out the >> app server and controller. The rfacebook config variables allows >> this with callback_path set to '/controller/'. >> >> Is there an equivalent behavior/config for Facebooker? >> >> Thanks, >> Shawn >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> From digidigo at gmail.com Sun Jan 20 20:30:52 2008 From: digidigo at gmail.com (David Clements) Date: Sun, 20 Jan 2008 18:30:52 -0700 Subject: [Facebooker-talk] relative root In-Reply-To: <20080120171534019268.73817541@gmail.com> References: <20080119182348238505.eca1866a@gmail.com> <20080120171534019268.73817541@gmail.com> Message-ID: Hey Shawn, The Facebooker way is to set your relative root via ENV["FACEBOOKER_RELATIVE_URL_ROOT"] , this root should have nothing to do with your controller names. For me I make it my app name. The facebooker way to do this is to utilize the rails support for relative root path. This allows for all of your URLs, whether you are a facebook app or not, to have a prefix to the path. Facebooker strips this FACEBOOKER_RELATIVE_ROOT on the way in, and the url rewrite code adds it in for you along with apps.facebook.com. This effects all the urls generated via url_for. After doing this, all of your controllers will generate canvas based urls, whether link_to or url_for. Does that make sense? I am not familiar with rfacebook, so I think I misunderstood your original intent. I will also start documenting some of the code so that some of these answers can be gleaned from a quick read. Dave On Jan 20, 2008 6:15 PM, Shawn Van Ittersum wrote: > How does Facebooker alter the ActionController::Base class? I see that rfacebook uses an include: > > ActionController::Base.send(:include, RFacebook::Rails::ControllerExtensions) > ActionController::Base.send(:include, RFacebook::Rails::Plugin::ControllerExtensions) > > I need to do something similar to write the url_for wrapper, so I can rewrite the path returned by url_for. But I want to include the new function in the "right" Facebooker way. > > Shawn > > On Sat, 19 Jan 2008 20:46:29 -0700, David Clements wrote: > > > Hey Shawn, > > > > Are you saying that you basically only want one controller to handle > > all your facebook requests? And that appname == controller? > > > > I looked into this scenario and it looks like maybe the code would > > need to change to handle it. Basically you don't want to have any > > relative_root_url and you set the Callback Url in your facebook > > application settings to the same name as your controller. > > > > Something like http://appserver.com/facebook_handler > > > > Then create a facebook_handler_controller. > > > > And then change the code in facebook_url_rewriting to this > > > > def relative_url_root > > "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" > > if (parameters['fb_sig'] && > > (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) > > ) > > end > > > > > > This will effectively remove the relative url root. > > > > But maybe I am wrong as to what you are trying to do. > > > > > > Dave > > > > > > > > On Jan 19, 2008 7:23 PM, Shawn Van Ittersum wrote: > >> Hey guys, > >> > >> In rfacebook, the callback_path variable allows the developer to > >> strip part of the URL off of auto-generated links (link_to). For > >> example, if an app's canvas pages lead to a certain controller: > >> > >> http://apps.facebook.com/appname/index > >> -> http://appserver.com/controller/index > >> > >> I want the link_to method to prefix the action with > >> 'http://apps.facebook.com/appname/', automatically stripping out the > >> app server and controller. The rfacebook config variables allows > >> this with callback_path set to '/controller/'. > >> > >> Is there an equivalent behavior/config for Facebooker? > >> > >> Thanks, > >> Shawn > >> _______________________________________________ > >> Facebooker-talk mailing list > >> Facebooker-talk at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/facebooker-talk > >> > From svicalifornia at gmail.com Sun Jan 20 21:15:27 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Sun, 20 Jan 2008 18:15:27 -0800 Subject: [Facebooker-talk] relative root In-Reply-To: References: <20080119182348238505.eca1866a@gmail.com> <20080120171534019268.73817541@gmail.com> Message-ID: <20080120181527284352.6b9752f0@gmail.com> BTW, the reason I'm pointing the app's callback path to a specific controller is that the facebook app is an add-on to a regular web app, so the other controllers are serving the standard web app, and I want the facebook app confined to its own controller. So it is not ideal for me to use routes to get apps.facebook.com/appname to redirect to apps.facebook.com/appname/controller/index... Shawn On Sun, 20 Jan 2008 18:30:52 -0700, David Clements wrote: > Hey Shawn, > > The Facebooker way is to set your relative root via > ENV["FACEBOOKER_RELATIVE_URL_ROOT"] , this root should have nothing to > do with your controller names. For me I make it my app name. > > The facebooker way to do this is to utilize the rails support for > relative root path. This allows for all of your URLs, whether you are > a facebook app or not, to have a prefix to the path. Facebooker > strips this FACEBOOKER_RELATIVE_ROOT on the way in, and the url > rewrite code adds it in for you along with apps.facebook.com. This > effects all the urls generated via url_for. > > After doing this, all of your controllers will generate canvas based > urls, whether link_to or url_for. > > Does that make sense? I am not familiar with rfacebook, so I think I > misunderstood your original intent. > > I will also start documenting some of the code so that some of these > answers can be gleaned from a quick read. > > Dave > > On Jan 20, 2008 6:15 PM, Shawn Van Ittersum wrote: >> How does Facebooker alter the ActionController::Base class? I see >> that rfacebook uses an include: >> >> ActionController::Base.send(:include, >> RFacebook::Rails::ControllerExtensions) >> ActionController::Base.send(:include, >> RFacebook::Rails::Plugin::ControllerExtensions) >> >> I need to do something similar to write the url_for wrapper, so I >> can rewrite the path returned by url_for. But I want to include the >> new function in the "right" Facebooker way. >> >> Shawn >> >> On Sat, 19 Jan 2008 20:46:29 -0700, David Clements wrote: >> >>> Hey Shawn, >>> >>> Are you saying that you basically only want one controller to handle >>> all your facebook requests? And that appname == controller? >>> >>> I looked into this scenario and it looks like maybe the code would >>> need to change to handle it. Basically you don't want to have any >>> relative_root_url and you set the Callback Url in your facebook >>> application settings to the same name as your controller. >>> >>> Something like http://appserver.com/facebook_handler >>> >>> Then create a facebook_handler_controller. >>> >>> And then change the code in facebook_url_rewriting to this >>> >>> def relative_url_root >>> >>> "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" >>> if (parameters['fb_sig'] && >>> (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) >>> ) >>> end >>> >>> >>> This will effectively remove the relative url root. >>> >>> But maybe I am wrong as to what you are trying to do. >>> >>> >>> Dave >>> >>> >>> >>> On Jan 19, 2008 7:23 PM, Shawn Van Ittersum >>> wrote: >>>> Hey guys, >>>> >>>> In rfacebook, the callback_path variable allows the developer to >>>> strip part of the URL off of auto-generated links (link_to). For >>>> example, if an app's canvas pages lead to a certain controller: >>>> >>>> http://apps.facebook.com/appname/index >>>> -> http://appserver.com/controller/index >>>> >>>> I want the link_to method to prefix the action with >>>> 'http://apps.facebook.com/appname/', automatically stripping out the >>>> app server and controller. The rfacebook config variables allows >>>> this with callback_path set to '/controller/'. >>>> >>>> Is there an equivalent behavior/config for Facebooker? >>>> >>>> Thanks, >>>> Shawn >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >> From digidigo at gmail.com Sun Jan 20 22:02:23 2008 From: digidigo at gmail.com (David Clements) Date: Sun, 20 Jan 2008 20:02:23 -0700 Subject: [Facebooker-talk] relative root In-Reply-To: <20080120181527284352.6b9752f0@gmail.com> References: <20080119182348238505.eca1866a@gmail.com> <20080120171534019268.73817541@gmail.com> <20080120181527284352.6b9752f0@gmail.com> Message-ID: Hey Shawn, I think I understand and my initial post should address the issue, and I tested it in my dev environment to make sure. Basically you don't want any relative root url, the current code has a deficiency (IMHO), and the change that I suggested should allow you to avoid the issue that you are having. I'll wrap it up as a patch and see if the guys want to change it. But to get you going you change the code in facebook_url_rewriting to this def relative_url_root "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" if (parameters['fb_sig'] && (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) ) end And then remove any env variable for FACEBOOKER_RELATIVE_URL_ROOT or FACEBOOK_CANVAS_PATH. Does that make sense? Dave On Jan 20, 2008 7:15 PM, Shawn Van Ittersum wrote: > BTW, the reason I'm pointing the app's callback path to a specific controller is that the facebook app is an add-on to a regular web app, so the other controllers are serving the standard web app, and I want the facebook app confined to its own controller. So it is not ideal for me to use routes to get apps.facebook.com/appname to redirect to apps.facebook.com/appname/controller/index... > > Shawn > > > On Sun, 20 Jan 2008 18:30:52 -0700, David Clements wrote: > > Hey Shawn, > > > > The Facebooker way is to set your relative root via > > ENV["FACEBOOKER_RELATIVE_URL_ROOT"] , this root should have nothing to > > do with your controller names. For me I make it my app name. > > > > The facebooker way to do this is to utilize the rails support for > > relative root path. This allows for all of your URLs, whether you are > > a facebook app or not, to have a prefix to the path. Facebooker > > strips this FACEBOOKER_RELATIVE_ROOT on the way in, and the url > > rewrite code adds it in for you along with apps.facebook.com. This > > effects all the urls generated via url_for. > > > > After doing this, all of your controllers will generate canvas based > > urls, whether link_to or url_for. > > > > Does that make sense? I am not familiar with rfacebook, so I think I > > misunderstood your original intent. > > > > I will also start documenting some of the code so that some of these > > answers can be gleaned from a quick read. > > > > Dave > > > > On Jan 20, 2008 6:15 PM, Shawn Van Ittersum wrote: > >> How does Facebooker alter the ActionController::Base class? I see > >> that rfacebook uses an include: > >> > >> ActionController::Base.send(:include, > >> RFacebook::Rails::ControllerExtensions) > >> ActionController::Base.send(:include, > >> RFacebook::Rails::Plugin::ControllerExtensions) > >> > >> I need to do something similar to write the url_for wrapper, so I > >> can rewrite the path returned by url_for. But I want to include the > >> new function in the "right" Facebooker way. > >> > >> Shawn > >> > >> On Sat, 19 Jan 2008 20:46:29 -0700, David Clements wrote: > >> > >>> Hey Shawn, > >>> > >>> Are you saying that you basically only want one controller to handle > >>> all your facebook requests? And that appname == controller? > >>> > >>> I looked into this scenario and it looks like maybe the code would > >>> need to change to handle it. Basically you don't want to have any > >>> relative_root_url and you set the Callback Url in your facebook > >>> application settings to the same name as your controller. > >>> > >>> Something like http://appserver.com/facebook_handler > >>> > >>> Then create a facebook_handler_controller. > >>> > >>> And then change the code in facebook_url_rewriting to this > >>> > >>> def relative_url_root > >>> > >>> "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" > >>> if (parameters['fb_sig'] && > >>> (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) > >>> ) > >>> end > >>> > >>> > >>> This will effectively remove the relative url root. > >>> > >>> But maybe I am wrong as to what you are trying to do. > >>> > >>> > >>> Dave > >>> > >>> > >>> > >>> On Jan 19, 2008 7:23 PM, Shawn Van Ittersum > >>> wrote: > >>>> Hey guys, > >>>> > >>>> In rfacebook, the callback_path variable allows the developer to > >>>> strip part of the URL off of auto-generated links (link_to). For > >>>> example, if an app's canvas pages lead to a certain controller: > >>>> > >>>> http://apps.facebook.com/appname/index > >>>> -> http://appserver.com/controller/index > >>>> > >>>> I want the link_to method to prefix the action with > >>>> 'http://apps.facebook.com/appname/', automatically stripping out the > >>>> app server and controller. The rfacebook config variables allows > >>>> this with callback_path set to '/controller/'. > >>>> > >>>> Is there an equivalent behavior/config for Facebooker? > >>>> > >>>> Thanks, > >>>> Shawn > >>>> _______________________________________________ > >>>> Facebooker-talk mailing list > >>>> Facebooker-talk at rubyforge.org > >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>> > >> > From svicalifornia at gmail.com Sun Jan 20 22:14:03 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Sun, 20 Jan 2008 19:14:03 -0800 Subject: [Facebooker-talk] relative root In-Reply-To: References: <20080119182348238505.eca1866a@gmail.com> <20080120171534019268.73817541@gmail.com> Message-ID: <20080120191403853264.6c671b20@gmail.com> I hacked a bit and got the rfacebook behavior to work. I've probably broken the Facebooker way, so we'll need to reconcile the changes somehow to make it backward compatible with existing Facebooker apps. Here's the new sub as I have it: def rewrite_url_with_facebooker(*args) options = args.first.is_a?(Hash) ? args.first : args.last is_link_to_canvas = link_to_canvas?(@request.request_parameters, options) #options[:skip_relative_url_root] ||= !is_link_to_canvas options[:skip_relative_url_root] = true if is_link_to_canvas && !options.has_key?(:host) options[:host] = "apps.facebook.com" end options.delete(:canvas) path = rewrite_url_without_facebooker(*args) facebook_canvas_path = ENV['FACEBOOKER_RELATIVE_URL_ROOT'] || ENV['FACEBOOK_CANVAS_PATH'] facebook_callback_path = ENV['FACEBOOKER_CALLBACK_PATH'] print "path: #{path}\n\n" # for debugging only # replace anything that references the callback with the # Facebook canvas equivalent (apps.facebook.com/*) if path.starts_with?(facebook_callback_path) path.sub!(facebook_callback_path, facebook_canvas_path) path = "http://apps.facebook.com#{path}" elsif "#{path}/".starts_with?(facebook_callback_path) path.sub!(facebook_callback_path.chop, facebook_canvas_path.chop) path = "http://apps.facebook.com#{path}" elsif (path.starts_with?("http://www.facebook.com") or path.starts_with?("https://www.facebook.com")) # be sure that URLs that go to some other Facebook service redirect back to the canvas if path.include?("?") path = "#{path}&canvas=true" else path = "#{path}?canvas=true" end elsif (!path.starts_with?("http://") and !path.starts_with?("https://")) # this will fail here because 'request' is not defined; need to translate to Facebooker vars # default to a full URL (will link externally) RAILS_DEFAULT_LOGGER.debug "** RFACEBOOK INFO: failed to get canvas-friendly URL ("+path+") for ["+options.inspect+"], creating an external URL instead" path = "#{request.protocol}#{request.host}:#{request.port}#{path}" end end Shawn On Sun, 20 Jan 2008 18:30:52 -0700, David Clements wrote: > Hey Shawn, > > The Facebooker way is to set your relative root via > ENV["FACEBOOKER_RELATIVE_URL_ROOT"] , this root should have nothing to > do with your controller names. For me I make it my app name. > > The facebooker way to do this is to utilize the rails support for > relative root path. This allows for all of your URLs, whether you are > a facebook app or not, to have a prefix to the path. Facebooker > strips this FACEBOOKER_RELATIVE_ROOT on the way in, and the url > rewrite code adds it in for you along with apps.facebook.com. This > effects all the urls generated via url_for. > > After doing this, all of your controllers will generate canvas based > urls, whether link_to or url_for. > > Does that make sense? I am not familiar with rfacebook, so I think I > misunderstood your original intent. > > I will also start documenting some of the code so that some of these > answers can be gleaned from a quick read. > > Dave > > On Jan 20, 2008 6:15 PM, Shawn Van Ittersum wrote: >> How does Facebooker alter the ActionController::Base class? I see >> that rfacebook uses an include: >> >> ActionController::Base.send(:include, >> RFacebook::Rails::ControllerExtensions) >> ActionController::Base.send(:include, >> RFacebook::Rails::Plugin::ControllerExtensions) >> >> I need to do something similar to write the url_for wrapper, so I >> can rewrite the path returned by url_for. But I want to include the >> new function in the "right" Facebooker way. >> >> Shawn >> >> On Sat, 19 Jan 2008 20:46:29 -0700, David Clements wrote: >> >>> Hey Shawn, >>> >>> Are you saying that you basically only want one controller to handle >>> all your facebook requests? And that appname == controller? >>> >>> I looked into this scenario and it looks like maybe the code would >>> need to change to handle it. Basically you don't want to have any >>> relative_root_url and you set the Callback Url in your facebook >>> application settings to the same name as your controller. >>> >>> Something like http://appserver.com/facebook_handler >>> >>> Then create a facebook_handler_controller. >>> >>> And then change the code in facebook_url_rewriting to this >>> >>> def relative_url_root >>> >>> "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" >>> if (parameters['fb_sig'] && >>> (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) >>> ) >>> end >>> >>> >>> This will effectively remove the relative url root. >>> >>> But maybe I am wrong as to what you are trying to do. >>> >>> >>> Dave >>> >>> >>> >>> On Jan 19, 2008 7:23 PM, Shawn Van Ittersum >>> wrote: >>>> Hey guys, >>>> >>>> In rfacebook, the callback_path variable allows the developer to >>>> strip part of the URL off of auto-generated links (link_to). For >>>> example, if an app's canvas pages lead to a certain controller: >>>> >>>> http://apps.facebook.com/appname/index >>>> -> http://appserver.com/controller/index >>>> >>>> I want the link_to method to prefix the action with >>>> 'http://apps.facebook.com/appname/', automatically stripping out the >>>> app server and controller. The rfacebook config variables allows >>>> this with callback_path set to '/controller/'. >>>> >>>> Is there an equivalent behavior/config for Facebooker? >>>> >>>> Thanks, >>>> Shawn >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >> From mmangino at elevatedrails.com Mon Jan 21 01:46:07 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Mon, 21 Jan 2008 00:46:07 -0600 Subject: [Facebooker-talk] Towards a 1.0 release In-Reply-To: <631618CA-1342-41EB-9132-E7E1C921C030@scidept.com> References: <89393DF9-D385-48DE-8D0D-B828D530DEA8@elevatedrails.com> <4ab757a40801161742m75faa11ay9d36a7dd3652903f@mail.gmail.com> <20080120143539934325.5c4b16a3@gmail.com> <631618CA-1342-41EB-9132-E7E1C921C030@scidept.com> Message-ID: <7788913A-A7E1-424B-94AD-04199D104BDB@elevatedrails.com> I'll set that up tomorrow. I can't give shell access until I free up another machine, but we can at least get started. Mike On Jan 20, 2008, at 4:40 PM, BJ Clark wrote: > I'll reiterate, I'd be happy to get a copy of radiant up and going if > Mike(or anyone else) wants to provide the hosting. > > ----- > BJ Clark > the science department > bjclark at scidept.com > www.scidept.com > > > On Jan 20, 2008, at 3:35 PM, Shawn Van Ittersum wrote: > >> I can contribute to a tutorial. We just need a web site / CMS to >> publish the text... :) The most important thing missing from the >> current docs is how to access the current session, which David >> Clements showed me how to do last week. The rest is pretty easy to >> grasp from the RDoc, but I can contribute usage examples for the >> common functions. >> >> Shawn >> >> On Sun, 20 Jan 2008 11:06:36 +0000, Jon Gilbraith wrote: >>> Hey folks, >>> >>> Re: tutorials, I had planned to try and put together something a >>> while >>> back but since then had to reprioritise my projects so haven't been >>> able to keep up on things. If nobody else is able to help out in >>> this >>> area before then, I hope to be able to give it some time in late >>> Feb / >>> early March latest and would be happy to help out then. >>> >>> Cheers, >>> >>> Jon >>> >>> On 18 Jan 2008, at 16:32, David Newbury wrote: >>> >>>> Hey, Y'all. >>>> >>>> I'm Shane's designer friend, David. I am willing to work on a >>>> design >>>> and user interface for the site. I am currently using Radiant >>>> for a >>>> small project--i'm comfortable enough with it that I think it's a >>>> good >>>> choice for the site. >>>> >>>> Let me know what the next steps are. >>>> >>>> - David Newbury >>>> (773)-547-2272 >>>> www.workergnome.com >>>> >>>> On Jan 17, 2008, at 10:38 PM, "David Clements" >>>> wrote: >>>> >>>>> I can jump in and do some documentation if no one else is on it >>>>> yet? >>>>> >>>>> Dave >>>>> >>>>> >>>>> On Jan 16, 2008 6:42 PM, Shane Vitarana wrote: >>>>>> Hey Mike- >>>>>> >>>>>> I can help with getting it working with apps with non-facebook >>>>>> sections. I'm working on fixing the issue with the facebook >>>>>> relative >>>>>> root being appended to non-facebook assets. I'd like to fix up >>>>>> routing before a 1.0 release as well. I think I might be able to >>>>>> get >>>>>> a designer for the site. I'll keep you posted. >>>>>> >>>>>> Shane >>>>>> >>>>>> >>>>>> On Jan 16, 2008 5:35 PM, Mike Mangino >>>>>> >>>>>> wrote: >>>>>>> Hey everybody. >>>>>>> >>>>>>> I've been using Facebooker on several projects over the last few >>>>>>> months and feel like it is really starting to mature. I'd like >>>>>>> to >>>>>>> push >>>>>>> towards a 1.0 release within the next month. I'd really like >>>>>>> everybody's input on what still needs to be done, as well as >>>>>>> some >>>>>>> help >>>>>>> in wrapping things up. I've created a list of things that still >>>>>>> need >>>>>>> to be done on Facebooker. Can you guys take a look and send me >>>>>>> any >>>>>>> additions? I plan on spending next week looking at projects with >>>>>>> both >>>>>>> Facebook and non-facebook sections. I'll try to clean up the >>>>>>> outstanding issues in that area. >>>>>>> >>>>>>> Before a 1.0 release, I think we need to: >>>>>>> >>>>>>> 1) Document all helpers and major methods. >>>>>>> >>>>>>> Most helpers have documentation, but it is a little sparse. I'd >>>>>>> love >>>>>>> some help adding rdoc to our helper methods along with any other >>>>>>> method that is externally usable. >>>>>>> >>>>>>> 2) Implement object creation for all FQL types. >>>>>>> >>>>>>> Right now, we can only handle FQL queries for a few different >>>>>>> types. >>>>>>> We should support all of the available types. You can add >>>>>>> support >>>>>>> for >>>>>>> new types by editing parser.rb. Search for Fql there to see how >>>>>>> that >>>>>>> works. >>>>>>> >>>>>>> 3) Create a website for Facebooker >>>>>>> >>>>>>> I registered Facebooker-api.com and am willing to provide >>>>>>> hosting >>>>>>> hardware and bandwidth (through Elevated Rails) I would like to >>>>>>> use >>>>>>> Rubyforge for the issue tracker and mailing lists, but I can >>>>>>> create a >>>>>>> Radiant or Mephisto instance for hosting the main website. Is >>>>>>> anyone >>>>>>> interested in helping out here? I have no UI development skills, >>>>>>> so a >>>>>>> nice UI would be appreciated as well. >>>>>>> >>>>>>> 4) Create a getting started tutorial >>>>>>> >>>>>>> Unfortunately, there is no good tutorial for how to setup a >>>>>>> Facebook >>>>>>> app with Facebooker. It would be nice to have at least a basic >>>>>>> getting >>>>>>> started guide. >>>>>>> >>>>>>> >>>>>>> So what have I missed? Is there anything else that we need to >>>>>>> do? >>>>>>> Does >>>>>>> anyone have any preferences about how to run the website? We >>>>>>> (Elevated >>>>>>> Rails) are using Radiant already, so that is easy for me to >>>>>>> setup. >>>>>>> I'm >>>>>>> open to other options. >>>>>>> >>>>>>> Thanks for your help and suggestions. >>>>>>> >>>>>>> >>>>>>> Mike >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> Mike Mangino >>>>>>> http://www.elevatedrails.com >>>>>>> >>>>>>> _______________________________________________ >>>>>>> Facebooker-talk mailing list >>>>>>> Facebooker-talk at rubyforge.org >>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>> >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>>>> crimsonjet.com >>>>>> >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>> >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>>> !DSPAM:4790d4bc212744243410844! >>>> >>>> >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From svicalifornia at gmail.com Mon Jan 21 17:24:33 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Mon, 21 Jan 2008 14:24:33 -0800 Subject: [Facebooker-talk] Facebooker website In-Reply-To: References: <74200FED-B3EB-416A-8A0F-F4FDF96BFEE7@elevatedrails.com> Message-ID: <20080121142433608148.934083ae@gmail.com> I just wanted to contribute a quick-start page with details about how to get the Facebook session (for internal apps), how to get user info, set profile FBML, post to the news feed, etc. I could even send this as text, or I can add a page using the Radiant CMS if it's not too cumbersome. I am also working with Dave Clements to augment the configuration options to make it easier for rfacebook users to migrate to Facebooker, now that rfacebook maintenance has been officially discontinued. The lead developer of rfacebook is now encouraging people to use Facebooker, which is how I got here. :) Along these lines, it will also be nice to have YAML configuration similar to rfacebook's, instead of setting ENV variables in environment scripts. So that will be my focus. I will be traveling a lot in the next month and may not be able to commit much more than this. Shawn On Mon, 21 Jan 2008 09:43:50 -0600, David Newbury wrote: > Shawn, you're interested in providing a tutorial, right? What do you > need to work on that, and what can we expect from you? From mmangino at elevatedrails.com Mon Jan 21 17:42:29 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Mon, 21 Jan 2008 16:42:29 -0600 Subject: [Facebooker-talk] Facebooker website In-Reply-To: <20080121142433608148.934083ae@gmail.com> References: <74200FED-B3EB-416A-8A0F-F4FDF96BFEE7@elevatedrails.com> <20080121142433608148.934083ae@gmail.com> Message-ID: <4E98B625-3BC6-4CB4-8BD7-4B4A18F7853F@elevatedrails.com> Shane was working on YAML configuration files as well. Make sure you ping him about that. Mike On Jan 21, 2008, at 4:24 PM, Shawn Van Ittersum wrote: > I just wanted to contribute a quick-start page with details about > how to get the Facebook session (for internal apps), how to get user > info, set profile FBML, post to the news feed, etc. I could even > send this as text, or I can add a page using the Radiant CMS if it's > not too cumbersome. > > I am also working with Dave Clements to augment the configuration > options to make it easier for rfacebook users to migrate to > Facebooker, now that rfacebook maintenance has been officially > discontinued. The lead developer of rfacebook is now encouraging > people to use Facebooker, which is how I got here. :) > > Along these lines, it will also be nice to have YAML configuration > similar to rfacebook's, instead of setting ENV variables in > environment scripts. > > So that will be my focus. I will be traveling a lot in the next > month and may not be able to commit much more than this. > > Shawn > > On Mon, 21 Jan 2008 09:43:50 -0600, David Newbury wrote: >> Shawn, you're interested in providing a tutorial, right? What do you >> need to work on that, and what can we expect from you? > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From digidigo at gmail.com Mon Jan 21 23:05:17 2008 From: digidigo at gmail.com (David Clements) Date: Mon, 21 Jan 2008 21:05:17 -0700 Subject: [Facebooker-talk] relative root In-Reply-To: <20080120191403853264.6c671b20@gmail.com> References: <20080119182348238505.eca1866a@gmail.com> <20080120171534019268.73817541@gmail.com> <20080120191403853264.6c671b20@gmail.com> Message-ID: Hey Shawn, FYI: I played around with this some more today with the application that has the same requirements as yours: Canvas path is http://apps.facebook.com/travelerstable Callback URL is http://www.travelerstable.com/facebook Controller is facebook_controller, and the is only one controller that handles all the facebook requests. This is the same sort of setup that you have right? I was able to get facebooker to work by implementing the previous mentioned change that allows AbstractRequest.relative_root_url to return nil if it is not set and by adding this route. map.canvas_page_base("#{ENV["FACEBOOK_APP_NAME"]}/:action/:id", :controller => 'facebook') I remember you saying that you didn't really like this approach, but I thought I would try it out anyway. I would like to take a poll to understand how many people fall into one of these four use cases. 1) Callback path and canvas path have the same ending. 2) Callback path and canvas path have a different ending and app uses multiple controllers to handle facebook requests 3) Callback path and canvas path have a different ending and app use one controller to handle all facebook requests ( This is what Shawn and I have been discussing. ) 4) Callback path only contains the host portion. (ex. http://www.example.com/ ) I hope that is clear, did I cover them all? Dave On Jan 20, 2008 8:14 PM, Shawn Van Ittersum wrote: > I hacked a bit and got the rfacebook behavior to work. I've probably broken the Facebooker way, so we'll need to reconcile the changes somehow to make it backward compatible with existing Facebooker apps. > > Here's the new sub as I have it: > > def rewrite_url_with_facebooker(*args) > options = args.first.is_a?(Hash) ? args.first : args.last > is_link_to_canvas = link_to_canvas?(@request.request_parameters, options) > #options[:skip_relative_url_root] ||= !is_link_to_canvas > options[:skip_relative_url_root] = true > if is_link_to_canvas && !options.has_key?(:host) > options[:host] = "apps.facebook.com" > end > options.delete(:canvas) > > path = rewrite_url_without_facebooker(*args) > > facebook_canvas_path = ENV['FACEBOOKER_RELATIVE_URL_ROOT'] || ENV['FACEBOOK_CANVAS_PATH'] > facebook_callback_path = ENV['FACEBOOKER_CALLBACK_PATH'] > > print "path: #{path}\n\n" # for debugging only > > # replace anything that references the callback with the > # Facebook canvas equivalent (apps.facebook.com/*) > if path.starts_with?(facebook_callback_path) > path.sub!(facebook_callback_path, facebook_canvas_path) > path = "http://apps.facebook.com#{path}" > elsif "#{path}/".starts_with?(facebook_callback_path) > path.sub!(facebook_callback_path.chop, facebook_canvas_path.chop) > path = "http://apps.facebook.com#{path}" > elsif (path.starts_with?("http://www.facebook.com") or path.starts_with?("https://www.facebook.com")) > # be sure that URLs that go to some other Facebook service redirect back to the canvas > if path.include?("?") > path = "#{path}&canvas=true" > else > path = "#{path}?canvas=true" > end > elsif (!path.starts_with?("http://") and !path.starts_with?("https://")) > # this will fail here because 'request' is not defined; need to translate to Facebooker vars > > # default to a full URL (will link externally) > RAILS_DEFAULT_LOGGER.debug "** RFACEBOOK INFO: failed to get canvas-friendly URL ("+path+") for ["+options.inspect+"], creating an external URL instead" > path = "#{request.protocol}#{request.host}:#{request.port}#{path}" > end > end > > Shawn > > > On Sun, 20 Jan 2008 18:30:52 -0700, David Clements wrote: > > Hey Shawn, > > > > The Facebooker way is to set your relative root via > > ENV["FACEBOOKER_RELATIVE_URL_ROOT"] , this root should have nothing to > > do with your controller names. For me I make it my app name. > > > > The facebooker way to do this is to utilize the rails support for > > relative root path. This allows for all of your URLs, whether you are > > a facebook app or not, to have a prefix to the path. Facebooker > > strips this FACEBOOKER_RELATIVE_ROOT on the way in, and the url > > rewrite code adds it in for you along with apps.facebook.com. This > > effects all the urls generated via url_for. > > > > After doing this, all of your controllers will generate canvas based > > urls, whether link_to or url_for. > > > > Does that make sense? I am not familiar with rfacebook, so I think I > > misunderstood your original intent. > > > > I will also start documenting some of the code so that some of these > > answers can be gleaned from a quick read. > > > > Dave > > > > On Jan 20, 2008 6:15 PM, Shawn Van Ittersum wrote: > >> How does Facebooker alter the ActionController::Base class? I see > >> that rfacebook uses an include: > >> > >> ActionController::Base.send(:include, > >> RFacebook::Rails::ControllerExtensions) > >> ActionController::Base.send(:include, > >> RFacebook::Rails::Plugin::ControllerExtensions) > >> > >> I need to do something similar to write the url_for wrapper, so I > >> can rewrite the path returned by url_for. But I want to include the > >> new function in the "right" Facebooker way. > >> > >> Shawn > >> > >> On Sat, 19 Jan 2008 20:46:29 -0700, David Clements wrote: > >> > >>> Hey Shawn, > >>> > >>> Are you saying that you basically only want one controller to handle > >>> all your facebook requests? And that appname == controller? > >>> > >>> I looked into this scenario and it looks like maybe the code would > >>> need to change to handle it. Basically you don't want to have any > >>> relative_root_url and you set the Callback Url in your facebook > >>> application settings to the same name as your controller. > >>> > >>> Something like http://appserver.com/facebook_handler > >>> > >>> Then create a facebook_handler_controller. > >>> > >>> And then change the code in facebook_url_rewriting to this > >>> > >>> def relative_url_root > >>> > >>> "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" > >>> if (parameters['fb_sig'] && > >>> (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) > >>> ) > >>> end > >>> > >>> > >>> This will effectively remove the relative url root. > >>> > >>> But maybe I am wrong as to what you are trying to do. > >>> > >>> > >>> Dave > >>> > >>> > >>> > >>> On Jan 19, 2008 7:23 PM, Shawn Van Ittersum > >>> wrote: > >>>> Hey guys, > >>>> > >>>> In rfacebook, the callback_path variable allows the developer to > >>>> strip part of the URL off of auto-generated links (link_to). For > >>>> example, if an app's canvas pages lead to a certain controller: > >>>> > >>>> http://apps.facebook.com/appname/index > >>>> -> http://appserver.com/controller/index > >>>> > >>>> I want the link_to method to prefix the action with > >>>> 'http://apps.facebook.com/appname/', automatically stripping out the > >>>> app server and controller. The rfacebook config variables allows > >>>> this with callback_path set to '/controller/'. > >>>> > >>>> Is there an equivalent behavior/config for Facebooker? > >>>> > >>>> Thanks, > >>>> Shawn > >>>> _______________________________________________ > >>>> Facebooker-talk mailing list > >>>> Facebooker-talk at rubyforge.org > >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>> > >> > From svicalifornia at gmail.com Tue Jan 22 00:49:02 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Mon, 21 Jan 2008 21:49:02 -0800 Subject: [Facebooker-talk] relative root In-Reply-To: References: <20080119182348238505.eca1866a@gmail.com> <20080120171534019268.73817541@gmail.com> <20080120191403853264.6c671b20@gmail.com> Message-ID: <20080121214902901737.27c91a72@gmail.com> Hey Dave, Thanks for looking into this and other alternative approaches to this case. I appreciate the ideas and proposed workarounds. However, it would be great if Facebooker offered the same flexibility of configuration as rfacebook does, so developers who started there do not have to change the routing of their applications to use Facebooker. Of course I would not want to impact existing Facebooker apps, but I believe it is possible to support the URL rewriting done by rfacebook in a way that is backward compatible with existing Facebooker configs. I believe the rfacebook solution handles all of the cases Dave is polling about now, and for any developers who want to use the Facebooker framework to handle any of these use cases, it is much easier to explain how to set the callback_path (which is already set on the Facebook Developers app) than to explain the various routing solutions on a case-by-case basis. And the callback_path rewriting solution ensures that the routing exceptions will not need revisited, relearned, and modified should the design of an application change. One need only change the callback_path or appname as necessary, which is extremely simple, making app changes much easier to implement. With our progress last night, we are very close and should be able to support the callback_path URL rewrite by the end of the week. Shawn On Mon, 21 Jan 2008 21:05:17 -0700, David Clements wrote: > Hey Shawn, > > FYI: > I played around with this some more today with the application that > has the same requirements as yours: > > Canvas path is http://apps.facebook.com/travelerstable > Callback URL is http://www.travelerstable.com/facebook > > Controller is facebook_controller, and the is only one controller that > handles all the facebook requests. This is the same sort of setup > that you have right? > > I was able to get facebooker to work by implementing the previous > mentioned change that allows AbstractRequest.relative_root_url to > return nil if it is not set and by adding this route. > > map.canvas_page_base("#{ENV["FACEBOOK_APP_NAME"]}/:action/:id", > :controller => 'facebook') > > I remember you saying that you didn't really like this approach, but I > thought I would try it out anyway. > > > > I would like to take a poll to understand how many people fall into > one of these four use cases. > > > 1) Callback path and canvas path have the same ending. > 2) Callback path and canvas path have a different ending and app uses > multiple controllers to handle facebook requests > 3) Callback path and canvas path have a different ending and app use > one controller to handle all facebook requests ( This is what Shawn > and I have been discussing. ) > 4) Callback path only contains the host portion. (ex. > http://www.example.com/ ) > > I hope that is clear, did I cover them all? > Dave > > > > > On Jan 20, 2008 8:14 PM, Shawn Van Ittersum wrote: >> I hacked a bit and got the rfacebook behavior to work. I've >> probably broken the Facebooker way, so we'll need to reconcile the >> changes somehow to make it backward compatible with existing >> Facebooker apps. >> >> Here's the new sub as I have it: >> >> def rewrite_url_with_facebooker(*args) >> options = args.first.is_a?(Hash) ? args.first : args.last >> is_link_to_canvas = >> link_to_canvas?(@request.request_parameters, options) >> #options[:skip_relative_url_root] ||= !is_link_to_canvas >> options[:skip_relative_url_root] = true >> if is_link_to_canvas && !options.has_key?(:host) >> options[:host] = "apps.facebook.com" >> end >> options.delete(:canvas) >> >> path = rewrite_url_without_facebooker(*args) >> >> facebook_canvas_path = ENV['FACEBOOKER_RELATIVE_URL_ROOT'] || >> ENV['FACEBOOK_CANVAS_PATH'] >> facebook_callback_path = ENV['FACEBOOKER_CALLBACK_PATH'] >> >> print "path: #{path}\n\n" # for debugging only >> >> # replace anything that references the callback with the >> # Facebook canvas equivalent (apps.facebook.com/*) >> if path.starts_with?(facebook_callback_path) >> path.sub!(facebook_callback_path, facebook_canvas_path) >> path = "http://apps.facebook.com#{path}" >> elsif "#{path}/".starts_with?(facebook_callback_path) >> path.sub!(facebook_callback_path.chop, facebook_canvas_path.chop) >> path = "http://apps.facebook.com#{path}" >> elsif (path.starts_with?("http://www.facebook.com") or >> path.starts_with?("https://www.facebook.com")) >> # be sure that URLs that go to some other Facebook service >> redirect back to the canvas >> if path.include?("?") >> path = "#{path}&canvas=true" >> else >> path = "#{path}?canvas=true" >> end >> elsif (!path.starts_with?("http://") and >> !path.starts_with?("https://")) >> # this will fail here because 'request' is not defined; need >> to translate to Facebooker vars >> >> # default to a full URL (will link externally) >> RAILS_DEFAULT_LOGGER.debug "** RFACEBOOK INFO: failed to get >> canvas-friendly URL ("+path+") for ["+options.inspect+"], creating >> an external URL instead" >> path = "#{request.protocol}#{request.host}:#{request.port}#{path}" >> end >> end >> >> Shawn >> >> >> On Sun, 20 Jan 2008 18:30:52 -0700, David Clements wrote: >>> Hey Shawn, >>> >>> The Facebooker way is to set your relative root via >>> ENV["FACEBOOKER_RELATIVE_URL_ROOT"] , this root should have nothing to >>> do with your controller names. For me I make it my app name. >>> >>> The facebooker way to do this is to utilize the rails support for >>> relative root path. This allows for all of your URLs, whether you are >>> a facebook app or not, to have a prefix to the path. Facebooker >>> strips this FACEBOOKER_RELATIVE_ROOT on the way in, and the url >>> rewrite code adds it in for you along with apps.facebook.com. This >>> effects all the urls generated via url_for. >>> >>> After doing this, all of your controllers will generate canvas based >>> urls, whether link_to or url_for. >>> >>> Does that make sense? I am not familiar with rfacebook, so I think I >>> misunderstood your original intent. >>> >>> I will also start documenting some of the code so that some of these >>> answers can be gleaned from a quick read. >>> >>> Dave >>> >>> On Jan 20, 2008 6:15 PM, Shawn Van Ittersum >>> wrote: >>>> How does Facebooker alter the ActionController::Base class? I see >>>> that rfacebook uses an include: >>>> >>>> ActionController::Base.send(:include, >>>> RFacebook::Rails::ControllerExtensions) >>>> ActionController::Base.send(:include, >>>> RFacebook::Rails::Plugin::ControllerExtensions) >>>> >>>> I need to do something similar to write the url_for wrapper, so I >>>> can rewrite the path returned by url_for. But I want to include the >>>> new function in the "right" Facebooker way. >>>> >>>> Shawn >>>> >>>> On Sat, 19 Jan 2008 20:46:29 -0700, David Clements wrote: >>>> >>>>> Hey Shawn, >>>>> >>>>> Are you saying that you basically only want one controller to handle >>>>> all your facebook requests? And that appname == controller? >>>>> >>>>> I looked into this scenario and it looks like maybe the code would >>>>> need to change to handle it. Basically you don't want to have any >>>>> relative_root_url and you set the Callback Url in your facebook >>>>> application settings to the same name as your controller. >>>>> >>>>> Something like http://appserver.com/facebook_handler >>>>> >>>>> Then create a facebook_handler_controller. >>>>> >>>>> And then change the code in facebook_url_rewriting to this >>>>> >>>>> def relative_url_root >>>>> >>>>> "/#{ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']}" >>>>> if (parameters['fb_sig'] && >>>>> (ENV['FACEBOOKER_RELATIVE_URL_ROOT']||ENV['FACEBOOK_CANVAS_PATH']) >>>>> ) >>>>> end >>>>> >>>>> >>>>> This will effectively remove the relative url root. >>>>> >>>>> But maybe I am wrong as to what you are trying to do. >>>>> >>>>> >>>>> Dave >>>>> >>>>> >>>>> >>>>> On Jan 19, 2008 7:23 PM, Shawn Van Ittersum >>>>> wrote: >>>>>> Hey guys, >>>>>> >>>>>> In rfacebook, the callback_path variable allows the developer to >>>>>> strip part of the URL off of auto-generated links (link_to). For >>>>>> example, if an app's canvas pages lead to a certain controller: >>>>>> >>>>>> http://apps.facebook.com/appname/index >>>>>> -> http://appserver.com/controller/index >>>>>> >>>>>> I want the link_to method to prefix the action with >>>>>> 'http://apps.facebook.com/appname/', automatically stripping out the >>>>>> app server and controller. The rfacebook config variables allows >>>>>> this with callback_path set to '/controller/'. >>>>>> >>>>>> Is there an equivalent behavior/config for Facebooker? >>>>>> >>>>>> Thanks, >>>>>> Shawn >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>> >>>> >> From svicalifornia at gmail.com Wed Jan 23 05:18:16 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Wed, 23 Jan 2008 02:18:16 -0800 Subject: [Facebooker-talk] Accessing the current session Message-ID: <20080123021816705889.943ac242@gmail.com> I'm trying to fetch a session (and other fb user variables from the session) at the start of my controller, so that all the actions in that controller can make use of it. Here's the code: class FacebookController < ApplicationController ensure_application_is_installed_by_facebook_user fb_session = session[:facebook_session] # ... action functions here ... end I'm getting this error: TypeError (Symbol as array index): .//app/controllers/facebook_controller.rb:3:in `[]' .//app/controllers/facebook_controller.rb:3 If I put the session[:facebook_session] reference inside any of the actions, it works fine. But that doesn't allow me to factor it out for use by all actions. If I put it inside a helper function or class method, it gives the same error as above. So how do I access the current session outside of an action function, so that I can factor out the session setup code common to all the actions? Thanks, Shawn From digidigo at gmail.com Wed Jan 23 09:28:53 2008 From: digidigo at gmail.com (David Clements) Date: Wed, 23 Jan 2008 07:28:53 -0700 Subject: [Facebooker-talk] Accessing the current session In-Reply-To: <20080123021816705889.943ac242@gmail.com> References: <20080123021816705889.943ac242@gmail.com> Message-ID: Hey Shawn, If I am reading your code right you are tring to access 'session' in the class level context, session is an instance method. What you want here is another method and then you can use it as a before filter. class FacebookController < ApplicationController ensure_application_is_installed_by_facebook_user before_filter :setup_stuff def setup_stuff @fb_user = @facebook_session.user @current_friends = @fb_user.friends! ....... end ..... BTW: After further code reading I noticed that ensure_application_is_installed_by_facebook_user allready sets up the session in an instance variable "@facebook_session", my previous advice didn't go far enough. Dave On Jan 23, 2008 3:18 AM, Shawn Van Ittersum wrote: > I'm trying to fetch a session (and other fb user variables from the session) at the start of my controller, so that all the actions in that controller can make use of it. Here's the code: > > class FacebookController < ApplicationController > ensure_application_is_installed_by_facebook_user > fb_session = session[:facebook_session] > > # ... action functions here ... > end > > I'm getting this error: > > TypeError (Symbol as array index): > .//app/controllers/facebook_controller.rb:3:in `[]' > .//app/controllers/facebook_controller.rb:3 > > If I put the session[:facebook_session] reference inside any of the actions, it works fine. But that doesn't allow me to factor it out for use by all actions. If I put it inside a helper function or class method, it gives the same error as above. So how do I access the current session outside of an action function, so that I can factor out the session setup code common to all the actions? > > Thanks, > Shawn > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From svicalifornia at gmail.com Wed Jan 23 13:50:20 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Wed, 23 Jan 2008 10:50:20 -0800 Subject: [Facebooker-talk] Accessing the current session In-Reply-To: References: <20080123021816705889.943ac242@gmail.com> Message-ID: <20080123105020155514.18794515@gmail.com> Thanks, Dave! Shawn On Wed, 23 Jan 2008 07:28:53 -0700, David Clements wrote: > Hey Shawn, > > If I am reading your code right you are tring to access 'session' in > the class level context, session is an instance method. What you want > here is another method and then you can use it as a before filter. > > > class FacebookController < ApplicationController > ensure_application_is_installed_by_facebook_user > before_filter :setup_stuff > > def setup_stuff > @fb_user = @facebook_session.user > @current_friends = @fb_user.friends! > ....... > end > > ..... > > > BTW: After further code reading I noticed that > ensure_application_is_installed_by_facebook_user allready sets up the > session in an instance variable "@facebook_session", my previous > advice didn't go far enough. > > Dave > > > > > > > On Jan 23, 2008 3:18 AM, Shawn Van Ittersum wrote: >> I'm trying to fetch a session (and other fb user variables from the >> session) at the start of my controller, so that all the actions in >> that controller can make use of it. Here's the code: >> >> class FacebookController < ApplicationController >> ensure_application_is_installed_by_facebook_user >> fb_session = session[:facebook_session] >> >> # ... action functions here ... >> end >> >> I'm getting this error: >> >> TypeError (Symbol as array index): >> .//app/controllers/facebook_controller.rb:3:in `[]' >> .//app/controllers/facebook_controller.rb:3 >> >> If I put the session[:facebook_session] reference inside any of the >> actions, it works fine. But that doesn't allow me to factor it out >> for use by all actions. If I put it inside a helper function or >> class method, it gives the same error as above. So how do I access >> the current session outside of an action function, so that I can >> factor out the session setup code common to all the actions? >> >> Thanks, >> Shawn >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> From svicalifornia at gmail.com Wed Jan 23 13:51:16 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Wed, 23 Jan 2008 10:51:16 -0800 Subject: [Facebooker-talk] bug in external apps Message-ID: <20080123105116179610.5e5aa0ca@gmail.com> I was connecting directly to my server to try to debug something. I disabled the ensure_application_is_installed_by_facebook_user check, then tried to connect to my index action. Got this error: SystemStackError in FacebookController#index stack level too deep RAILS_ROOT: script/../config/.. Application Trace | Framework Trace | Full Trace vendor/rails/activesupport/lib/active_support/core_ext/hash/indifferent_access.rb:18:in `default' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:119:in `[]' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:119:in `request_is_for_a_facebook_canvas?' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:107:in `redirect_to' vendor/rails/actionpack/lib/action_controller/base.rb:987:in `redirect_to' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:110:in `redirect_to' vendor/rails/actionpack/lib/action_controller/base.rb:987:in `redirect_to' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:110:in `redirect_to' vendor/rails/actionpack/lib/action_controller/base.rb:987:in `redirect_to' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:110:in `redirect_to' ### ... above two lines repeated 100's of times ... ### app/controllers/pages_controller.rb:11:in `method_missing' Request Parameters: None Show session dump --- flash: !map:ActionController::Flash::FlashHash {} Response Headers: {"cookie"=>[], "Cache-Control"=>"no-cache"} From svicalifornia at gmail.com Wed Jan 23 13:55:41 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Wed, 23 Jan 2008 10:55:41 -0800 Subject: [Facebooker-talk] redirect_to broken? Message-ID: <20080123105541791604.71772970@gmail.com> Is ActionController's redirect_to method broken by Facebooker? When I try to invoke it and execute through apps.facebook.com, I get a blank page returned, response code 200, no redirect. When I try to connect directly to the server (not through apps.fb), I get the infinite recursion error described minutes ago. Are any of you able to use redirect_to successfully, and if so, any ideas on what's wrong in my app? Shawn From svicalifornia at gmail.com Wed Jan 23 14:06:24 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Wed, 23 Jan 2008 11:06:24 -0800 Subject: [Facebooker-talk] redirect_to broken? In-Reply-To: <20080123105541791604.71772970@gmail.com> References: <20080123105541791604.71772970@gmail.com> Message-ID: <38123e0f0801231106y3f695053g2391a76bf8c968db@mail.gmail.com> Added some debug output to facebooker/rails/controller.rb:108 (in redirect_to), and saw this: *args: {:action=>:index} request_is_for_a_facebook_canvas?: true fbml_redirect_tag(*args): So fbml_redirect_tag is incorrectly generating an empty URL. Shawn On Jan 23, 2008 10:55 AM, Shawn Van Ittersum wrote: > Is ActionController's redirect_to method broken by Facebooker? When I try > to invoke it and execute through apps.facebook.com, I get a blank page > returned, response code 200, no redirect. When I try to connect directly to > the server (not through apps.fb), I get the infinite recursion error > described minutes ago. Are any of you able to use redirect_to successfully, > and if so, any ideas on what's wrong in my app? > > Shawn > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080123/0d491b69/attachment.html From svicalifornia at gmail.com Wed Jan 23 14:08:06 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Wed, 23 Jan 2008 11:08:06 -0800 Subject: [Facebooker-talk] redirect_to broken? In-Reply-To: <38123e0f0801231106y3f695053g2391a76bf8c968db@mail.gmail.com> References: <20080123105541791604.71772970@gmail.com> <38123e0f0801231106y3f695053g2391a76bf8c968db@mail.gmail.com> Message-ID: <38123e0f0801231108m765be652ve1b9f926a6a1132e@mail.gmail.com> This may have something to do with my experimental version of url_for in fb_url_rewriting. :) Please disregard until I find the root cause... Shawn On Jan 23, 2008 11:06 AM, Shawn Van Ittersum wrote: > Added some debug output to facebooker/rails/controller.rb:108 (in > redirect_to), and saw this: > *args: {:action=>:index} > request_is_for_a_facebook_canvas?: true > fbml_redirect_tag(*args): > > So fbml_redirect_tag is incorrectly generating an empty URL. > > Shawn > > On Jan 23, 2008 10:55 AM, Shawn Van Ittersum > wrote: > > > Is ActionController's redirect_to method broken by Facebooker? When I > > try to invoke it and execute through apps.facebook.com, I get a blank > > page returned, response code 200, no redirect. When I try to connect > > directly to the server (not through apps.fb), I get the infinite > > recursion error described minutes ago. Are any of you able to use > > redirect_to successfully, and if so, any ideas on what's wrong in my app? > > > > Shawn > > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080123/0e023ffd/attachment.html From shanev at gmail.com Wed Jan 23 14:41:53 2008 From: shanev at gmail.com (Shane Vitarana) Date: Wed, 23 Jan 2008 13:41:53 -0600 Subject: [Facebooker-talk] redirect_to broken? In-Reply-To: <38123e0f0801231106y3f695053g2391a76bf8c968db@mail.gmail.com> References: <20080123105541791604.71772970@gmail.com> <38123e0f0801231106y3f695053g2391a76bf8c968db@mail.gmail.com> Message-ID: <4ab757a40801231141m3804d9bdpdddb1fc78b5c162c@mail.gmail.com> Your args doesn't include a controller or any of the fb_params. On Jan 23, 2008 1:06 PM, Shawn Van Ittersum wrote: > Added some debug output to facebooker/rails/controller.rb:108 (in > redirect_to), and saw this: > > > *args: {:action=>:index} > request_is_for_a_facebook_canvas?: true > fbml_redirect_tag(*args): > > So fbml_redirect_tag is incorrectly generating an empty URL. > > Shawn > > On Jan 23, 2008 10:55 AM, Shawn Van Ittersum > wrote: > > Is ActionController's redirect_to method broken by Facebooker? When I try > to invoke it and execute through apps.facebook.com, I get a blank page > returned, response code 200, no redirect. When I try to connect directly to > the server (not through apps.fb), I get the infinite recursion error > described minutes ago. Are any of you able to use redirect_to successfully, > and if so, any ideas on what's wrong in my app? > > > > Shawn > > > > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From svicalifornia at gmail.com Wed Jan 23 15:03:11 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Wed, 23 Jan 2008 12:03:11 -0800 Subject: [Facebooker-talk] redirect_to broken? In-Reply-To: <4ab757a40801231141m3804d9bdpdddb1fc78b5c162c@mail.gmail.com> References: <20080123105541791604.71772970@gmail.com> <38123e0f0801231106y3f695053g2391a76bf8c968db@mail.gmail.com> <4ab757a40801231141m3804d9bdpdddb1fc78b5c162c@mail.gmail.com> Message-ID: <20080123120311587384.3642a717@gmail.com> A redirect_to call shouldn't require a controller or fb_params. The controller is implied to be the current controller. I reverted to the current fb_url_rewriting, and I've uncovered that somewhere along the way, a :host option is getting added to my redirect_to options. The :host points to my web server, and then FB is redirecting out of apps.facebook.com directly to my server's hostname, which causes the FB session to be lost. Still tracing where this :host option is being added... Shawn On Wed, 23 Jan 2008 13:41:53 -0600, Shane Vitarana wrote: > Your args doesn't include a controller or any of the fb_params. > > On Jan 23, 2008 1:06 PM, Shawn Van Ittersum wrote: >> Added some debug output to facebooker/rails/controller.rb:108 (in >> redirect_to), and saw this: >> >> >> *args: {:action=>:index} >> request_is_for_a_facebook_canvas?: true >> fbml_redirect_tag(*args): >> >> So fbml_redirect_tag is incorrectly generating an empty URL. >> >> Shawn >> >> On Jan 23, 2008 10:55 AM, Shawn Van Ittersum >> wrote: >>> Is ActionController's redirect_to method broken by Facebooker? When I try >> to invoke it and execute through apps.facebook.com, I get a blank page >> returned, response code 200, no redirect. When I try to connect >> directly to >> the server (not through apps.fb), I get the infinite recursion error >> described minutes ago. Are any of you able to use redirect_to >> successfully, >> and if so, any ideas on what's wrong in my app? >>> >>> Shawn >>> >> >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> > > > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From jnylund at yahoo.com Thu Jan 24 08:39:24 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Thu, 24 Jan 2008 08:39:24 -0500 Subject: [Facebooker-talk] getting started with facebooker Message-ID: Hi, I started with rfacebook but given the recent events figure its best to move over to facebooker. I have: 1.) Installed the facebooker plugin 2.) setup my facebook app (fbml/canvas) 3.) created a method on controller & view to handle initial request 4.) added "ensure_application_is_installed_by_facebook_user" to top off application.rb I am able to get to my landing page and show the facebook id of the users that comes in, but... If I try to show the users friends in the view using: <% for a_friend in @user.friends %> <%=a_friend.first_name%> <% end %> It makes my server hang, for about 70 seconds, then the method seems to complete. Note, I had similar functionality working in rfacebook, so I don't think its an environmental thing. What could I be doing wrong? Also, I have done some reading on issues with running a non facebook application with this setup on same application, what should I do? a.) Create a subclass of my ApplicationController called FaceController to do all the facebook related stuff? b.) Is there a way to do an if around "ensure_application_is_installed_by_facebook_user" so that it is only enforced if coming from facebook? Does anyone have an example app, example code of how to do common things?, I looked through kitchen sink and there is nothing in there? I will blog how to do this TODAY if you guys help me get it going. thanks Joel From mmangino at elevatedrails.com Thu Jan 24 09:23:57 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Thu, 24 Jan 2008 08:23:57 -0600 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: References: Message-ID: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> Facebooker is querying facebook and looking up the name of each friend, one at a time. We populate the the friends array from the ID list that is passed in via Facebook. If you want this output without having to query facebook for each friends, you can use: <%= fb_name a_friend,: firstnameonly=>true %> Mike On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: > Hi, > > I started with rfacebook but given the recent events figure its best > to move over to facebooker. > > I have: > > 1.) Installed the facebooker plugin > 2.) setup my facebook app (fbml/canvas) > 3.) created a method on controller & view to handle initial request > 4.) added "ensure_application_is_installed_by_facebook_user" to top > off application.rb > > I am able to get to my landing page and show the facebook id of the > users that comes in, but... > > If I try to show the users friends in the view using: > <% for a_friend in @user.friends %> > <%=a_friend.first_name%> > <% end %> > > It makes my server hang, for about 70 seconds, then the method seems > to complete. Note, I had similar functionality working in rfacebook, > so I don't think its an environmental thing. > > What could I be doing wrong? > > Also, I have done some reading on issues with running a non facebook > application with this setup on same application, what should I do? > > a.) Create a subclass of my ApplicationController called > FaceController to do all the facebook related stuff? > b.) Is there a way to do an if around > "ensure_application_is_installed_by_facebook_user" so that it is only > enforced if coming from facebook? > > Does anyone have an example app, example code of how to do common > things?, I looked through kitchen sink and there is nothing in there? > I will blog how to do this TODAY if you guys help me get it going. > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From jnylund at yahoo.com Thu Jan 24 11:59:26 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Thu, 24 Jan 2008 11:59:26 -0500 Subject: [Facebooker-talk] form helpers and paths Message-ID: <1DAEAB6B-E5A3-4091-85C3-DC602A5D76CB@yahoo.com> In the form helpers code, the comments have examples like "create_poke_path". can you tell me what this path is, and where I can read about it? I assume its a way to say what controller/method should be called when the form action is taken, but what is the format? thanks Joel From bjclark at scidept.com Thu Jan 24 14:10:35 2008 From: bjclark at scidept.com (BJ Clark) Date: Thu, 24 Jan 2008 12:10:35 -0700 Subject: [Facebooker-talk] New Batch API method Message-ID: <007F6049-82DA-46E9-A5F8-18CFD454CEEB@scidept.com> Anyone started implementing the new Batch api method? BJ ----- BJ Clark the science department bjclark at scidept.com www.scidept.com From svicalifornia at gmail.com Thu Jan 24 14:41:48 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 24 Jan 2008 11:41:48 -0800 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> Message-ID: <20080124114148693554.47a822b9@gmail.com> Can Facebooker be modified to call FB's getInfo on a list of friend ID's instead of one at a time? Shawn On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: > Facebooker is querying facebook and looking up the name of each > friend, one at a time. We populate the the friends array from the ID > list that is passed in via Facebook. > > If you want this output without having to query facebook for each > friends, you can use: > > <%= fb_name a_friend,: firstnameonly=>true %> > > Mike > > On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: > >> Hi, >> >> I started with rfacebook but given the recent events figure its best >> to move over to facebooker. >> >> I have: >> >> 1.) Installed the facebooker plugin >> 2.) setup my facebook app (fbml/canvas) >> 3.) created a method on controller & view to handle initial request >> 4.) added "ensure_application_is_installed_by_facebook_user" to top >> off application.rb >> >> I am able to get to my landing page and show the facebook id of the >> users that comes in, but... >> >> If I try to show the users friends in the view using: >> <% for a_friend in @user.friends %> >> <%=a_friend.first_name%> >> <% end %> >> >> It makes my server hang, for about 70 seconds, then the method seems >> to complete. Note, I had similar functionality working in rfacebook, >> so I don't think its an environmental thing. >> >> What could I be doing wrong? >> >> Also, I have done some reading on issues with running a non facebook >> application with this setup on same application, what should I do? >> >> a.) Create a subclass of my ApplicationController called >> FaceController to do all the facebook related stuff? >> b.) Is there a way to do an if around >> "ensure_application_is_installed_by_facebook_user" so that it is only >> enforced if coming from facebook? >> >> Does anyone have an example app, example code of how to do common >> things?, I looked through kitchen sink and there is nothing in there? >> I will blog how to do this TODAY if you guys help me get it going. >> >> thanks >> Joel >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From digidigo at gmail.com Thu Jan 24 14:46:19 2008 From: digidigo at gmail.com (David Clements) Date: Thu, 24 Jan 2008 12:46:19 -0700 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <20080124114148693554.47a822b9@gmail.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124114148693554.47a822b9@gmail.com> Message-ID: Isn't that what user.friends! already does? I think I did this once when I first started out. ### # Retrieve friends with user info populated # Subsequent calls will be retrieved from memory. # Optional: list of fields to retrieve as symbols def friends!(*fields) @friends ||= session.post('facebook.users.getInfo', :fields => collect(fields), :uids => friends.map{|f| f.id}.join(',')).map do |hash| User.new(hash['uid'], session, hash) end end Dave On Jan 24, 2008 12:41 PM, Shawn Van Ittersum wrote: > Can Facebooker be modified to call FB's getInfo on a list of friend ID's instead of one at a time? > > Shawn > > > On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: > > Facebooker is querying facebook and looking up the name of each > > friend, one at a time. We populate the the friends array from the ID > > list that is passed in via Facebook. > > > > If you want this output without having to query facebook for each > > friends, you can use: > > > > <%= fb_name a_friend,: firstnameonly=>true %> > > > > Mike > > > > On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: > > > >> Hi, > >> > >> I started with rfacebook but given the recent events figure its best > >> to move over to facebooker. > >> > >> I have: > >> > >> 1.) Installed the facebooker plugin > >> 2.) setup my facebook app (fbml/canvas) > >> 3.) created a method on controller & view to handle initial request > >> 4.) added "ensure_application_is_installed_by_facebook_user" to top > >> off application.rb > >> > >> I am able to get to my landing page and show the facebook id of the > >> users that comes in, but... > >> > >> If I try to show the users friends in the view using: > >> <% for a_friend in @user.friends %> > >> <%=a_friend.first_name%> > >> <% end %> > >> > >> It makes my server hang, for about 70 seconds, then the method seems > >> to complete. Note, I had similar functionality working in rfacebook, > >> so I don't think its an environmental thing. > >> > >> What could I be doing wrong? > >> > >> Also, I have done some reading on issues with running a non facebook > >> application with this setup on same application, what should I do? > >> > >> a.) Create a subclass of my ApplicationController called > >> FaceController to do all the facebook related stuff? > >> b.) Is there a way to do an if around > >> "ensure_application_is_installed_by_facebook_user" so that it is only > >> enforced if coming from facebook? > >> > >> Does anyone have an example app, example code of how to do common > >> things?, I looked through kitchen sink and there is nothing in there? > >> I will blog how to do this TODAY if you guys help me get it going. > >> > >> thanks > >> Joel > >> > >> _______________________________________________ > >> Facebooker-talk mailing list > >> Facebooker-talk at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > > > -- > > Mike Mangino > > http://www.elevatedrails.com > > > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From svicalifornia at gmail.com Thu Jan 24 14:53:12 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 24 Jan 2008 11:53:12 -0800 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> Message-ID: <20080124115312174181.b3c2405e@gmail.com> I see what you mean. And although I'm from rfacebook-land (like Joel), I just want to say that I do agree with the Ruby-inspired abstraction added to Facebooker. It would be great, tho, to be able to take advantage of FB's ability to return user info for a list of users in one REST call. Performance is very important in FB apps, and this is a very common use case for IFRAME apps and even many FBML apps. Shawn On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: > Facebooker is querying facebook and looking up the name of each > friend, one at a time. We populate the the friends array from the ID > list that is passed in via Facebook. > > If you want this output without having to query facebook for each > friends, you can use: > > <%= fb_name a_friend,: firstnameonly=>true %> > > Mike > > On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: > >> Hi, >> >> I started with rfacebook but given the recent events figure its best >> to move over to facebooker. >> >> I have: >> >> 1.) Installed the facebooker plugin >> 2.) setup my facebook app (fbml/canvas) >> 3.) created a method on controller & view to handle initial request >> 4.) added "ensure_application_is_installed_by_facebook_user" to top >> off application.rb >> >> I am able to get to my landing page and show the facebook id of the >> users that comes in, but... >> >> If I try to show the users friends in the view using: >> <% for a_friend in @user.friends %> >> <%=a_friend.first_name%> >> <% end %> >> >> It makes my server hang, for about 70 seconds, then the method seems >> to complete. Note, I had similar functionality working in rfacebook, >> so I don't think its an environmental thing. >> >> What could I be doing wrong? >> >> Also, I have done some reading on issues with running a non facebook >> application with this setup on same application, what should I do? >> >> a.) Create a subclass of my ApplicationController called >> FaceController to do all the facebook related stuff? >> b.) Is there a way to do an if around >> "ensure_application_is_installed_by_facebook_user" so that it is only >> enforced if coming from facebook? >> >> Does anyone have an example app, example code of how to do common >> things?, I looked through kitchen sink and there is nothing in there? >> I will blog how to do this TODAY if you guys help me get it going. >> >> thanks >> Joel >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From jnylund at yahoo.com Thu Jan 24 15:04:16 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Thu, 24 Jan 2008 15:04:16 -0500 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <20080124115312174181.b3c2405e@gmail.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124115312174181.b3c2405e@gmail.com> Message-ID: <4D038A12-BEED-4552-98BB-2AB888139990@yahoo.com> So I can try to learn what is going on beneath the covers I have modified the service post method to log (it would be cool if there was an env variable to turn this on or off in facebooker) the actual post and response: Here is my version for anyone else that wants to understand the facebook api calls that are happening under the covers. def post(params) logger.debug "About to post to :" + url.to_s logger.debug "with params:" params.each { |elem| logger.debug elem[0].to_s + " : " + elem[1].to_s} resp,data = Net::HTTP.post_form(url, params) logger.debug "Result: " + resp.to_s logger.debug "Response Data: " + data.to_s Parser.parse(params[:method],resp) end I also didn't realize that by using the helpers that fbml can add the First & Last name of the user for you on the return of the round trip (if your using fbml & canvas) so I changed it to: Friends:
<% for a_friend in @userF.friends %> <%= fb_name a_friend %>
<% end %> And it displays a list of friends that link to their profiles. thanks Joel On Jan 24, 2008, at 2:53 PM, Shawn Van Ittersum wrote: > I see what you mean. And although I'm from rfacebook-land (like > Joel), I just want to say that I do agree with the Ruby-inspired > abstraction added to Facebooker. It would be great, tho, to be able > to take advantage of FB's ability to return user info for a list of > users in one REST call. Performance is very important in FB apps, > and this is a very common use case for IFRAME apps and even many > FBML apps. > > Shawn > > On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: >> Facebooker is querying facebook and looking up the name of each >> friend, one at a time. We populate the the friends array from the ID >> list that is passed in via Facebook. >> >> If you want this output without having to query facebook for each >> friends, you can use: >> >> <%= fb_name a_friend,: firstnameonly=>true %> >> >> Mike >> >> On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: >> >>> Hi, >>> >>> I started with rfacebook but given the recent events figure its best >>> to move over to facebooker. >>> >>> I have: >>> >>> 1.) Installed the facebooker plugin >>> 2.) setup my facebook app (fbml/canvas) >>> 3.) created a method on controller & view to handle initial request >>> 4.) added "ensure_application_is_installed_by_facebook_user" to top >>> off application.rb >>> >>> I am able to get to my landing page and show the facebook id of the >>> users that comes in, but... >>> >>> If I try to show the users friends in the view using: >>> <% for a_friend in @user.friends %> >>> <%=a_friend.first_name%> >>> <% end %> >>> >>> It makes my server hang, for about 70 seconds, then the method seems >>> to complete. Note, I had similar functionality working in rfacebook, >>> so I don't think its an environmental thing. >>> >>> What could I be doing wrong? >>> >>> Also, I have done some reading on issues with running a non facebook >>> application with this setup on same application, what should I do? >>> >>> a.) Create a subclass of my ApplicationController called >>> FaceController to do all the facebook related stuff? >>> b.) Is there a way to do an if around >>> "ensure_application_is_installed_by_facebook_user" so that it is >>> only >>> enforced if coming from facebook? >>> >>> Does anyone have an example app, example code of how to do common >>> things?, I looked through kitchen sink and there is nothing in >>> there? >>> I will blog how to do this TODAY if you guys help me get it going. >>> >>> thanks >>> Joel >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> -- >> Mike Mangino >> http://www.elevatedrails.com >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk From svicalifornia at gmail.com Thu Jan 24 15:12:29 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 24 Jan 2008 12:12:29 -0800 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124114148693554.47a822b9@gmail.com> Message-ID: <20080124121229564844.041bb9be@gmail.com> Well, ideally, we'd also get to specify which fields get fetched from FB. Some (networks, schools, etc) require JOINs on FB's database and take longer to complete. I have timed simple requests (name, birthdate, etc) against full requests and noticed dramatic differences in speed. Shawn On Thu, 24 Jan 2008 12:46:19 -0700, David Clements wrote: > Isn't that what user.friends! already does? I think I did this once > when I first started out. > > ### > # Retrieve friends with user info populated > # Subsequent calls will be retrieved from memory. > # Optional: list of fields to retrieve as symbols > def friends!(*fields) > @friends ||= session.post('facebook.users.getInfo', :fields => > collect(fields), :uids => friends.map{|f| f.id}.join(',')).map do > |hash| > User.new(hash['uid'], session, hash) > end > end > > Dave > > > > On Jan 24, 2008 12:41 PM, Shawn Van Ittersum > wrote: >> Can Facebooker be modified to call FB's getInfo on a list of friend >> ID's instead of one at a time? >> >> Shawn >> >> >> On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: >>> Facebooker is querying facebook and looking up the name of each >>> friend, one at a time. We populate the the friends array from the ID >>> list that is passed in via Facebook. >>> >>> If you want this output without having to query facebook for each >>> friends, you can use: >>> >>> <%= fb_name a_friend,: firstnameonly=>true %> >>> >>> Mike >>> >>> On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: >>> >>>> Hi, >>>> >>>> I started with rfacebook but given the recent events figure its best >>>> to move over to facebooker. >>>> >>>> I have: >>>> >>>> 1.) Installed the facebooker plugin >>>> 2.) setup my facebook app (fbml/canvas) >>>> 3.) created a method on controller & view to handle initial request >>>> 4.) added "ensure_application_is_installed_by_facebook_user" to top >>>> off application.rb >>>> >>>> I am able to get to my landing page and show the facebook id of the >>>> users that comes in, but... >>>> >>>> If I try to show the users friends in the view using: >>>> <% for a_friend in @user.friends %> >>>> <%=a_friend.first_name%> >>>> <% end %> >>>> >>>> It makes my server hang, for about 70 seconds, then the method seems >>>> to complete. Note, I had similar functionality working in rfacebook, >>>> so I don't think its an environmental thing. >>>> >>>> What could I be doing wrong? >>>> >>>> Also, I have done some reading on issues with running a non facebook >>>> application with this setup on same application, what should I do? >>>> >>>> a.) Create a subclass of my ApplicationController called >>>> FaceController to do all the facebook related stuff? >>>> b.) Is there a way to do an if around >>>> "ensure_application_is_installed_by_facebook_user" so that it is only >>>> enforced if coming from facebook? >>>> >>>> Does anyone have an example app, example code of how to do common >>>> things?, I looked through kitchen sink and there is nothing in there? >>>> I will blog how to do this TODAY if you guys help me get it going. >>>> >>>> thanks >>>> Joel >>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >>> -- >>> Mike Mangino >>> http://www.elevatedrails.com >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> From chad at chadfowler.com Thu Jan 24 15:21:49 2008 From: chad at chadfowler.com (Chad Fowler) Date: Thu, 24 Jan 2008 14:21:49 -0600 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <20080124121229564844.041bb9be@gmail.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124114148693554.47a822b9@gmail.com> <20080124121229564844.041bb9be@gmail.com> Message-ID: On 1/24/08, Shawn Van Ittersum wrote: > Well, ideally, we'd also get to specify which fields get fetched from FB. Some (networks, schools, etc) require JOINs on FB's database and take longer to complete. I have timed simple requests (name, birthdate, etc) against full requests and noticed dramatic differences in speed. > > Shawn Yea. When I wrote this feature, I put that on my mental TODO list for when I needed it. Never needed it, so it never got added (by me). I'm of course not at all the main contributor to Facebooker anymore (until I need to do some more Facebook work), but I'm sure this addition would be warmly welcome if accompanied by tests. Thanks! Chad From digidigo at gmail.com Thu Jan 24 15:32:04 2008 From: digidigo at gmail.com (David Clements) Date: Thu, 24 Jan 2008 13:32:04 -0700 Subject: [Facebooker-talk] Is there a test for setting the session ID to the fb_sig_session_key param? Message-ID: Hey all, I have a patch that fixes a problem I am having with IFramed pages in rails 2.0. I am relying on the session being retrieved via fb_sig_session_key. I am looking for the test code that tests this functionality but I can't seem to find it. So you on the list today Chad, gotta pointer for me? Thanks, I want to get a test in for this fix, Dave From svicalifornia at gmail.com Thu Jan 24 15:43:03 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 24 Jan 2008 12:43:03 -0800 Subject: [Facebooker-talk] Is there a test for setting the session ID to the fb_sig_session_key param? In-Reply-To: References: Message-ID: <20080124124303989529.f7eb1c4b@gmail.com> Hi Dave and others, When making any changes to the way sessions are retrieved and validated, please test them with forms in an FBML app. In parsing FBML, Facebook adds fb_ params in hidden inputs to POST forms. These params messed up the rfacebook session validation, which is why I'm here on Facebooker, since it doesn't have that problem. :) Let's be sure to keep it working. :) Thanks, Shawn On Thu, 24 Jan 2008 13:32:04 -0700, David Clements wrote: > Hey all, > > I have a patch that fixes a problem I am having with IFramed pages in > rails 2.0. I am relying on the session being retrieved via > fb_sig_session_key. I am looking for the test code that tests this > functionality but I can't seem to find it. > > So you on the list today Chad, gotta pointer for me? > > > Thanks, I want to get a test in for this fix, > > Dave > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From shanev at gmail.com Thu Jan 24 16:03:39 2008 From: shanev at gmail.com (Shane Vitarana) Date: Thu, 24 Jan 2008 15:03:39 -0600 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <20080124121229564844.041bb9be@gmail.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124114148693554.47a822b9@gmail.com> <20080124121229564844.041bb9be@gmail.com> Message-ID: <4ab757a40801241303p4f5f2660le64bf7c1cf345407@mail.gmail.com> Shawn- You can specify what fields you want as symbols. i.e: facebook_session.user.populate(:first_name). This will only fetch the first name record. Shane On Jan 24, 2008 2:12 PM, Shawn Van Ittersum wrote: > Well, ideally, we'd also get to specify which fields get fetched from FB. Some (networks, schools, etc) require JOINs on FB's database and take longer to complete. I have timed simple requests (name, birthdate, etc) against full requests and noticed dramatic differences in speed. > > Shawn > > > On Thu, 24 Jan 2008 12:46:19 -0700, David Clements wrote: > > Isn't that what user.friends! already does? I think I did this once > > when I first started out. > > > > ### > > # Retrieve friends with user info populated > > # Subsequent calls will be retrieved from memory. > > # Optional: list of fields to retrieve as symbols > > def friends!(*fields) > > @friends ||= session.post('facebook.users.getInfo', :fields => > > collect(fields), :uids => friends.map{|f| f.id}.join(',')).map do > > |hash| > > User.new(hash['uid'], session, hash) > > end > > end > > > > Dave > > > > > > > > On Jan 24, 2008 12:41 PM, Shawn Van Ittersum > > wrote: > >> Can Facebooker be modified to call FB's getInfo on a list of friend > >> ID's instead of one at a time? > >> > >> Shawn > >> > >> > >> On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: > >>> Facebooker is querying facebook and looking up the name of each > >>> friend, one at a time. We populate the the friends array from the ID > >>> list that is passed in via Facebook. > >>> > >>> If you want this output without having to query facebook for each > >>> friends, you can use: > >>> > >>> <%= fb_name a_friend,: firstnameonly=>true %> > >>> > >>> Mike > >>> > >>> On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: > >>> > >>>> Hi, > >>>> > >>>> I started with rfacebook but given the recent events figure its best > >>>> to move over to facebooker. > >>>> > >>>> I have: > >>>> > >>>> 1.) Installed the facebooker plugin > >>>> 2.) setup my facebook app (fbml/canvas) > >>>> 3.) created a method on controller & view to handle initial request > >>>> 4.) added "ensure_application_is_installed_by_facebook_user" to top > >>>> off application.rb > >>>> > >>>> I am able to get to my landing page and show the facebook id of the > >>>> users that comes in, but... > >>>> > >>>> If I try to show the users friends in the view using: > >>>> <% for a_friend in @user.friends %> > >>>> <%=a_friend.first_name%> > >>>> <% end %> > >>>> > >>>> It makes my server hang, for about 70 seconds, then the method seems > >>>> to complete. Note, I had similar functionality working in rfacebook, > >>>> so I don't think its an environmental thing. > >>>> > >>>> What could I be doing wrong? > >>>> > >>>> Also, I have done some reading on issues with running a non facebook > >>>> application with this setup on same application, what should I do? > >>>> > >>>> a.) Create a subclass of my ApplicationController called > >>>> FaceController to do all the facebook related stuff? > >>>> b.) Is there a way to do an if around > >>>> "ensure_application_is_installed_by_facebook_user" so that it is only > >>>> enforced if coming from facebook? > >>>> > >>>> Does anyone have an example app, example code of how to do common > >>>> things?, I looked through kitchen sink and there is nothing in there? > >>>> I will blog how to do this TODAY if you guys help me get it going. > >>>> > >>>> thanks > >>>> Joel > >>>> > >>>> _______________________________________________ > >>>> Facebooker-talk mailing list > >>>> Facebooker-talk at rubyforge.org > >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>> > >>> -- > >>> Mike Mangino > >>> http://www.elevatedrails.com > >>> > >>> _______________________________________________ > >>> Facebooker-talk mailing list > >>> Facebooker-talk at rubyforge.org > >>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >> _______________________________________________ > >> Facebooker-talk mailing list > >> Facebooker-talk at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/facebooker-talk > >> > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From svicalifornia at gmail.com Thu Jan 24 16:08:57 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 24 Jan 2008 13:08:57 -0800 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <4ab757a40801241303p4f5f2660le64bf7c1cf345407@mail.gmail.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124114148693554.47a822b9@gmail.com> <20080124121229564844.041bb9be@gmail.com> <4ab757a40801241303p4f5f2660le64bf7c1cf345407@mail.gmail.com> Message-ID: <20080124130857840389.37a3b50a@gmail.com> OK, but does this allow fetching multiple specified fields on multiple specified users all in one FB API call? Shawn On Thu, 24 Jan 2008 15:03:39 -0600, Shane Vitarana wrote: > Shawn- > > You can specify what fields you want as symbols. i.e: > facebook_session.user.populate(:first_name). This will only fetch the > first name record. > > Shane > > > On Jan 24, 2008 2:12 PM, Shawn Van Ittersum wrote: >> Well, ideally, we'd also get to specify which fields get fetched >> from FB. Some (networks, schools, etc) require JOINs on FB's >> database and take longer to complete. I have timed simple requests >> (name, birthdate, etc) against full requests and noticed dramatic >> differences in speed. >> >> Shawn >> >> >> On Thu, 24 Jan 2008 12:46:19 -0700, David Clements wrote: >>> Isn't that what user.friends! already does? I think I did this once >>> when I first started out. >>> >>> ### >>> # Retrieve friends with user info populated >>> # Subsequent calls will be retrieved from memory. >>> # Optional: list of fields to retrieve as symbols >>> def friends!(*fields) >>> @friends ||= session.post('facebook.users.getInfo', :fields => >>> collect(fields), :uids => friends.map{|f| f.id}.join(',')).map do >>> |hash| >>> User.new(hash['uid'], session, hash) >>> end >>> end >>> >>> Dave >>> >>> >>> >>> On Jan 24, 2008 12:41 PM, Shawn Van Ittersum >>> wrote: >>>> Can Facebooker be modified to call FB's getInfo on a list of friend >>>> ID's instead of one at a time? >>>> >>>> Shawn >>>> >>>> >>>> On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: >>>>> Facebooker is querying facebook and looking up the name of each >>>>> friend, one at a time. We populate the the friends array from the ID >>>>> list that is passed in via Facebook. >>>>> >>>>> If you want this output without having to query facebook for each >>>>> friends, you can use: >>>>> >>>>> <%= fb_name a_friend,: firstnameonly=>true %> >>>>> >>>>> Mike >>>>> >>>>> On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: >>>>> >>>>>> Hi, >>>>>> >>>>>> I started with rfacebook but given the recent events figure its best >>>>>> to move over to facebooker. >>>>>> >>>>>> I have: >>>>>> >>>>>> 1.) Installed the facebooker plugin >>>>>> 2.) setup my facebook app (fbml/canvas) >>>>>> 3.) created a method on controller & view to handle initial request >>>>>> 4.) added "ensure_application_is_installed_by_facebook_user" to top >>>>>> off application.rb >>>>>> >>>>>> I am able to get to my landing page and show the facebook id of the >>>>>> users that comes in, but... >>>>>> >>>>>> If I try to show the users friends in the view using: >>>>>> <% for a_friend in @user.friends %> >>>>>> <%=a_friend.first_name%> >>>>>> <% end %> >>>>>> >>>>>> It makes my server hang, for about 70 seconds, then the method seems >>>>>> to complete. Note, I had similar functionality working in rfacebook, >>>>>> so I don't think its an environmental thing. >>>>>> >>>>>> What could I be doing wrong? >>>>>> >>>>>> Also, I have done some reading on issues with running a non facebook >>>>>> application with this setup on same application, what should I do? >>>>>> >>>>>> a.) Create a subclass of my ApplicationController called >>>>>> FaceController to do all the facebook related stuff? >>>>>> b.) Is there a way to do an if around >>>>>> "ensure_application_is_installed_by_facebook_user" so that it is only >>>>>> enforced if coming from facebook? >>>>>> >>>>>> Does anyone have an example app, example code of how to do common >>>>>> things?, I looked through kitchen sink and there is nothing in there? >>>>>> I will blog how to do this TODAY if you guys help me get it going. >>>>>> >>>>>> thanks >>>>>> Joel >>>>>> >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>> >>>>> -- >>>>> Mike Mangino >>>>> http://www.elevatedrails.com >>>>> >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> > > > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From shanev at gmail.com Thu Jan 24 16:20:37 2008 From: shanev at gmail.com (Shane Vitarana) Date: Thu, 24 Jan 2008 15:20:37 -0600 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <20080124130857840389.37a3b50a@gmail.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124114148693554.47a822b9@gmail.com> <20080124121229564844.041bb9be@gmail.com> <4ab757a40801241303p4f5f2660le64bf7c1cf345407@mail.gmail.com> <20080124130857840389.37a3b50a@gmail.com> Message-ID: <4ab757a40801241320y3f8e763p4ead25615cd3bdff@mail.gmail.com> You can only get multiple specified files for *one* user. You can always construct an FQL query to get multiple fields for multiple users. On Jan 24, 2008 3:08 PM, Shawn Van Ittersum wrote: > OK, but does this allow fetching multiple specified fields on multiple specified users all in one FB API call? > > Shawn > > > On Thu, 24 Jan 2008 15:03:39 -0600, Shane Vitarana wrote: > > Shawn- > > > > You can specify what fields you want as symbols. i.e: > > facebook_session.user.populate(:first_name). This will only fetch the > > first name record. > > > > Shane > > > > > > On Jan 24, 2008 2:12 PM, Shawn Van Ittersum wrote: > >> Well, ideally, we'd also get to specify which fields get fetched > >> from FB. Some (networks, schools, etc) require JOINs on FB's > >> database and take longer to complete. I have timed simple requests > >> (name, birthdate, etc) against full requests and noticed dramatic > >> differences in speed. > >> > >> Shawn > >> > >> > >> On Thu, 24 Jan 2008 12:46:19 -0700, David Clements wrote: > >>> Isn't that what user.friends! already does? I think I did this once > >>> when I first started out. > >>> > >>> ### > >>> # Retrieve friends with user info populated > >>> # Subsequent calls will be retrieved from memory. > >>> # Optional: list of fields to retrieve as symbols > >>> def friends!(*fields) > >>> @friends ||= session.post('facebook.users.getInfo', :fields => > >>> collect(fields), :uids => friends.map{|f| f.id}.join(',')).map do > >>> |hash| > >>> User.new(hash['uid'], session, hash) > >>> end > >>> end > >>> > >>> Dave > >>> > >>> > >>> > >>> On Jan 24, 2008 12:41 PM, Shawn Van Ittersum > >>> wrote: > >>>> Can Facebooker be modified to call FB's getInfo on a list of friend > >>>> ID's instead of one at a time? > >>>> > >>>> Shawn > >>>> > >>>> > >>>> On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: > >>>>> Facebooker is querying facebook and looking up the name of each > >>>>> friend, one at a time. We populate the the friends array from the ID > >>>>> list that is passed in via Facebook. > >>>>> > >>>>> If you want this output without having to query facebook for each > >>>>> friends, you can use: > >>>>> > >>>>> <%= fb_name a_friend,: firstnameonly=>true %> > >>>>> > >>>>> Mike > >>>>> > >>>>> On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: > >>>>> > >>>>>> Hi, > >>>>>> > >>>>>> I started with rfacebook but given the recent events figure its best > >>>>>> to move over to facebooker. > >>>>>> > >>>>>> I have: > >>>>>> > >>>>>> 1.) Installed the facebooker plugin > >>>>>> 2.) setup my facebook app (fbml/canvas) > >>>>>> 3.) created a method on controller & view to handle initial request > >>>>>> 4.) added "ensure_application_is_installed_by_facebook_user" to top > >>>>>> off application.rb > >>>>>> > >>>>>> I am able to get to my landing page and show the facebook id of the > >>>>>> users that comes in, but... > >>>>>> > >>>>>> If I try to show the users friends in the view using: > >>>>>> <% for a_friend in @user.friends %> > >>>>>> <%=a_friend.first_name%> > >>>>>> <% end %> > >>>>>> > >>>>>> It makes my server hang, for about 70 seconds, then the method seems > >>>>>> to complete. Note, I had similar functionality working in rfacebook, > >>>>>> so I don't think its an environmental thing. > >>>>>> > >>>>>> What could I be doing wrong? > >>>>>> > >>>>>> Also, I have done some reading on issues with running a non facebook > >>>>>> application with this setup on same application, what should I do? > >>>>>> > >>>>>> a.) Create a subclass of my ApplicationController called > >>>>>> FaceController to do all the facebook related stuff? > >>>>>> b.) Is there a way to do an if around > >>>>>> "ensure_application_is_installed_by_facebook_user" so that it is only > >>>>>> enforced if coming from facebook? > >>>>>> > >>>>>> Does anyone have an example app, example code of how to do common > >>>>>> things?, I looked through kitchen sink and there is nothing in there? > >>>>>> I will blog how to do this TODAY if you guys help me get it going. > >>>>>> > >>>>>> thanks > >>>>>> Joel > >>>>>> > >>>>>> _______________________________________________ > >>>>>> Facebooker-talk mailing list > >>>>>> Facebooker-talk at rubyforge.org > >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>> > >>>>> -- > >>>>> Mike Mangino > >>>>> http://www.elevatedrails.com > >>>>> > >>>>> _______________________________________________ > >>>>> Facebooker-talk mailing list > >>>>> Facebooker-talk at rubyforge.org > >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>> _______________________________________________ > >>>> Facebooker-talk mailing list > >>>> Facebooker-talk at rubyforge.org > >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>> > >> _______________________________________________ > >> Facebooker-talk mailing list > >> Facebooker-talk at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/facebooker-talk > >> > > > > > > > > -- > > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From svicalifornia at gmail.com Thu Jan 24 16:30:13 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 24 Jan 2008 13:30:13 -0800 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <4ab757a40801241320y3f8e763p4ead25615cd3bdff@mail.gmail.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124114148693554.47a822b9@gmail.com> <20080124121229564844.041bb9be@gmail.com> <4ab757a40801241303p4f5f2660le64bf7c1cf345407@mail.gmail.com> <20080124130857840389.37a3b50a@gmail.com> <4ab757a40801241320y3f8e763p4ead25615cd3bdff@mail.gmail.com> Message-ID: <20080124133013441900.4f32edf5@gmail.com> OK, then my request to get multiple fields for multiple users still holds. The FB API allows this, so we should have a method to do it, as Chad has also said. I'll be looking into this further after working on the callback_path stuff. Shawn On Thu, 24 Jan 2008 15:20:37 -0600, Shane Vitarana wrote: > You can only get multiple specified files for *one* user. You can > always construct an FQL query to get multiple fields for multiple > users. > > On Jan 24, 2008 3:08 PM, Shawn Van Ittersum wrote: >> OK, but does this allow fetching multiple specified fields on >> multiple specified users all in one FB API call? >> >> Shawn >> >> >> On Thu, 24 Jan 2008 15:03:39 -0600, Shane Vitarana wrote: >>> Shawn- >>> >>> You can specify what fields you want as symbols. i.e: >>> facebook_session.user.populate(:first_name). This will only fetch the >>> first name record. >>> >>> Shane >>> >>> >>> On Jan 24, 2008 2:12 PM, Shawn Van Ittersum >>> wrote: >>>> Well, ideally, we'd also get to specify which fields get fetched >>>> from FB. Some (networks, schools, etc) require JOINs on FB's >>>> database and take longer to complete. I have timed simple requests >>>> (name, birthdate, etc) against full requests and noticed dramatic >>>> differences in speed. >>>> >>>> Shawn >>>> >>>> >>>> On Thu, 24 Jan 2008 12:46:19 -0700, David Clements wrote: >>>>> Isn't that what user.friends! already does? I think I did this once >>>>> when I first started out. >>>>> >>>>> ### >>>>> # Retrieve friends with user info populated >>>>> # Subsequent calls will be retrieved from memory. >>>>> # Optional: list of fields to retrieve as symbols >>>>> def friends!(*fields) >>>>> @friends ||= session.post('facebook.users.getInfo', :fields => >>>>> collect(fields), :uids => friends.map{|f| f.id}.join(',')).map do >>>>> |hash| >>>>> User.new(hash['uid'], session, hash) >>>>> end >>>>> end >>>>> >>>>> Dave >>>>> >>>>> >>>>> >>>>> On Jan 24, 2008 12:41 PM, Shawn Van Ittersum >>>>> wrote: >>>>>> Can Facebooker be modified to call FB's getInfo on a list of friend >>>>>> ID's instead of one at a time? >>>>>> >>>>>> Shawn >>>>>> >>>>>> >>>>>> On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: >>>>>>> Facebooker is querying facebook and looking up the name of each >>>>>>> friend, one at a time. We populate the the friends array from the ID >>>>>>> list that is passed in via Facebook. >>>>>>> >>>>>>> If you want this output without having to query facebook for each >>>>>>> friends, you can use: >>>>>>> >>>>>>> <%= fb_name a_friend,: firstnameonly=>true %> >>>>>>> >>>>>>> Mike >>>>>>> >>>>>>> On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: >>>>>>> >>>>>>>> Hi, >>>>>>>> >>>>>>>> I started with rfacebook but given the recent events figure its best >>>>>>>> to move over to facebooker. >>>>>>>> >>>>>>>> I have: >>>>>>>> >>>>>>>> 1.) Installed the facebooker plugin >>>>>>>> 2.) setup my facebook app (fbml/canvas) >>>>>>>> 3.) created a method on controller & view to handle initial request >>>>>>>> 4.) added "ensure_application_is_installed_by_facebook_user" to top >>>>>>>> off application.rb >>>>>>>> >>>>>>>> I am able to get to my landing page and show the facebook id of the >>>>>>>> users that comes in, but... >>>>>>>> >>>>>>>> If I try to show the users friends in the view using: >>>>>>>> <% for a_friend in @user.friends %> >>>>>>>> <%=a_friend.first_name%> >>>>>>>> <% end %> >>>>>>>> >>>>>>>> It makes my server hang, for about 70 seconds, then the method seems >>>>>>>> to complete. Note, I had similar functionality working in rfacebook, >>>>>>>> so I don't think its an environmental thing. >>>>>>>> >>>>>>>> What could I be doing wrong? >>>>>>>> >>>>>>>> Also, I have done some reading on issues with running a non facebook >>>>>>>> application with this setup on same application, what should I do? >>>>>>>> >>>>>>>> a.) Create a subclass of my ApplicationController called >>>>>>>> FaceController to do all the facebook related stuff? >>>>>>>> b.) Is there a way to do an if around >>>>>>>> "ensure_application_is_installed_by_facebook_user" so that it is only >>>>>>>> enforced if coming from facebook? >>>>>>>> >>>>>>>> Does anyone have an example app, example code of how to do common >>>>>>>> things?, I looked through kitchen sink and there is nothing in there? >>>>>>>> I will blog how to do this TODAY if you guys help me get it going. >>>>>>>> >>>>>>>> thanks >>>>>>>> Joel >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> Facebooker-talk mailing list >>>>>>>> Facebooker-talk at rubyforge.org >>>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>> >>>>>>> -- >>>>>>> Mike Mangino >>>>>>> http://www.elevatedrails.com >>>>>>> >>>>>>> _______________________________________________ >>>>>>> Facebooker-talk mailing list >>>>>>> Facebooker-talk at rubyforge.org >>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>> >>> >>> >>> -- >>> http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com >> > > > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From shanev at gmail.com Thu Jan 24 18:47:52 2008 From: shanev at gmail.com (Shane Vitarana) Date: Thu, 24 Jan 2008 17:47:52 -0600 Subject: [Facebooker-talk] getting started with facebooker In-Reply-To: <20080124133013441900.4f32edf5@gmail.com> References: <57682593-655F-4E89-8183-3F4FD8F77507@elevatedrails.com> <20080124114148693554.47a822b9@gmail.com> <20080124121229564844.041bb9be@gmail.com> <4ab757a40801241303p4f5f2660le64bf7c1cf345407@mail.gmail.com> <20080124130857840389.37a3b50a@gmail.com> <4ab757a40801241320y3f8e763p4ead25615cd3bdff@mail.gmail.com> <20080124133013441900.4f32edf5@gmail.com> Message-ID: <4ab757a40801241547n68ed838r72f557f96e40006f@mail.gmail.com> Cool. On Jan 24, 2008 3:30 PM, Shawn Van Ittersum wrote: > OK, then my request to get multiple fields for multiple users still holds. The FB API allows this, so we should have a method to do it, as Chad has also said. I'll be looking into this further after working on the callback_path stuff. > > Shawn > > > On Thu, 24 Jan 2008 15:20:37 -0600, Shane Vitarana wrote: > > You can only get multiple specified files for *one* user. You can > > always construct an FQL query to get multiple fields for multiple > > users. > > > > On Jan 24, 2008 3:08 PM, Shawn Van Ittersum wrote: > >> OK, but does this allow fetching multiple specified fields on > >> multiple specified users all in one FB API call? > >> > >> Shawn > >> > >> > >> On Thu, 24 Jan 2008 15:03:39 -0600, Shane Vitarana wrote: > >>> Shawn- > >>> > >>> You can specify what fields you want as symbols. i.e: > >>> facebook_session.user.populate(:first_name). This will only fetch the > >>> first name record. > >>> > >>> Shane > >>> > >>> > >>> On Jan 24, 2008 2:12 PM, Shawn Van Ittersum > >>> wrote: > >>>> Well, ideally, we'd also get to specify which fields get fetched > >>>> from FB. Some (networks, schools, etc) require JOINs on FB's > >>>> database and take longer to complete. I have timed simple requests > >>>> (name, birthdate, etc) against full requests and noticed dramatic > >>>> differences in speed. > >>>> > >>>> Shawn > >>>> > >>>> > >>>> On Thu, 24 Jan 2008 12:46:19 -0700, David Clements wrote: > >>>>> Isn't that what user.friends! already does? I think I did this once > >>>>> when I first started out. > >>>>> > >>>>> ### > >>>>> # Retrieve friends with user info populated > >>>>> # Subsequent calls will be retrieved from memory. > >>>>> # Optional: list of fields to retrieve as symbols > >>>>> def friends!(*fields) > >>>>> @friends ||= session.post('facebook.users.getInfo', :fields => > >>>>> collect(fields), :uids => friends.map{|f| f.id}.join(',')).map do > >>>>> |hash| > >>>>> User.new(hash['uid'], session, hash) > >>>>> end > >>>>> end > >>>>> > >>>>> Dave > >>>>> > >>>>> > >>>>> > >>>>> On Jan 24, 2008 12:41 PM, Shawn Van Ittersum > >>>>> wrote: > >>>>>> Can Facebooker be modified to call FB's getInfo on a list of friend > >>>>>> ID's instead of one at a time? > >>>>>> > >>>>>> Shawn > >>>>>> > >>>>>> > >>>>>> On Thu, 24 Jan 2008 08:23:57 -0600, Mike Mangino wrote: > >>>>>>> Facebooker is querying facebook and looking up the name of each > >>>>>>> friend, one at a time. We populate the the friends array from the ID > >>>>>>> list that is passed in via Facebook. > >>>>>>> > >>>>>>> If you want this output without having to query facebook for each > >>>>>>> friends, you can use: > >>>>>>> > >>>>>>> <%= fb_name a_friend,: firstnameonly=>true %> > >>>>>>> > >>>>>>> Mike > >>>>>>> > >>>>>>> On Jan 24, 2008, at 7:39 AM, Joel Nylund wrote: > >>>>>>> > >>>>>>>> Hi, > >>>>>>>> > >>>>>>>> I started with rfacebook but given the recent events figure its best > >>>>>>>> to move over to facebooker. > >>>>>>>> > >>>>>>>> I have: > >>>>>>>> > >>>>>>>> 1.) Installed the facebooker plugin > >>>>>>>> 2.) setup my facebook app (fbml/canvas) > >>>>>>>> 3.) created a method on controller & view to handle initial request > >>>>>>>> 4.) added "ensure_application_is_installed_by_facebook_user" to top > >>>>>>>> off application.rb > >>>>>>>> > >>>>>>>> I am able to get to my landing page and show the facebook id of the > >>>>>>>> users that comes in, but... > >>>>>>>> > >>>>>>>> If I try to show the users friends in the view using: > >>>>>>>> <% for a_friend in @user.friends %> > >>>>>>>> <%=a_friend.first_name%> > >>>>>>>> <% end %> > >>>>>>>> > >>>>>>>> It makes my server hang, for about 70 seconds, then the method seems > >>>>>>>> to complete. Note, I had similar functionality working in rfacebook, > >>>>>>>> so I don't think its an environmental thing. > >>>>>>>> > >>>>>>>> What could I be doing wrong? > >>>>>>>> > >>>>>>>> Also, I have done some reading on issues with running a non facebook > >>>>>>>> application with this setup on same application, what should I do? > >>>>>>>> > >>>>>>>> a.) Create a subclass of my ApplicationController called > >>>>>>>> FaceController to do all the facebook related stuff? > >>>>>>>> b.) Is there a way to do an if around > >>>>>>>> "ensure_application_is_installed_by_facebook_user" so that it is only > >>>>>>>> enforced if coming from facebook? > >>>>>>>> > >>>>>>>> Does anyone have an example app, example code of how to do common > >>>>>>>> things?, I looked through kitchen sink and there is nothing in there? > >>>>>>>> I will blog how to do this TODAY if you guys help me get it going. > >>>>>>>> > >>>>>>>> thanks > >>>>>>>> Joel > >>>>>>>> > >>>>>>>> _______________________________________________ > >>>>>>>> Facebooker-talk mailing list > >>>>>>>> Facebooker-talk at rubyforge.org > >>>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>>>> > >>>>>>> -- > >>>>>>> Mike Mangino > >>>>>>> http://www.elevatedrails.com > >>>>>>> > >>>>>>> _______________________________________________ > >>>>>>> Facebooker-talk mailing list > >>>>>>> Facebooker-talk at rubyforge.org > >>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>>> _______________________________________________ > >>>>>> Facebooker-talk mailing list > >>>>>> Facebooker-talk at rubyforge.org > >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>>> > >>>> _______________________________________________ > >>>> Facebooker-talk mailing list > >>>> Facebooker-talk at rubyforge.org > >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>> > >>> > >>> > >>> > >>> -- > >>> http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > >> > > > > > > > > -- > > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From jnylund at yahoo.com Fri Jan 25 09:55:27 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Fri, 25 Jan 2008 09:55:27 -0500 Subject: [Facebooker-talk] simple routing & linking question Message-ID: So I have an existing app & facebook app in same rails application, for now I have decided to go the route of creating a controller for facebook stuff (called FaceController). (setup is canvas, fbml) So I have: facebook config http://myurl:myport/face/ My controllers name is face, so I dont even need a manual route, for the landing page it works like a charm. but, when I try to make links: true) %>" title="All Tasks"> This makes a url call to http://myurl:myport/face/face/index Any ideas for a cleaner setup? btw, is there a helper for making this link cleaner than this, or is this the best way to do it (borrowed from rfacebook example) thanks Joel From jnylund at yahoo.com Fri Jan 25 11:45:46 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Fri, 25 Jan 2008 11:45:46 -0500 Subject: [Facebooker-talk] ajax with facebooker? Message-ID: <086067E6-4630-4969-A28C-31B8388F7D9C@yahoo.com> So if I am using fbml,canvas & facebooker, can I do ajax calls? if so how? From reading it seems they support some sort of mock ajax, but I don't really understand, can somone explain to me? If I cant do ajax, can I still do javascript? Can I use 3rd party libs like prototype & scriptaculous? thanks Joel From bjclark at scidept.com Fri Jan 25 12:02:10 2008 From: bjclark at scidept.com (BJ Clark) Date: Fri, 25 Jan 2008 10:02:10 -0700 Subject: [Facebooker-talk] ajax with facebooker? In-Reply-To: <086067E6-4630-4969-A28C-31B8388F7D9C@yahoo.com> References: <086067E6-4630-4969-A28C-31B8388F7D9C@yahoo.com> Message-ID: Joel, Check out the facebook wiki on this: http://wiki.developers.facebook.com/index.php/FBJS As far as in your views, you can't use the built in view helpers, you'll have to code stuff from scratch as the wiki explains. In your controllers and models, everything is the same as a regular rails app. BJ ----- BJ Clark the science department bjclark at scidept.com www.scidept.com On Jan 25, 2008, at 9:45 AM, Joel Nylund wrote: > So if I am using fbml,canvas & facebooker, can I do ajax calls? if so > how? > > From reading it seems they support some sort of mock ajax, but I > don't really understand, can somone explain to me? > > If I cant do ajax, can I still do javascript? > > Can I use 3rd party libs like prototype & scriptaculous? > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080125/2de8285d/attachment.html From svicalifornia at gmail.com Fri Jan 25 12:48:22 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Fri, 25 Jan 2008 09:48:22 -0800 Subject: [Facebooker-talk] simple routing & linking question In-Reply-To: References: Message-ID: <20080125094822869985.00b81004@gmail.com> Hi Joel, This is the same problem I had, and I solved it by introducing a callback_path variable (like rfacebook has) and rewriting facebook_url_rewriting.rb. I'm working to make my changes backward-compatible with other users' Facebooker configs so I can contribute the code back to the project. Shawn On Fri, 25 Jan 2008 09:55:27 -0500, Joel Nylund wrote: > So I have an existing app & facebook app in same rails application, > for now I have decided to go the route of creating a controller for > facebook stuff (called FaceController). > (setup is canvas, fbml) > > So I have: > > facebook config > http://myurl:myport/face/ > > My controllers name is face, so I dont even need a manual route, for > the landing page it works like a charm. > > but, when I try to make links: > > href="http://apps.facebook.com<%= url_for(:controller => > 'face', :action => "index", :only_path => true) %>" > title="All Tasks"> > > This makes a url call to http://myurl:myport/face/face/index > > Any ideas for a cleaner setup? > > btw, is there a helper for making this link cleaner than this, or is > this the best way to do it (borrowed from rfacebook example) > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From svicalifornia at gmail.com Fri Jan 25 12:50:00 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Fri, 25 Jan 2008 09:50:00 -0800 Subject: [Facebooker-talk] ajax with facebooker? In-Reply-To: <086067E6-4630-4969-A28C-31B8388F7D9C@yahoo.com> References: <086067E6-4630-4969-A28C-31B8388F7D9C@yahoo.com> Message-ID: <20080125095000030456.53bdf96e@gmail.com> Plain JavaScript is not allowed in FBML apps. You'll have to use FB's "mock AJAX" and/or FBJS. Shawn On Fri, 25 Jan 2008 11:45:46 -0500, Joel Nylund wrote: > So if I am using fbml,canvas & facebooker, can I do ajax calls? if so > how? > > From reading it seems they support some sort of mock ajax, but I > don't really understand, can somone explain to me? > > If I cant do ajax, can I still do javascript? > > Can I use 3rd party libs like prototype & scriptaculous? > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From mmangino at elevatedrails.com Fri Jan 25 12:51:46 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Fri, 25 Jan 2008 11:51:46 -0600 Subject: [Facebooker-talk] form helpers and paths In-Reply-To: <1DAEAB6B-E5A3-4091-85C3-DC602A5D76CB@yahoo.com> References: <1DAEAB6B-E5A3-4091-85C3-DC602A5D76CB@yahoo.com> Message-ID: <959CA74B-9CB0-491F-A730-368D11ADF379@elevatedrails.com> This is just a normal rails named route. You could also use something like {:action=>:create} Mike On Jan 24, 2008, at 10:59 AM, Joel Nylund wrote: > In the form helpers code, the comments have examples like > "create_poke_path". > > can you tell me what this path is, and where I can read about it? > > I assume its a way to say what controller/method should be called when > the form action is taken, but what is the format? > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From mmangino at elevatedrails.com Fri Jan 25 12:55:11 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Fri, 25 Jan 2008 11:55:11 -0600 Subject: [Facebooker-talk] New Batch API method In-Reply-To: <007F6049-82DA-46E9-A5F8-18CFD454CEEB@scidept.com> References: <007F6049-82DA-46E9-A5F8-18CFD454CEEB@scidept.com> Message-ID: I've thought about it a little, but I'm not sure how it should work. I was thinking about something like facebook_session.batch do |batch_session| notify_result=batch_session.send_notification(...) albums = bath.albums end The problem I see is that we need a way to give back a fake return value, since we won't have a real result until outside of the loop. We'll also need to handle errors during the load. I would consider returning a dumb proxy object that delegates everything to another object. I may prototype this one shortly, but to be honest, I don't think I'm going to use it. Mike On Jan 24, 2008, at 1:10 PM, BJ Clark wrote: > Anyone started implementing the new Batch api method? > > BJ > ----- > BJ Clark > the science department > bjclark at scidept.com > www.scidept.com > > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From mmangino at elevatedrails.com Fri Jan 25 12:56:40 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Fri, 25 Jan 2008 11:56:40 -0600 Subject: [Facebooker-talk] Is there a test for setting the session ID to the fb_sig_session_key param? In-Reply-To: References: Message-ID: I think Michael wrote that code, and we decided that the tests would be more work than they are worth. Can you explain exactly what problem you are having? Mike On Jan 24, 2008, at 2:32 PM, David Clements wrote: > Hey all, > > I have a patch that fixes a problem I am having with IFramed pages in > rails 2.0. I am relying on the session being retrieved via > fb_sig_session_key. I am looking for the test code that tests this > functionality but I can't seem to find it. > > So you on the list today Chad, gotta pointer for me? > > > Thanks, I want to get a test in for this fix, > > Dave > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From bjclark at scidept.com Fri Jan 25 13:05:03 2008 From: bjclark at scidept.com (BJ Clark) Date: Fri, 25 Jan 2008 11:05:03 -0700 Subject: [Facebooker-talk] simple routing & linking question In-Reply-To: <20080125094822869985.00b81004@gmail.com> References: <20080125094822869985.00b81004@gmail.com> Message-ID: <85B63D65-2E06-4916-ABA5-577DFA97D66E@scidept.com> I still don't understand why this is necessary. Why do you guys use absolute urls? What's wrong with using a relative url? What are you guys setting ENV['FACEBOOKER_RELATIVE_URL_ROOT'] to in your env files? Joel: If you don't want /face/face/index, why don't you just leave off the :controller part of the url_for or (I'm guessing this is the issue) set your F...R_RELATIVE_URL_ROOT to "" (is it currently set to "face" also?)? BJ ----- BJ Clark the science department bjclark at scidept.com www.scidept.com On Jan 25, 2008, at 10:48 AM, Shawn Van Ittersum wrote: > Hi Joel, > > This is the same problem I had, and I solved it by introducing a > callback_path variable (like rfacebook has) and rewriting > facebook_url_rewriting.rb. I'm working to make my changes backward- > compatible with other users' Facebooker configs so I can contribute > the code back to the project. > > Shawn > > On Fri, 25 Jan 2008 09:55:27 -0500, Joel Nylund wrote: >> So I have an existing app & facebook app in same rails application, >> for now I have decided to go the route of creating a controller for >> facebook stuff (called FaceController). >> (setup is canvas, fbml) >> >> So I have: >> >> facebook config >> http://myurl:myport/face/ >> >> My controllers name is face, so I dont even need a manual route, for >> the landing page it works like a charm. >> >> but, when I try to make links: >> >> > href="http://apps.facebook.com<%= url_for(:controller => >> 'face', :action => "index", :only_path => true) %>" >> title="All Tasks"> >> >> This makes a url call to http://myurl:myport/face/face/index >> >> Any ideas for a cleaner setup? >> >> btw, is there a helper for making this link cleaner than this, or is >> this the best way to do it (borrowed from rfacebook example) >> >> thanks >> Joel >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From mmangino at elevatedrails.com Fri Jan 25 13:10:46 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Fri, 25 Jan 2008 12:10:46 -0600 Subject: [Facebooker-talk] simple routing & linking question In-Reply-To: References: Message-ID: <8A0438CA-C530-44F9-92EE-F671910C35D8@elevatedrails.com> This has been a frequently asked question and one that I'm working on in my book right now. Here are my recommendations: Don't set a controller as your callback path. How will you create a development and production environment? Instead, make your callback url by the root of the server, i.e. http://myurl :myport/ Inside your routes.rb, do: map.facebook_root '', :controller=>"face", :conditions=>{:canvas=>true} Put that before your root route for your main site Your urls can then be: <% fb_tabs do %> <%= fb_tab_item("All Tasks",facebook_root %> <% end %> If you want to link to your facebook page from a non-facebook view, do: <%= link_to "Check me out on facebook",facebook_root_url(:canvas=>true) %> If you want to link to your non-facebook app from facebook, simply do <%= link_to "Check out my non-facebook website", todo_path(:canvas=>false) %> Does that make sense? I know this stuff isn't documented as well as it could be. There are people working on that. Please contribute tutorials. If you write one, let me know and I will give you access to the new http://www.facebooker-api.com site to upload it. SHAMELESS PLUG: I'm also writing a book on Facebook development with rails that will be available as a beta book. I'll let everybody know when it is available. I'm hoping it will available within the next three weeks or so. Mike On Jan 25, 2008, at 8:55 AM, Joel Nylund wrote: > So I have an existing app & facebook app in same rails application, > for now I have decided to go the route of creating a controller for > facebook stuff (called FaceController). > (setup is canvas, fbml) > > So I have: > > facebook config > http://myurl:myport/face/ > > My controllers name is face, so I dont even need a manual route, for > the landing page it works like a charm. > > but, when I try to make links: > > href="http://apps.facebook.com<%= url_for(:controller => > 'face', :action => "index", :only_path => true) %>" > title="All Tasks"> > > This makes a url call to http://myurl:myport/face/face/index > > Any ideas for a cleaner setup? > > btw, is there a helper for making this link cleaner than this, or is > this the best way to do it (borrowed from rfacebook example) > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From jnylund at yahoo.com Fri Jan 25 15:04:37 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Fri, 25 Jan 2008 15:04:37 -0500 Subject: [Facebooker-talk] simple routing & linking question In-Reply-To: <85B63D65-2E06-4916-ABA5-577DFA97D66E@scidept.com> References: <20080125094822869985.00b81004@gmail.com> <85B63D65-2E06-4916-ABA5-577DFA97D66E@scidept.com> Message-ID: <023B2E55-F45F-4DB2-8B2A-C062D6CF652C@yahoo.com> I don't wan to do absolute urls, I just cant figure out how to get it to work with relative urls (going to try Mike suggestion) my relative root env is set to my application name right now (http://apps.facebook.com/myapp --- mine is set to myapp) thanks Joel On Jan 25, 2008, at 1:05 PM, BJ Clark wrote: > I still don't understand why this is necessary. > > Why do you guys use absolute urls? What's wrong with using a relative > url? > > What are you guys setting ENV['FACEBOOKER_RELATIVE_URL_ROOT'] to in > your env files? > > Joel: > If you don't want /face/face/index, why don't you just leave off > the :controller part of the url_for or (I'm guessing this is the > issue) set your F...R_RELATIVE_URL_ROOT to "" (is it currently set to > "face" also?)? > > BJ > ----- > BJ Clark > the science department > bjclark at scidept.com > www.scidept.com > > > On Jan 25, 2008, at 10:48 AM, Shawn Van Ittersum wrote: > >> Hi Joel, >> >> This is the same problem I had, and I solved it by introducing a >> callback_path variable (like rfacebook has) and rewriting >> facebook_url_rewriting.rb. I'm working to make my changes backward- >> compatible with other users' Facebooker configs so I can contribute >> the code back to the project. >> >> Shawn >> >> On Fri, 25 Jan 2008 09:55:27 -0500, Joel Nylund wrote: >>> So I have an existing app & facebook app in same rails application, >>> for now I have decided to go the route of creating a controller for >>> facebook stuff (called FaceController). >>> (setup is canvas, fbml) >>> >>> So I have: >>> >>> facebook config >>> http://myurl:myport/face/ >>> >>> My controllers name is face, so I dont even need a manual route, for >>> the landing page it works like a charm. >>> >>> but, when I try to make links: >>> >>> >> href="http://apps.facebook.com<%= url_for(:controller => >>> 'face', :action => "index", :only_path => true) %>" >>> title="All Tasks"> >>> >>> This makes a url call to http://myurl:myport/face/face/index >>> >>> Any ideas for a cleaner setup? >>> >>> btw, is there a helper for making this link cleaner than this, or is >>> this the best way to do it (borrowed from rfacebook example) >>> >>> thanks >>> Joel >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From jnylund at yahoo.com Fri Jan 25 15:08:51 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Fri, 25 Jan 2008 15:08:51 -0500 Subject: [Facebooker-talk] simple routing & linking question In-Reply-To: <8A0438CA-C530-44F9-92EE-F671910C35D8@elevatedrails.com> References: <8A0438CA-C530-44F9-92EE-F671910C35D8@elevatedrails.com> Message-ID: <85D6F58B-1EA2-4DD4-AEF8-129852C84AC4@yahoo.com> Thanks to everyone for the responses, I think I will go with Mike's suggestion, I implemented your approach and it seems to mess up my stand alone app, it seems to always try to route to facebook when I add: map.facebook_root '', :controller=>"face", :conditions=>{:canvas=>true} to the top of my routes.rb file Also I have one question on the tabs How do I link to a method: on fb_tabs: for example I want to have a tab "My Tasks" that links to face controller mytasks method. If I do: <%= fb_tab_item("My Tasks", facebook_root_url + url_for(:controller => :face,:action => :my_tasks, :only_path => true)) %> it generates the url: http://apps.facebook.com/myapp//myapp/face/my_tasks My relative url is: ENV['FACEBOOKER_RELATIVE_URL_ROOT'] = 'myapp' As for your book, please hurry :) let me know if you want someone to read it. thanks Joel On Jan 25, 2008, at 1:10 PM, Mike Mangino wrote: > This has been a frequently asked question and one that I'm working > on in my book right now. Here are my recommendations: > > Don't set a controller as your callback path. How will you create a > development and production environment? > > Instead, make your callback url by the root of the server, i.e. http://myurl > :myport/ > > Inside your routes.rb, do: > > map.facebook_root > '', :controller=>"face", :conditions=>{:canvas=>true} > > Put that before your root route for your main site > > Your urls can then be: > <% fb_tabs do %> > <%= fb_tab_item("All Tasks",facebook_root %> > <% end %> > > If you want to link to your facebook page from a non-facebook view, > do: > > <%= link_to "Check me out on > facebook",facebook_root_url(:canvas=>true) %> > > If you want to link to your non-facebook app from facebook, simply do > > <%= link_to "Check out my non-facebook website", > todo_path(:canvas=>false) %> > > > Does that make sense? I know this stuff isn't documented as well as > it could be. There are people working on that. Please contribute > tutorials. If you write one, let me know and I will give you access > to the new http://www.facebooker-api.com site to upload it. > > SHAMELESS PLUG: > > I'm also writing a book on Facebook development with rails that will > be available as a beta book. I'll let everybody know when it is > available. I'm hoping it will available within the next three weeks > or so. > > Mike > > > On Jan 25, 2008, at 8:55 AM, Joel Nylund wrote: > >> So I have an existing app & facebook app in same rails application, >> for now I have decided to go the route of creating a controller for >> facebook stuff (called FaceController). >> (setup is canvas, fbml) >> >> So I have: >> >> facebook config >> http://myurl:myport/face/ >> >> My controllers name is face, so I dont even need a manual route, for >> the landing page it works like a charm. >> >> but, when I try to make links: >> >> > href="http://apps.facebook.com<%= url_for(:controller => >> 'face', :action => "index", :only_path => true) %>" >> title="All Tasks"> >> >> This makes a url call to http://myurl:myport/face/face/index >> >> Any ideas for a cleaner setup? >> >> btw, is there a helper for making this link cleaner than this, or is >> this the best way to do it (borrowed from rfacebook example) >> >> thanks >> Joel >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > > From jnylund at yahoo.com Fri Jan 25 16:46:06 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Fri, 25 Jan 2008 16:46:06 -0500 Subject: [Facebooker-talk] form error with datetime select Message-ID: <8194B430-44A3-493C-BEC5-23211F2F50B5@yahoo.com> Hi, Im trying to build a form using: <% facebook_form_for(:task, at task,:url => create_task_path) do |f| %> Assign Task To: <%= fb_friend_selector %> <%=f.text_field :ttype, :label=> "Title"%> <%=f.datetime_select :duedate, :label=> "Due Date"%> <%=f.buttons "Add" %> <% end %> But im getting an error: ActionView::TemplateError (undefined local variable or method `_erbout' for #) on line #12 of app/views/face/new_task.rhtml: 9: <% facebook_form_for(:task, at task,:url => create_task_path) do |f| %> 10: Assign Task To: <%= fb_friend_selector %> 11: <%=f.text_field :ttype, :label=> "Title"%> 12: <%=f.datetime_select :duedate, :label=> "Due Date"%> 13: <%=f.buttons "Add" %> 14: <% end %> 15: vendor/plugins/facebooker/lib/facebooker/rails/ facebook_form_builder.rb:30:in `build_shell' vendor/plugins/facebooker/lib/facebooker/rails/ facebook_form_builder.rb:30:in `datetime_select' #{RAILS_ROOT}/app/views/face/new_task.rhtml:12:in `_run_rhtml_47app47views47face47new_task46rhtml' /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/actionpack-1.13.3/lib/action_view/helpers/ form_helper.rb:151:in `fields_for' vendor/plugins/facebooker/lib/facebooker/rails/helpers.rb:135:in `facebook_form_for' #{RAILS_ROOT}/app/views/face/new_task.rhtml:9:in `_run_rhtml_47app47views47face47new_task46rhtml' To make sure im not doing something stupid, I just did and it works: <% form_for(:task, at task,:url => create_task_path) do |f| %> <%=f.text_field :ttype, :label=> "Title"%> <%=f.datetime_select :duedate, :label=> "Due Date"%> <%=submit_tag %> <% end %> It seemed to work ok until I added the datetime select. (although mixing the facebook field and the rails stuff didnt look too nice. thanks Joel From sudara at alonetone.com Fri Jan 25 17:09:58 2008 From: sudara at alonetone.com (sudara) Date: Fri, 25 Jan 2008 23:09:58 +0100 Subject: [Facebooker-talk] More on routing, relative_root and facebooker Message-ID: <8E302D2D-D2AF-4BBF-ADED-DCBB9344FDC9@alonetone.com> Hey there! I would like the discussion to continue on how facebooker handles routes, as it appears that there is an unsolved issue. Mike, I read your recent reply involving setting facebook's callback_path to the root of the rails app, and adding a route to catch all calls to the app root where canvas => true. I just want to point out this is counterintuitive to some folks and I didn't actually get what you really meant until i started writing this. Still my brain is confused, and I have no idea what the ideal is for how facebooker is supposed to work regarding routing. So, I'll finish writing it so that maybe it helps someone else and again puts it out there that something is funky, at least to folks wanting to do have a part of their app be facebook, but not all of it. Here is why people like me are running into issues. You build a rails app. All is fine and dandy. You want to expose a few controller/actions to facebook, and so you install facebooker. I define my facebook callback_path to be 'facebook' then facebook should always be hitting: http://mydomain.com/facebook Great. Next, I want to next define routes to catch those calls and render appropriately. I would use map.facebook_resouces, except I can't pass any options in (for example a prefix 'facebook' or a different controller name from a route name) For fun, I take an hour and experiment and rewrite the facebook routing stuff to allow it to take options. I get it working great...but still, there was this screwy thing with urls looking like this in canvas: http://apps.facebook.com/appname/facebook/... and therefore hitting the rails routing as: http://mydomain.com/facebook/facebook/.... Ok, so then I try a manual route, just to try and get it working: map.facebook_accounts '/facebook/:action/:id', :controller => 'facebook_accounts' Same deal, the first hit onto facebook is fine, but subsequent calls are wacky. My rails app seems to be working against me. The routes I dictate in routes.rb are not being listened to. There is magic going on that isn't helping me out, but making things tougher. (What makes matters worse is that people migrating from rFacebook are used to being more or less in control of their routes and probably have a different thinking cap on). So then I read Mike's latest post, and I say 'ok....make a conditional- on-canvas route for the base route of the app.' I'm sketched out because I don't really want my app being hit at the base or to define a route at the app root - I have 90% of my non-facebook stuff running off the root and want the facebook stuff namespaced. I try it anyway... I set my facebook callback url to http://mydomain.com # somewhere in config/initializers ENV['FACEBOOKER_RELATIVE_URL_ROOT'] = '' # in routes.rb map.facebook_accounts '', :controller => 'facebook_accounts', :condition => {:canvas => true} Ok, that breaks everything. My normal routes no longer function, nor do my helpers for those routes. After the first day of working with facebooker from my perspective, I think the following would be helpful: a) rewrite map.facebook_resources to handle options so people have a bit more flexibility (also add the GET/POST conditions to the routes) b) make it crystal clear somewhere in the docs that by default there is rewriting going on FOR you while in-canvas. I'm tempted to try out Shawns recent rewrite of the url_rewrite thing. Is there openness to a patch being accepted? still not up and running, but still trying, sudara From jnylund at yahoo.com Fri Jan 25 17:10:55 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Fri, 25 Jan 2008 17:10:55 -0500 Subject: [Facebooker-talk] form formatting Message-ID: <0C561406-8D8F-4CD9-8EF5-FD4BAA620B5E@yahoo.com> If I want to use fbml elements and rails tags, is there a way to do within a fb:editor? if I do: <% facebook_form_for(:task, at task,:url => create_task_path) do |f| %> Assign Task To: <%= fb_friend_selector %> <%=f.text_field :ttype, :label=> "Title"%> <%=text_field_tag :newrnumdays, ndays, :label => "# Days"%> <%=f.buttons "Add" %> <% end %> the text_field seems to be placed nicely in the editor and formatted accordingly but the friend selector & the text_field_tag are not placed inside the editor display table and are just dumped on the canvas. Not sure if images go through on this mail list, but attached what it looks like: -------------- next part -------------- A non-text attachment was scrubbed... Name: Picture 7.png Type: image/png Size: 9781 bytes Desc: not available Url : http://rubyforge.org/pipermail/facebooker-talk/attachments/20080125/ddd62fd5/attachment.png -------------- next part -------------- thanks Joel From mmangino at elevatedrails.com Fri Jan 25 18:31:20 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Fri, 25 Jan 2008 17:31:20 -0600 Subject: [Facebooker-talk] More on routing, relative_root and facebooker In-Reply-To: <8E302D2D-D2AF-4BBF-ADED-DCBB9344FDC9@alonetone.com> References: <8E302D2D-D2AF-4BBF-ADED-DCBB9344FDC9@alonetone.com> Message-ID: <17F0E4C9-6568-4173-89C2-6998405BB79D@elevatedrails.com> Sudara, I see a couple of issues here. First map.facebook_resources is deprecated. Use map.resources instead The second is that you set your facebook callback path to /facebook. Just leave it as http://mydomain.com/ Facebooker was built so that you can just specify your server root as the callback path. I know this isn't well documented. I'd love to have patches to fix the documentation. If you include a controller name or a namespace name in your callback path, it makes it very difficult to have multiple environments (dev and prod) and also multiple developers. Here's how I set things up: in production.rb ENV['FACEBOOK_CANVAS_PATH'] = 'growing' # the old name was FACEBOOKER_RELATIVE_URL_ROOT, that was too closely tied to the implementation ActionController::Base.asset_host="http://growing.elevatedrails.com" The main page from Facebook gets the route: map.connect '', :controller => 'gifts', :action => 'new' We have other routes like: map.resources :users, :member => { :profile => :any } map.resources :gifts ... In short, once you add a couple of lines to your environment file, you've got a completely normal rails app. If you want to show different information based upon whether the request comes from facebook or not, you do the same thing you would do with a multi-domain app: map.connect '', :controller => 'gifts', :action => 'new', :conditions=>{:canvas=>true} map.connect '', :controller => 'marketing', :action => 'index' compare this to a multidomain site I run: map.connect '', :controller => 'guide', :conditions=>{:host=>/guide/} map.connect '', :controller => 'home', :action => 'index' My main goal in building the rails integration of Facebooker this way is to make it identical to running a normal rails application. I want to be able to run a completely facebook app basically out of the box. I want to be able to use respond_to to render different content for Facebook and non-fb users. Mike On Jan 25, 2008, at 4:09 PM, sudara wrote: > Hey there! > > I would like the discussion to continue on how facebooker handles > routes, as it appears that there is an unsolved issue. > > Mike, I read your recent reply involving setting facebook's > callback_path to the root of the rails app, and adding a route to > catch all calls to the app root where canvas => true. > > I just want to point out this is counterintuitive to some folks and I > didn't actually get what you really meant until i started writing > this. Still my brain is confused, and I have no idea what the ideal is > for how facebooker is supposed to work regarding routing. So, I'll > finish writing it so that maybe it helps someone else and again puts > it out there that something is funky, at least to folks wanting to do > have a part of their app be facebook, but not all of it. > > Here is why people like me are running into issues. > > You build a rails app. All is fine and dandy. You want to expose a few > controller/actions to facebook, and so you install facebooker. > > I define my facebook callback_path to be 'facebook' then facebook > should always be hitting: > > http://mydomain.com/facebook > > Great. Next, I want to next define routes to catch those calls and > render appropriately. > > I would use map.facebook_resouces, except I can't pass any options in > (for example a prefix 'facebook' or a different controller name from a > route name) > > For fun, I take an hour and experiment and rewrite the facebook > routing stuff to allow it to take options. I get it working > great...but still, there was this screwy thing with urls looking like > this in canvas: > > http://apps.facebook.com/appname/facebook/... > > and therefore hitting the rails routing as: > > http://mydomain.com/facebook/facebook/.... > > Ok, so then I try a manual route, just to try and get it working: > > map.facebook_accounts '/facebook/:action/:id', :controller => > 'facebook_accounts' > > Same deal, the first hit onto facebook is fine, but subsequent calls > are wacky. My rails app seems to be working against me. The routes I > dictate in routes.rb are not being listened to. There is magic going > on that isn't helping me out, but making things tougher. (What makes > matters worse is that people migrating from rFacebook are used to > being more or less in control of their routes and probably have a > different thinking cap on). > > So then I read Mike's latest post, and I say 'ok....make a > conditional- > on-canvas route for the base route of the app.' I'm sketched out > because I don't really want my app being hit at the base or to define > a route at the app root - I have 90% of my non-facebook stuff running > off the root and want the facebook stuff namespaced. I try it > anyway... > > I set my facebook callback url to http://mydomain.com > > # somewhere in config/initializers > ENV['FACEBOOKER_RELATIVE_URL_ROOT'] = '' > > # in routes.rb > map.facebook_accounts '', :controller => > 'facebook_accounts', :condition => {:canvas => true} > > > Ok, that breaks everything. My normal routes no longer function, nor > do my helpers for those routes. > > After the first day of working with facebooker from my perspective, I > think the following would be helpful: > > a) rewrite map.facebook_resources to handle options so people have a > bit more flexibility (also add the GET/POST conditions to the routes) > b) make it crystal clear somewhere in the docs that by default there > is rewriting going on FOR you while in-canvas. > > I'm tempted to try out Shawns recent rewrite of the url_rewrite thing. > Is there openness to a patch being accepted? > > still not up and running, but still trying, > sudara > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From mmangino at elevatedrails.com Fri Jan 25 18:33:53 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Fri, 25 Jan 2008 17:33:53 -0600 Subject: [Facebooker-talk] form formatting In-Reply-To: <0C561406-8D8F-4CD9-8EF5-FD4BAA620B5E@yahoo.com> References: <0C561406-8D8F-4CD9-8EF5-FD4BAA620B5E@yahoo.com> Message-ID: Joel, try: <%=f.text(text_field_tag(:newrnumdays, ndays), :label => "# Days")%> The text method puts any string into the value of an editor. Mike On Jan 25, 2008, at 4:10 PM, Joel Nylund wrote: > If I want to use fbml elements and rails tags, is there a way to do > within a fb:editor? > > if I do: > > <% facebook_form_for(:task, at task,:url => create_task_path) do |f| %> > Assign Task To: <%= fb_friend_selector %> > <%=f.text_field :ttype, :label=> "Title"%> > <%=text_field_tag :newrnumdays, ndays, :label => "# Days"%> > <%=f.buttons "Add" %> > <% end %> > > the text_field seems to be placed nicely in the editor and formatted > accordingly but the friend selector & the text_field_tag are not > placed inside the editor display table and are just dumped on the > canvas. > > Not sure if images go through on this mail list, but attached what > it looks like: > > > > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From shanev at gmail.com Fri Jan 25 19:07:37 2008 From: shanev at gmail.com (Shane Vitarana) Date: Fri, 25 Jan 2008 18:07:37 -0600 Subject: [Facebooker-talk] form error with datetime select In-Reply-To: <8194B430-44A3-493C-BEC5-23211F2F50B5@yahoo.com> References: <8194B430-44A3-493C-BEC5-23211F2F50B5@yahoo.com> Message-ID: <4ab757a40801251607t72072241gdc66aa01ba9ed6f4@mail.gmail.com> Joel- I ran into this issue as well. I think it is because _erbout is being nested too deep and loses its binding needed to write to the ERB string buffer. One of my co-workers has a fix and we'll check it in once we have some good tests and make sure it covers all cases. Shane On 1/25/08, Joel Nylund wrote: > Hi, Im trying to build a form using: > > <% facebook_form_for(:task, at task,:url => create_task_path) do |f| %> > Assign Task To: <%= fb_friend_selector %> > <%=f.text_field :ttype, :label=> "Title"%> > <%=f.datetime_select :duedate, :label=> "Due Date"%> > <%=f.buttons "Add" %> > <% end %> > > But im getting an error: > > ActionView::TemplateError (undefined local variable or method > `_erbout' for #) on > line #12 of app/views/face/new_task.rhtml: > 9: <% facebook_form_for(:task, at task,:url => create_task_path) do |f| > %> > 10: Assign Task To: <%= fb_friend_selector %> > 11: <%=f.text_field :ttype, :label=> "Title"%> > 12: <%=f.datetime_select :duedate, :label=> "Due Date"%> > 13: <%=f.buttons "Add" %> > 14: <% end %> > 15: > > vendor/plugins/facebooker/lib/facebooker/rails/ > facebook_form_builder.rb:30:in `build_shell' > vendor/plugins/facebooker/lib/facebooker/rails/ > facebook_form_builder.rb:30:in `datetime_select' > #{RAILS_ROOT}/app/views/face/new_task.rhtml:12:in > `_run_rhtml_47app47views47face47new_task46rhtml' > /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/actionpack-1.13.3/lib/action_view/helpers/ > form_helper.rb:151:in `fields_for' > vendor/plugins/facebooker/lib/facebooker/rails/helpers.rb:135:in > `facebook_form_for' > #{RAILS_ROOT}/app/views/face/new_task.rhtml:9:in > `_run_rhtml_47app47views47face47new_task46rhtml' > > To make sure im not doing something stupid, I just did and it works: > > <% form_for(:task, at task,:url => create_task_path) do |f| %> > <%=f.text_field :ttype, :label=> "Title"%> > <%=f.datetime_select :duedate, :label=> "Due Date"%> > <%=submit_tag %> > <% end %> > > It seemed to work ok until I added the datetime select. (although > mixing the facebook field and the rails stuff didnt look too nice. > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From svicalifornia at gmail.com Fri Jan 25 19:16:20 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Fri, 25 Jan 2008 16:16:20 -0800 Subject: [Facebooker-talk] More on routing, relative_root and facebooker In-Reply-To: <17F0E4C9-6568-4173-89C2-6998405BB79D@elevatedrails.com> References: <8E302D2D-D2AF-4BBF-ADED-DCBB9344FDC9@alonetone.com> <17F0E4C9-6568-4173-89C2-6998405BB79D@elevatedrails.com> Message-ID: <20080125161620904666.3d13afad@gmail.com> On Fri, 25 Jan 2008 17:31:20 -0600, Mike Mangino wrote: > The second is that you set your facebook callback path to /facebook. > Just leave it as http://mydomain.com/ Facebooker was built so that you > can just specify your server root as the callback path. I know this > isn't well documented. I'd love to have patches to fix the > documentation. If you include a controller name or a namespace name in > your callback path, it makes it very difficult to have multiple > environments (dev and prod) and also multiple developers. Mike, The problem with pointing the Facebook app to the root of the rails app is that we don't want to expose all of the rails app's other functionality through facebook. We want to sandbox the facebook app to a subset of the rails app's functionality, which we make available through a facebook-specific controller. It is therefore a business requirement to include the controller in the callback_path, so the app will be properly sandboxed to the limited-function facebook controller. Including the controller in the callback_path does not make it any more difficult to support separate dev, test, and prod environments. We already host the entire app in three environments, so we do not need to create multiple controllers to simulate dev, test, and prod. We just need one facebook controller in each of our three rails environment instances. To connect to these different environments, we merely create three different facebook apps, each pointing to its own environment. Thus we can have our dev and test apps setup with news feed postings disabled and limited to developers only, and we can add new features to dev/test while our production app continues to serve new and existing users. I have yet to hear a good reason not to support specifying the controller on the callback_path. And there are some logic errors in facebook_url_rewriting, which I am also fixing as I add the ability to specify a longer callback_path. Also note that the changes I am implementing will not make it harder for you or anyone else to make a "facebook app basically out of the box." If you want to have all of your facebook stuff in the root of your rails app, that will still work. If you want the route from your root to a facebook controller as you seem to do now, that should still work too. The callback_path will be an optional variable with a default value to support Facebooker's current URL rewriting behavior, so you won't have to change a thing. And for those of us who need to sandbox the facebook to a controller with the callback_path, we will also be able to do that as well, just be adding the callback_path to our apps. Thanks, Shawn From shanev at gmail.com Fri Jan 25 19:38:04 2008 From: shanev at gmail.com (Shane Vitarana) Date: Fri, 25 Jan 2008 18:38:04 -0600 Subject: [Facebooker-talk] New feature: get profile pictures Message-ID: <4ab757a40801251638m3f306323vf7aa41ab60686ee9@mail.gmail.com> The profile picture album is treated as a special album by Facebok and is not returned in the normal get photo albums API call. A bunch of special operations have to be performed to get the aid for the profile picture album. I added a method to User to get the profile pics. Use as follows: facebook_session.user.profile_photos # returns Photo objects Enjoy, Shane -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From mmangino at elevatedrails.com Fri Jan 25 19:44:14 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Fri, 25 Jan 2008 18:44:14 -0600 Subject: [Facebooker-talk] More on routing, relative_root and facebooker In-Reply-To: <20080125161620904666.3d13afad@gmail.com> References: <8E302D2D-D2AF-4BBF-ADED-DCBB9344FDC9@alonetone.com> <17F0E4C9-6568-4173-89C2-6998405BB79D@elevatedrails.com> <20080125161620904666.3d13afad@gmail.com> Message-ID: <3D37A58E-DE4C-4F37-8EA7-D5BCE4BDA132@elevatedrails.com> Okay. I don't necessarily agree with you, but I'll shut up and look at your code. Please send the patch to the list to make sure I catch it. I've missed some on the rubyforge tracker. Mike On Jan 25, 2008, at 6:16 PM, Shawn Van Ittersum wrote: > On Fri, 25 Jan 2008 17:31:20 -0600, Mike Mangino wrote: >> The second is that you set your facebook callback path to /facebook. >> Just leave it as http://mydomain.com/ Facebooker was built so that >> you >> can just specify your server root as the callback path. I know this >> isn't well documented. I'd love to have patches to fix the >> documentation. If you include a controller name or a namespace name >> in >> your callback path, it makes it very difficult to have multiple >> environments (dev and prod) and also multiple developers. > > Mike, > > The problem with pointing the Facebook app to the root of the rails > app is that we don't want to expose all of the rails app's other > functionality through facebook. We want to sandbox the facebook app > to a subset of the rails app's functionality, which we make > available through a facebook-specific controller. It is therefore a > business requirement to include the controller in the callback_path, > so the app will be properly sandboxed to the limited-function > facebook controller. > > Including the controller in the callback_path does not make it any > more difficult to support separate dev, test, and prod > environments. We already host the entire app in three environments, > so we do not need to create multiple controllers to simulate dev, > test, and prod. We just need one facebook controller in each of our > three rails environment instances. To connect to these different > environments, we merely create three different facebook apps, each > pointing to its own environment. Thus we can have our dev and test > apps setup with news feed postings disabled and limited to > developers only, and we can add new features to dev/test while our > production app continues to serve new and existing users. > > I have yet to hear a good reason not to support specifying the > controller on the callback_path. And there are some logic errors in > facebook_url_rewriting, which I am also fixing as I add the ability > to specify a longer callback_path. > > Also note that the changes I am implementing will not make it harder > for you or anyone else to make a "facebook app basically out of the > box." If you want to have all of your facebook stuff in the root of > your rails app, that will still work. If you want the route from > your root to a facebook controller as you seem to do now, that > should still work too. The callback_path will be an optional > variable with a default value to support Facebooker's current URL > rewriting behavior, so you won't have to change a thing. And for > those of us who need to sandbox the facebook to a controller with > the callback_path, we will also be able to do that as well, just be > adding the callback_path to our apps. > > Thanks, > Shawn -- Mike Mangino http://www.elevatedrails.com From jnylund at yahoo.com Fri Jan 25 21:49:43 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Fri, 25 Jan 2008 21:49:43 -0500 Subject: [Facebooker-talk] form formatting In-Reply-To: References: <0C561406-8D8F-4CD9-8EF5-FD4BAA620B5E@yahoo.com> Message-ID: <30AAB421-36E3-478C-934B-EFA3AF448446@yahoo.com> cool that works, for the friend selector is there a similar trick?, I tried putting the label in the options but it didn't seem to work, I got it to look good using the brute force approach: <%=fb_friend_selector()%> thanks Joel On Jan 25, 2008, at 6:33 PM, Mike Mangino wrote: > Joel, try: <%=f.text(text_field_tag(:newrnumdays, ndays), :label => > "# Days")%> > > The text method puts any string into the value of an editor. > > Mike > > On Jan 25, 2008, at 4:10 PM, Joel Nylund wrote: > >> If I want to use fbml elements and rails tags, is there a way to do >> within a fb:editor? >> >> if I do: >> >> <% facebook_form_for(:task, at task,:url => create_task_path) do |f| %> >> Assign Task To: <%= fb_friend_selector %> >> <%=f.text_field :ttype, :label=> "Title"%> >> <%=text_field_tag :newrnumdays, ndays, :label => "# Days"%> >> <%=f.buttons "Add" %> >> <% end %> >> >> the text_field seems to be placed nicely in the editor and >> formatted accordingly but the friend selector & the text_field_tag >> are not placed inside the editor display table and are just dumped >> on the canvas. >> >> Not sure if images go through on this mail list, but attached what >> it looks like: >> >> >> >> >> thanks >> Joel >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > > From jnylund at yahoo.com Fri Jan 25 22:16:48 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Fri, 25 Jan 2008 22:16:48 -0500 Subject: [Facebooker-talk] simple routing & linking question In-Reply-To: <85D6F58B-1EA2-4DD4-AEF8-129852C84AC4@yahoo.com> References: <8A0438CA-C530-44F9-92EE-F671910C35D8@elevatedrails.com> <85D6F58B-1EA2-4DD4-AEF8-129852C84AC4@yahoo.com> Message-ID: Mike & Other Friends, I played with this some more but no luck, no matter what I do, adding : map.facebook_root '', :controller=>"face", :conditions=>{:canvas=>true} makes all requests to my app go to the facebook controller. I paired down my routes.rb to the basics, here it is: ActionController::Routing::Routes.draw do |map| map.facebook_root '', :controller=>"face", :conditions=>{:canvas=>true} map.connect '', :controller => 'account', :action => 'home' map.connect 'index.html', :controller => 'account', :action => 'home' map.connect 'index.htm', :controller => 'account', :action => 'home' # Install the default route as the lowest priority. map.connect '/:controller/:action' end If I go to localhost:3001 I get routed to: Processing FaceController#index (for 127.0.0.1 at 2008-01-25 22:09:07) [GET] Session ID: f513d7d336f467d9c6ca2f35e889dc7d Parameters: {"action"=>"index", "controller"=>"face"} any ideas? Is it just me, has anyone else tried this :conditions approach? I did get the tabs to work by doing: <%= fb_tab_item("My Tasks", facebook_root_url + url_for(:controller => :face,:action => :my_tasks, :only_path => true, :skip_relative_url_root => true)) %> the urls still have an extra slash, but they are working now! thanks Joel On Jan 25, 2008, at 3:08 PM, Joel Nylund wrote: > Thanks to everyone for the responses, I think I will go with Mike's > suggestion, > > I implemented your approach and it seems to mess up my stand alone > app, it seems to always try to route to facebook when I add: > map.facebook_root > '', :controller=>"face", :conditions=>{:canvas=>true} > > to the top of my routes.rb file > > Also I have one question on the tabs > > How do I link to a method: > > on fb_tabs: > > for example I want to have a tab "My Tasks" that links to face > controller mytasks method. > > If I do: > <%= fb_tab_item("My Tasks", facebook_root_url + url_for(:controller > => :face,:action => :my_tasks, :only_path => true)) %> > > it generates the url: > > http://apps.facebook.com/myapp//myapp/face/my_tasks > > My relative url is: > ENV['FACEBOOKER_RELATIVE_URL_ROOT'] = 'myapp' > > As for your book, please hurry :) let me know if you want someone to > read it. > > thanks > Joel > > On Jan 25, 2008, at 1:10 PM, Mike Mangino wrote: > >> This has been a frequently asked question and one that I'm working >> on in my book right now. Here are my recommendations: >> >> Don't set a controller as your callback path. How will you create a >> development and production environment? >> >> Instead, make your callback url by the root of the server, i.e. http://myurl >> :myport/ >> >> Inside your routes.rb, do: >> >> map.facebook_root >> '', :controller=>"face", :conditions=>{:canvas=>true} >> >> Put that before your root route for your main site >> >> Your urls can then be: >> <% fb_tabs do %> >> <%= fb_tab_item("All Tasks",facebook_root %> >> <% end %> >> >> If you want to link to your facebook page from a non-facebook view, >> do: >> >> <%= link_to "Check me out on >> facebook",facebook_root_url(:canvas=>true) %> >> >> If you want to link to your non-facebook app from facebook, simply do >> >> <%= link_to "Check out my non-facebook website", >> todo_path(:canvas=>false) %> >> >> >> Does that make sense? I know this stuff isn't documented as well as >> it could be. There are people working on that. Please contribute >> tutorials. If you write one, let me know and I will give you access >> to the new http://www.facebooker-api.com site to upload it. >> >> SHAMELESS PLUG: >> >> I'm also writing a book on Facebook development with rails that >> will be available as a beta book. I'll let everybody know when it >> is available. I'm hoping it will available within the next three >> weeks or so. >> >> Mike >> >> >> On Jan 25, 2008, at 8:55 AM, Joel Nylund wrote: >> >>> So I have an existing app & facebook app in same rails application, >>> for now I have decided to go the route of creating a controller for >>> facebook stuff (called FaceController). >>> (setup is canvas, fbml) >>> >>> So I have: >>> >>> facebook config >>> http://myurl:myport/face/ >>> >>> My controllers name is face, so I dont even need a manual route, for >>> the landing page it works like a charm. >>> >>> but, when I try to make links: >>> >>> >> href="http://apps.facebook.com<%= url_for(:controller => >>> 'face', :action => "index", :only_path => true) %>" >>> title="All Tasks"> >>> >>> This makes a url call to http://myurl:myport/face/face/index >>> >>> Any ideas for a cleaner setup? >>> >>> btw, is there a helper for making this link cleaner than this, or is >>> this the best way to do it (borrowed from rfacebook example) >>> >>> thanks >>> Joel >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> -- >> Mike Mangino >> http://www.elevatedrails.com >> >> >> > From svicalifornia at gmail.com Fri Jan 25 22:35:22 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Fri, 25 Jan 2008 19:35:22 -0800 Subject: [Facebooker-talk] simple routing & linking question In-Reply-To: <8A0438CA-C530-44F9-92EE-F671910C35D8@elevatedrails.com> References: <8A0438CA-C530-44F9-92EE-F671910C35D8@elevatedrails.com> Message-ID: <20080125193522961903.ce55fc2d@gmail.com> What book? Shawn On Fri, 25 Jan 2008 12:10:46 -0600, Mike Mangino wrote: > This has been a frequently asked question and one that I'm working on > in my book right now. From mmangino at elevatedrails.com Fri Jan 25 23:47:49 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Fri, 25 Jan 2008 22:47:49 -0600 Subject: [Facebooker-talk] simple routing & linking question In-Reply-To: <20080125193522961903.ce55fc2d@gmail.com> References: <8A0438CA-C530-44F9-92EE-F671910C35D8@elevatedrails.com> <20080125193522961903.ce55fc2d@gmail.com> Message-ID: <658AC2DA-06F0-4F1B-8FC2-E388347DE325@elevatedrails.com> I'm writing Facebook Application Development with Rails for the Pragmatic Bookshelf. I hope it will be available in beta format next month. I'm hard at work making that happen. I'm actually working on the code for integrating Facebook and non-Facebook applications. I'll make sure to spend a little time this weekend looking at using just a single controller or just several controllers. If you're having problems, I'd ask you to: 1) Make sure you are on the latest version of Facebooker. The conditions=>{:canvas=>true} was committed within the last week. 2) Try to reproduce it using a very small application. If you can do that, either post the code somewhere or email it to me and I will make it available. 3) It would be really nice if you could write a failing test for the problem you are having. It's better than just a sample app, but not required 4) Include a patch that fixes your failing tests. :) I know this can be a little frustrating, but please bare with us. Thanks Mike On Jan 25, 2008, at 9:35 PM, Shawn Van Ittersum wrote: > What book? > > Shawn > > On Fri, 25 Jan 2008 12:10:46 -0600, Mike Mangino wrote: >> This has been a frequently asked question and one that I'm working on >> in my book right now. -- Mike Mangino http://www.elevatedrails.com From shanev at gmail.com Sat Jan 26 02:40:49 2008 From: shanev at gmail.com (Shane Vitarana) Date: Sat, 26 Jan 2008 01:40:49 -0600 Subject: [Facebooker-talk] Introducing facebooker.yml Message-ID: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> If you are using facebooker as a plugin, you can now have all your configuration in one place, namely config/facebooker.yml. You can create this file with rake facebooker:setup. It is also generated when you install it as a plugin. It has a similar setup to database.yml with sections for each environment. You can also configure your ssh reverse tunnels. If you are upgrading, make sure to remove your facebooker specific setup in your environment files and consolidate them into facebooker.yml. Shane -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From jnylund at yahoo.com Sat Jan 26 07:50:33 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Sat, 26 Jan 2008 07:50:33 -0500 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> Message-ID: <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> Shane, I upgraded using : script/plugin install http://facebooker.rubyforge.org/svn/trunk/facebooker/ --force removed old env vars from my development.rb added my stuff to facebooker.yml Now when I start my server it will not start: ** Ruby version is up-to-date; cgi_multipart_eof_fix was not loaded ** Starting Mongrel listening at 0.0.0.0:3001 ** Starting Rails with development environment... Exiting /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ 1.8/rubygems.rb:249:in `activate': can't activate rails (= 1.2.6), already activated rails-1.2.3] (Gem::Exception) from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/1.8/rubygems/custom_require.rb:31:in `require' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ dependencies.rb:495:in `require' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ dependencies.rb:342:in `new_constants_in' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ dependencies.rb:495:in `require' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/1.8/rubygems/custom_require.rb:27:in `require' from script/server:3 from googling most people say this is related to a missing gem, is there a new gem dependency in this build? thanks Joel On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: > If you are using facebooker as a plugin, you can now have all your > configuration in one place, namely config/facebooker.yml. You can > create this file with rake facebooker:setup. It is also generated > when you install it as a plugin. > > It has a similar setup to database.yml with sections for each > environment. You can also configure your ssh reverse tunnels. > > If you are upgrading, make sure to remove your facebooker specific > setup in your environment files and consolidate them into > facebooker.yml. > > Shane > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From jnylund at yahoo.com Sat Jan 26 08:17:36 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Sat, 26 Jan 2008 08:17:36 -0500 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> Message-ID: <1D6F59EB-FF9B-4ED4-88E4-95328754BF63@yahoo.com> Sorry Shane its not the yml fix thats the problem, its been a week since I installed facebooker, I think its something todo with a previous checkin: require 'net/http_multipart_post' Im not sure exactly what the issue is, after I comment this out, I get this error: ** Starting Mongrel listening at 0.0.0.0:3001 ** Starting Rails with development environment... Exiting script/../config/../vendor/plugins/facebooker/init.rb:34:in `load_plugin_without_engine_additions': undefined method `optimise_named_routes=' for ActionController::Base:Class (NoMethodError) from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in `load_plugin_without_engine_additions' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/core_ext/ kernel/reporting.rb:11:in `silence_warnings' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in `load_plugin_without_engine_additions' from ./script/../config/../vendor/plugins/engines/lib/engines/ rails_extensions/rails_initializer.rb:54:in `load_plugin' from ./script/../config/../vendor/plugins/engines/lib/engines/ rails_extensions/rails_initializer.rb:36:in `load_all_plugins' from ./script/../config/../vendor/plugins/engines/lib/engines/ rails_extensions/rails_initializer.rb:36:in `each' from ./script/../config/../vendor/plugins/engines/lib/engines/ rails_extensions/rails_initializer.rb:36:in `load_all_plugins' from ./script/../config/../vendor/plugins/engines/lib/engines.rb: 253:in `after_initialize' ... 31 levels... from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ ruby/1.8/rubygems/custom_require.rb:27:in `require' Joel On Jan 26, 2008, at 7:50 AM, Joel Nylund wrote: > Shane, I upgraded using : > > script/plugin install http://facebooker.rubyforge.org/svn/trunk/facebooker/ > --force > > removed old env vars from my development.rb > added my stuff to facebooker.yml > > Now when I start my server it will not start: > > ** Ruby version is up-to-date; cgi_multipart_eof_fix was not loaded > ** Starting Mongrel listening at 0.0.0.0:3001 > ** Starting Rails with development environment... > Exiting > /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ > 1.8/rubygems.rb:249:in `activate': can't activate rails (= 1.2.6), > already activated rails-1.2.3] (Gem::Exception) > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:31:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ > dependencies.rb:495:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ > dependencies.rb:342:in `new_constants_in' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ > dependencies.rb:495:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:27:in `require' > from script/server:3 > > from googling most people say this is related to a missing gem, is > there a new gem dependency in this build? > > thanks > Joel > > > > On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: > >> If you are using facebooker as a plugin, you can now have all your >> configuration in one place, namely config/facebooker.yml. You can >> create this file with rake facebooker:setup. It is also generated >> when you install it as a plugin. >> >> It has a similar setup to database.yml with sections for each >> environment. You can also configure your ssh reverse tunnels. >> >> If you are upgrading, make sure to remove your facebooker specific >> setup in your environment files and consolidate them into >> facebooker.yml. >> >> Shane >> >> -- >> http://myfitbuddy.com | http://shanesbrain.net | http:// >> crimsonjet.com >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From mmangino at elevatedrails.com Sat Jan 26 10:10:35 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Sat, 26 Jan 2008 09:10:35 -0600 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <1D6F59EB-FF9B-4ED4-88E4-95328754BF63@yahoo.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> <1D6F59EB-FF9B-4ED4-88E4-95328754BF63@yahoo.com> Message-ID: <72A73C7F-D313-4560-883E-E3DE6F8231E5@elevatedrails.com> Hmm. What error do you get for net/http_multipart_post? That is a new library that allows you to upload photos to facebook. The next error was my fault. I assumed that everybody is running rails 2.0. That may be the cause of other problems. I'm inclined to only support rails 2.0 for now. Is anyone using facebooker successfully on rails 1.2? Mike On Jan 26, 2008, at 7:17 AM, Joel Nylund wrote: > Sorry Shane its not the yml fix thats the problem, its been a week > since I installed facebooker, > > I think its something todo with a previous checkin: > > require 'net/http_multipart_post' > > Im not sure exactly what the issue is, after I comment this out, I get > this error: > > ** Starting Mongrel listening at 0.0.0.0:3001 > ** Starting Rails with development environment... > Exiting > script/../config/../vendor/plugins/facebooker/init.rb:34:in > `load_plugin_without_engine_additions': undefined method > `optimise_named_routes=' for ActionController::Base:Class > (NoMethodError) > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in > `load_plugin_without_engine_additions' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/core_ext/ > kernel/reporting.rb:11:in `silence_warnings' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in > `load_plugin_without_engine_additions' > from ./script/../config/../vendor/plugins/engines/lib/engines/ > rails_extensions/rails_initializer.rb:54:in `load_plugin' > from ./script/../config/../vendor/plugins/engines/lib/engines/ > rails_extensions/rails_initializer.rb:36:in `load_all_plugins' > from ./script/../config/../vendor/plugins/engines/lib/engines/ > rails_extensions/rails_initializer.rb:36:in `each' > from ./script/../config/../vendor/plugins/engines/lib/engines/ > rails_extensions/rails_initializer.rb:36:in `load_all_plugins' > from ./script/../config/../vendor/plugins/engines/lib/engines.rb: > 253:in `after_initialize' > ... 31 levels... > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:27:in `require' > > > Joel > > > > On Jan 26, 2008, at 7:50 AM, Joel Nylund wrote: > >> Shane, I upgraded using : >> >> script/plugin install http://facebooker.rubyforge.org/svn/trunk/facebooker/ >> --force >> >> removed old env vars from my development.rb >> added my stuff to facebooker.yml >> >> Now when I start my server it will not start: >> >> ** Ruby version is up-to-date; cgi_multipart_eof_fix was not loaded >> ** Starting Mongrel listening at 0.0.0.0:3001 >> ** Starting Rails with development environment... >> Exiting >> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ >> 1.8/rubygems.rb:249:in `activate': can't activate rails (= 1.2.6), >> already activated rails-1.2.3] (Gem::Exception) >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/1.8/rubygems/custom_require.rb:31:in `require' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >> dependencies.rb:495:in `require' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >> dependencies.rb:342:in `new_constants_in' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >> dependencies.rb:495:in `require' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/1.8/rubygems/custom_require.rb:27:in `require' >> from script/server:3 >> >> from googling most people say this is related to a missing gem, is >> there a new gem dependency in this build? >> >> thanks >> Joel >> >> >> >> On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: >> >>> If you are using facebooker as a plugin, you can now have all your >>> configuration in one place, namely config/facebooker.yml. You can >>> create this file with rake facebooker:setup. It is also generated >>> when you install it as a plugin. >>> >>> It has a similar setup to database.yml with sections for each >>> environment. You can also configure your ssh reverse tunnels. >>> >>> If you are upgrading, make sure to remove your facebooker specific >>> setup in your environment files and consolidate them into >>> facebooker.yml. >>> >>> Shane >>> >>> -- >>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>> crimsonjet.com >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From svicalifornia at gmail.com Sat Jan 26 17:20:33 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Sat, 26 Jan 2008 14:20:33 -0800 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <72A73C7F-D313-4560-883E-E3DE6F8231E5@elevatedrails.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> <1D6F59EB-FF9B-4ED4-88E4-95328754BF63@yahoo.com> <72A73C7F-D313-4560-883E-E3DE6F8231E5@elevatedrails.com> Message-ID: <20080126142033061203.cce67a8d@gmail.com> Hi Mike, Sorry to add more trouble, but some of my clients have not upgraded to Rails 2.0 yet and may not be able to do so until late Q2 of this year. Unfortunately, I don't set the upgrade schedule. Given that 2.0 is still relatively new, I hope you will understand a need to support 1.x a little while longer. Thanks, Shawn On Sat, 26 Jan 2008 09:10:35 -0600, Mike Mangino wrote: > Hmm. What error do you get for net/http_multipart_post? That is a new > library that allows you to upload photos to facebook. > > The next error was my fault. I assumed that everybody is running rails > 2.0. That may be the cause of other problems. I'm inclined to only > support rails 2.0 for now. Is anyone using facebooker successfully on > rails 1.2? > > Mike > > On Jan 26, 2008, at 7:17 AM, Joel Nylund wrote: > >> Sorry Shane its not the yml fix thats the problem, its been a week >> since I installed facebooker, >> >> I think its something todo with a previous checkin: >> >> require 'net/http_multipart_post' >> >> Im not sure exactly what the issue is, after I comment this out, I get >> this error: >> >> ** Starting Mongrel listening at 0.0.0.0:3001 >> ** Starting Rails with development environment... >> Exiting >> script/../config/../vendor/plugins/facebooker/init.rb:34:in >> `load_plugin_without_engine_additions': undefined method >> `optimise_named_routes=' for ActionController::Base:Class >> (NoMethodError) >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >> `load_plugin_without_engine_additions' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/core_ext/ >> kernel/reporting.rb:11:in `silence_warnings' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >> `load_plugin_without_engine_additions' >> from ./script/../config/../vendor/plugins/engines/lib/engines/ >> rails_extensions/rails_initializer.rb:54:in `load_plugin' >> from ./script/../config/../vendor/plugins/engines/lib/engines/ >> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >> from ./script/../config/../vendor/plugins/engines/lib/engines/ >> rails_extensions/rails_initializer.rb:36:in `each' >> from ./script/../config/../vendor/plugins/engines/lib/engines/ >> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >> from ./script/../config/../vendor/plugins/engines/lib/engines.rb: >> 253:in `after_initialize' >> ... 31 levels... >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/1.8/rubygems/custom_require.rb:27:in `require' >> >> >> Joel >> >> >> >> On Jan 26, 2008, at 7:50 AM, Joel Nylund wrote: >> >>> Shane, I upgraded using : >>> >>> script/plugin install >>> http://facebooker.rubyforge.org/svn/trunk/facebooker/ >>> --force >>> >>> removed old env vars from my development.rb >>> added my stuff to facebooker.yml >>> >>> Now when I start my server it will not start: >>> >>> ** Ruby version is up-to-date; cgi_multipart_eof_fix was not loaded >>> ** Starting Mongrel listening at 0.0.0.0:3001 >>> ** Starting Rails with development environment... >>> Exiting >>> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ >>> 1.8/rubygems.rb:249:in `activate': can't activate rails (= 1.2.6), >>> already activated rails-1.2.3] (Gem::Exception) >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>> ruby/1.8/rubygems/custom_require.rb:31:in `require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>> dependencies.rb:495:in `require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>> dependencies.rb:342:in `new_constants_in' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>> dependencies.rb:495:in `require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>> ruby/1.8/rubygems/custom_require.rb:27:in `require' >>> from script/server:3 >>> >>> from googling most people say this is related to a missing gem, is >>> there a new gem dependency in this build? >>> >>> thanks >>> Joel >>> >>> >>> >>> On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: >>> >>>> If you are using facebooker as a plugin, you can now have all your >>>> configuration in one place, namely config/facebooker.yml. You can >>>> create this file with rake facebooker:setup. It is also generated >>>> when you install it as a plugin. >>>> >>>> It has a similar setup to database.yml with sections for each >>>> environment. You can also configure your ssh reverse tunnels. >>>> >>>> If you are upgrading, make sure to remove your facebooker specific >>>> setup in your environment files and consolidate them into >>>> facebooker.yml. >>>> >>>> Shane >>>> >>>> -- >>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>> crimsonjet.com >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From philipmatarese at yahoo.com Sat Jan 26 17:22:41 2008 From: philipmatarese at yahoo.com (Matarese Philip) Date: Sat, 26 Jan 2008 14:22:41 -0800 (PST) Subject: [Facebooker-talk] Facebooker::Session::IncorrectSignature Message-ID: <58685.18819.qm@web61017.mail.yahoo.com> I think I must be missing something obvious on this one, but I can't get past the initial "ensure_application_is_installed_by_facebook_user" in a rails app that I'm trying to put together. I'm running on edge rails with the latest Facebooker as a plugin. I've tried adding my settings to the environment configs and recently I tried the new yaml format. The non-facebook parts of the application work fine on their own when ensure_application... is commented out. This is my first attempt at a Facebook app, so I might be messing something up on that side of things as well. I followed the steps in http://rfacebook.wordpress.com/2008/01/05/desktop/, but perhaps there is something different for a web-based set up. All I get when I attempt to load a page that uses ensure_application_is_installed_by_facebook_user is this: vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:92:in `verify_signature' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:77:in `verified_facebook_params' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:24:in `facebook_params' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in `secure_with_facebook_params!' vendor/rails/activesupport/lib/active_support/inflector.rb:260:in `all?' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in `each' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in `all?' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in `secure_with_facebook_params!' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:15:in `set_facebook_session' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:130:in `ensure_authenticated_to_facebook' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:135:in `ensure_application_is_installed_by_facebook_user' As far as troubleshooting goes, I started digging into the code, but quickly realized that without understanding how the Facebook sessions are expected to function, I couldn't figure out what was being missed. I'd love to start playing around with some of this stuff, so any help would be appreciated. Thanks, -Phil ____________________________________________________________________________________ Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080126/768fd539/attachment-0001.html From jnylund at yahoo.com Sat Jan 26 17:39:40 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Sat, 26 Jan 2008 17:39:40 -0500 Subject: [Facebooker-talk] Facebooker::Session::IncorrectSignature In-Reply-To: <58685.18819.qm@web61017.mail.yahoo.com> References: <58685.18819.qm@web61017.mail.yahoo.com> Message-ID: <3ADFBECE-7F33-4204-916E-4AEC7C4A2E7B@yahoo.com> Hi, are you going through facebook to get there, I usually get this if I point directly to my rails app, you need to create the face book app on facebook and go to http://apps.facebook.com/yourapp to get to your app with the right stuff to make ensure_application_is_installed_by_facebook_user happy. Joel On Jan 26, 2008, at 5:22 PM, Matarese Philip wrote: > I think I must be missing something obvious on this one, but I can't > get past the initial > "ensure_application_is_installed_by_facebook_user" in a rails app > that I'm trying to put together. I'm running on edge rails with the > latest Facebooker as a plugin. I've tried adding my settings to the > environment configs and recently I tried the new yaml format. The > non-facebook parts of the application work fine on their own when > ensure_application... is commented out. > > This is my first attempt at a Facebook app, so I might be messing > something up on that side of things as well. I followed the steps inhttp://rfacebook.wordpress.com/2008/01/05/desktop/ > , but perhaps there is something different for a web-based set up. > > All I get when I attempt to load a page that uses > ensure_application_is_installed_by_facebook_user is this: > > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:92:in > `verify_signature' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:77:in > `verified_facebook_params' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:24:in > `facebook_params' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in > `secure_with_facebook_params!' > vendor/rails/activesupport/lib/active_support/inflector.rb:260:in > `all?' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in > `each' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in > `all?' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in > `secure_with_facebook_params!' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:15:in > `set_facebook_session' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:130:in > `ensure_authenticated_to_facebook' > vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:135:in > `ensure_application_is_installed_by_facebook_user' > > As far as troubleshooting goes, I started digging into the code, but > quickly realized that without understanding how the Facebook > sessions are expected to function, I couldn't figure out what was > being missed. > > I'd love to start playing around with some of this stuff, so any > help would be appreciated. > > Thanks, > -Phil > > Never miss a thing. Make Yahoo your homepage. > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080126/14452e7b/attachment.html From philipmatarese at yahoo.com Sat Jan 26 18:06:33 2008 From: philipmatarese at yahoo.com (Matarese Philip) Date: Sat, 26 Jan 2008 15:06:33 -0800 (PST) Subject: [Facebooker-talk] Facebooker::Session::IncorrectSignature Message-ID: <94316.36253.qm@web61014.mail.yahoo.com> Ah ha! Thanks Joel, things make a lot more sense now. ----- Original Message ---- From: Joel Nylund To: Matarese Philip Cc: facebooker-talk at rubyforge.org Sent: Saturday, January 26, 2008 5:39:40 PM Subject: Re: [Facebooker-talk] Facebooker::Session::IncorrectSignature Hi, are you going through facebook to get there, I usually get this if I point directly to my rails app, you need to create the face book app on facebook and go to http://apps.facebook.com/yourapp to get to your app with the right stuff to make ensure_application_is_installed_by_facebook_user happy. Joel On Jan 26, 2008, at 5:22 PM, Matarese Philip wrote: I think I must be missing something obvious on this one, but I can't get past the initial "ensure_application_is_installed_by_facebook_user" in a rails app that I'm trying to put together. I'm running on edge rails with the latest Facebooker as a plugin. I've tried adding my settings to the environment configs and recently I tried the new yaml format. The non-facebook parts of the application work fine on their own when ensure_application... is commented out. This is my first attempt at a Facebook app, so I might be messing something up on that side of things as well. I followed the steps inhttp://rfacebook.wordpress.com/2008/01/05/desktop/, but perhaps there is something different for a web-based set up. All I get when I attempt to load a page that uses ensure_application_is_installed_by_facebook_user is this: vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:92:in `verify_signature' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:77:in `verified_facebook_params' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:24:in `facebook_params' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in `secure_with_facebook_params!' vendor/rails/activesupport/lib/active_support/inflector.rb:260:in `all?' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in `each' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in `all?' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in `secure_with_facebook_params!' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:15:in `set_facebook_session' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:130:in `ensure_authenticated_to_facebook' vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:135:in `ensure_application_is_installed_by_facebook_user' As far as troubleshooting goes, I started digging into the code, but quickly realized that without understanding how the Facebook sessions are expected to function, I couldn't figure out what was being missed. I'd love to start playing around with some of this stuff, so any help would be appreciated. Thanks, -Phil Never miss a thing. Make Yahoo your homepage. _______________________________________________ Facebooker-talk mailing list Facebooker-talk at rubyforge.org http://rubyforge.org/mailman/listinfo/facebooker-talk ____________________________________________________________________________________ Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080126/de19ca90/attachment.html From jnylund at yahoo.com Sat Jan 26 18:30:04 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Sat, 26 Jan 2008 18:30:04 -0500 Subject: [Facebooker-talk] Facebooker::Session::IncorrectSignature In-Reply-To: <94316.36253.qm@web61014.mail.yahoo.com> References: <94316.36253.qm@web61014.mail.yahoo.com> Message-ID: your welcome, facebook dev is a big learning curve im still coming up as well, I put a picture of what seems the std arch on my blog a couple days ago,I think its pretty close to correct, it may help understand how it works. http://jnylund.typepad.com/joels_blog/2008/01/facebook-plugin.html Joel On Jan 26, 2008, at 6:06 PM, Matarese Philip wrote: > Ah ha! Thanks Joel, things make a lot more sense now. > > ----- Original Message ---- > From: Joel Nylund > To: Matarese Philip > Cc: facebooker-talk at rubyforge.org > Sent: Saturday, January 26, 2008 5:39:40 PM > Subject: Re: [Facebooker-talk] Facebooker::Session::IncorrectSignature > > Hi, > > are you going through facebook to get there, I usually get this if > I point directly to my rails app, you need to create the face book > app on facebook and go to http://apps.facebook.com/yourapp to get to > your app with the right stuff to make > ensure_application_is_installed_by_facebook_user happy. > > Joel > > On Jan 26, 2008, at 5:22 PM, Matarese Philip wrote: > >> I think I must be missing something obvious on this one, but I >> can't get past the initial >> "ensure_application_is_installed_by_facebook_user" in a rails app >> that I'm trying to put together. I'm running on edge rails with >> the latest Facebooker as a plugin. I've tried adding my settings >> to the environment configs and recently I tried the new yaml >> format. The non-facebook parts of the application work fine on >> their own when ensure_application... is commented out. >> >> This is my first attempt at a Facebook app, so I might be messing >> something up on that side of things as well. I followed the steps >> inhttp://rfacebook.wordpress.com/2008/01/05/desktop/, but perhaps >> there is something different for a web-based set up. >> >> All I get when I attempt to load a page that uses >> ensure_application_is_installed_by_facebook_user is this: >> >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:92:in >> `verify_signature' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:77:in >> `verified_facebook_params' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:24:in >> `facebook_params' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in >> `secure_with_facebook_params!' >> vendor/rails/activesupport/lib/active_support/inflector.rb:260:in >> `all?' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in >> `each' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in >> `all?' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:43:in >> `secure_with_facebook_params!' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:15:in >> `set_facebook_session' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:130:in >> `ensure_authenticated_to_facebook' >> vendor/plugins/facebooker/lib/facebooker/rails/controller.rb:135:in >> `ensure_application_is_installed_by_facebook_user' >> >> As far as troubleshooting goes, I started digging into the code, >> but quickly realized that without understanding how the Facebook >> sessions are expected to function, I couldn't figure out what was >> being missed. >> >> I'd love to start playing around with some of this stuff, so any >> help would be appreciated. >> >> Thanks, >> -Phil >> >> Never miss a thing. Make Yahoo your homepage. >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > > > Never miss a thing. Make Yahoo your homepage. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080126/f19d96f6/attachment-0001.html From jnylund at yahoo.com Sun Jan 27 14:35:24 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Sun, 27 Jan 2008 14:35:24 -0500 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <72A73C7F-D313-4560-883E-E3DE6F8231E5@elevatedrails.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> <1D6F59EB-FF9B-4ED4-88E4-95328754BF63@yahoo.com> <72A73C7F-D313-4560-883E-E3DE6F8231E5@elevatedrails.com> Message-ID: <622F306F-5167-4BA1-B0C9-D64C8C1A7F5C@yahoo.com> Hi Mike, Its going to be a while before we can upgrade to 2.0, we have a large complex system that was built over a year and has dependencies on several plugins that are not ready for 2.0. Also there is at least one critical bug in 2.0 that needs to be addressed before we can go live, I anticipate it being late spring to early summer before we can go. Please, please consider continuing to support 1.x rails at least until mid this year, we were using it on 1.2 until this latest build (the one from a week ago worked ok, other than the routing issues and the complex form helper issues I have noted) The first email has the stack from net/http_multpart_post (see bottom of this mail), is this library included in base ruby, if so which version? (were running 1.8.4 & working on getting to 1.8.6 (it breaks in 1.8.6 in dev) thanks Joel On Jan 26, 2008, at 10:10 AM, Mike Mangino wrote: > Hmm. What error do you get for net/http_multipart_post? That is a > new library that allows you to upload photos to facebook. > > The next error was my fault. I assumed that everybody is running > rails 2.0. That may be the cause of other problems. I'm inclined to > only support rails 2.0 for now. Is anyone using facebooker > successfully on rails 1.2? > > Mike > > On Jan 26, 2008, at 7:17 AM, Joel Nylund wrote: > >> Sorry Shane its not the yml fix thats the problem, its been a week >> since I installed facebooker, >> >> I think its something todo with a previous checkin: >> >> require 'net/http_multipart_post' >> >> Im not sure exactly what the issue is, after I comment this out, I >> get >> this error: >> >> ** Starting Mongrel listening at 0.0.0.0:3001 >> ** Starting Rails with development environment... >> Exiting >> script/../config/../vendor/plugins/facebooker/init.rb:34:in >> `load_plugin_without_engine_additions': undefined method >> `optimise_named_routes=' for ActionController::Base:Class >> (NoMethodError) >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >> `load_plugin_without_engine_additions' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/core_ext/ >> kernel/reporting.rb:11:in `silence_warnings' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >> `load_plugin_without_engine_additions' >> from ./script/../config/../vendor/plugins/engines/lib/engines/ >> rails_extensions/rails_initializer.rb:54:in `load_plugin' >> from ./script/../config/../vendor/plugins/engines/lib/engines/ >> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >> from ./script/../config/../vendor/plugins/engines/lib/engines/ >> rails_extensions/rails_initializer.rb:36:in `each' >> from ./script/../config/../vendor/plugins/engines/lib/engines/ >> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >> from ./script/../config/../vendor/plugins/engines/lib/engines.rb: >> 253:in `after_initialize' >> ... 31 levels... >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >> ruby/1.8/rubygems/custom_require.rb:27:in `require' >> >> >> Joel >> >> >> >> On Jan 26, 2008, at 7:50 AM, Joel Nylund wrote: >> >>> Shane, I upgraded using : >>> >>> script/plugin install http://facebooker.rubyforge.org/svn/trunk/facebooker/ >>> --force >>> >>> removed old env vars from my development.rb >>> added my stuff to facebooker.yml >>> >>> Now when I start my server it will not start: >>> >>> ** Ruby version is up-to-date; cgi_multipart_eof_fix was not loaded >>> ** Starting Mongrel listening at 0.0.0.0:3001 >>> ** Starting Rails with development environment... >>> Exiting >>> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ >>> 1.8/rubygems.rb:249:in `activate': can't activate rails (= 1.2.6), >>> already activated rails-1.2.3] (Gem::Exception) >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/1.8/rubygems/custom_require.rb:31:in `require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>> dependencies.rb:495:in `require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>> dependencies.rb:342:in `new_constants_in' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>> dependencies.rb:495:in `require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/1.8/rubygems/custom_require.rb:27:in `require' >>> from script/server:3 >>> >>> from googling most people say this is related to a missing gem, is >>> there a new gem dependency in this build? >>> >>> thanks >>> Joel >>> >>> >>> >>> On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: >>> >>>> If you are using facebooker as a plugin, you can now have all your >>>> configuration in one place, namely config/facebooker.yml. You can >>>> create this file with rake facebooker:setup. It is also generated >>>> when you install it as a plugin. >>>> >>>> It has a similar setup to database.yml with sections for each >>>> environment. You can also configure your ssh reverse tunnels. >>>> >>>> If you are upgrading, make sure to remove your facebooker specific >>>> setup in your environment files and consolidate them into >>>> facebooker.yml. >>>> >>>> Shane >>>> >>>> -- >>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>> crimsonjet.com >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > From mmangino at elevatedrails.com Sun Jan 27 17:17:40 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Sun, 27 Jan 2008 16:17:40 -0600 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <20080126142033061203.cce67a8d@gmail.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> <1D6F59EB-FF9B-4ED4-88E4-95328754BF63@yahoo.com> <72A73C7F-D313-4560-883E-E3DE6F8231E5@elevatedrails.com> <20080126142033061203.cce67a8d@gmail.com> Message-ID: <3BE8DE87-093A-4AD7-AF90-4E34872C156D@elevatedrails.com> I don't mind supporting Rails 1.2, I just don't run it. Can you guys that are using it send whatever patches are necessary to make it work? Mike On Jan 26, 2008, at 4:20 PM, Shawn Van Ittersum wrote: > Hi Mike, > > Sorry to add more trouble, but some of my clients have not upgraded > to Rails 2.0 yet and may not be able to do so until late Q2 of this > year. Unfortunately, I don't set the upgrade schedule. Given that > 2.0 is still relatively new, I hope you will understand a need to > support 1.x a little while longer. > > Thanks, > Shawn > > On Sat, 26 Jan 2008 09:10:35 -0600, Mike Mangino wrote: >> Hmm. What error do you get for net/http_multipart_post? That is a new >> library that allows you to upload photos to facebook. >> >> The next error was my fault. I assumed that everybody is running >> rails >> 2.0. That may be the cause of other problems. I'm inclined to only >> support rails 2.0 for now. Is anyone using facebooker successfully on >> rails 1.2? >> >> Mike >> >> On Jan 26, 2008, at 7:17 AM, Joel Nylund wrote: >> >>> Sorry Shane its not the yml fix thats the problem, its been a week >>> since I installed facebooker, >>> >>> I think its something todo with a previous checkin: >>> >>> require 'net/http_multipart_post' >>> >>> Im not sure exactly what the issue is, after I comment this out, I >>> get >>> this error: >>> >>> ** Starting Mongrel listening at 0.0.0.0:3001 >>> ** Starting Rails with development environment... >>> Exiting >>> script/../config/../vendor/plugins/facebooker/init.rb:34:in >>> `load_plugin_without_engine_additions': undefined method >>> `optimise_named_routes=' for ActionController::Base:Class >>> (NoMethodError) >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >>> `load_plugin_without_engine_additions' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/core_ext/ >>> kernel/reporting.rb:11:in `silence_warnings' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >>> `load_plugin_without_engine_additions' >>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>> rails_extensions/rails_initializer.rb:54:in `load_plugin' >>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>> rails_extensions/rails_initializer.rb:36:in `each' >>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >>> from ./script/../config/../vendor/plugins/engines/lib/engines.rb: >>> 253:in `after_initialize' >>> ... 31 levels... >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>> lib/ >>> ruby/1.8/rubygems/custom_require.rb:27:in `require' >>> >>> >>> Joel >>> >>> >>> >>> On Jan 26, 2008, at 7:50 AM, Joel Nylund wrote: >>> >>>> Shane, I upgraded using : >>>> >>>> script/plugin install >>>> http://facebooker.rubyforge.org/svn/trunk/facebooker/ >>>> --force >>>> >>>> removed old env vars from my development.rb >>>> added my stuff to facebooker.yml >>>> >>>> Now when I start my server it will not start: >>>> >>>> ** Ruby version is up-to-date; cgi_multipart_eof_fix was not loaded >>>> ** Starting Mongrel listening at 0.0.0.0:3001 >>>> ** Starting Rails with development environment... >>>> Exiting >>>> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>>> ruby/ >>>> 1.8/rubygems.rb:249:in `activate': can't activate rails (= 1.2.6), >>>> already activated rails-1.2.3] (Gem::Exception) >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/1.8/rubygems/custom_require.rb:31:in `require' >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>> dependencies.rb:495:in `require' >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>> dependencies.rb:342:in `new_constants_in' >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>> dependencies.rb:495:in `require' >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/1.8/rubygems/custom_require.rb:27:in `require' >>>> from script/server:3 >>>> >>>> from googling most people say this is related to a missing gem, is >>>> there a new gem dependency in this build? >>>> >>>> thanks >>>> Joel >>>> >>>> >>>> >>>> On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: >>>> >>>>> If you are using facebooker as a plugin, you can now have all your >>>>> configuration in one place, namely config/facebooker.yml. You can >>>>> create this file with rake facebooker:setup. It is also generated >>>>> when you install it as a plugin. >>>>> >>>>> It has a similar setup to database.yml with sections for each >>>>> environment. You can also configure your ssh reverse tunnels. >>>>> >>>>> If you are upgrading, make sure to remove your facebooker specific >>>>> setup in your environment files and consolidate them into >>>>> facebooker.yml. >>>>> >>>>> Shane >>>>> >>>>> -- >>>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>>> crimsonjet.com >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> -- >> Mike Mangino >> http://www.elevatedrails.com >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From jnylund at yahoo.com Sun Jan 27 21:00:47 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Sun, 27 Jan 2008 21:00:47 -0500 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <3BE8DE87-093A-4AD7-AF90-4E34872C156D@elevatedrails.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> <1D6F59EB-FF9B-4ED4-88E4-95328754BF63@yahoo.com> <72A73C7F-D313-4560-883E-E3DE6F8231E5@elevatedrails.com> <20080126142033061203.cce67a8d@gmail.com> <3BE8DE87-093A-4AD7-AF90-4E34872C156D@elevatedrails.com> Message-ID: I can help test stuff, document issues, even write tutorials, but I don't have the experience yet to do much code fixes, im still coming up the learning curve on facebook & rails. for example I spent some time looking around and cant even find anything about net/http_multipart_post, I google it and nothing, dont see any mention of it in ruby or rails api document. Joel On Jan 27, 2008, at 5:17 PM, Mike Mangino wrote: > I don't mind supporting Rails 1.2, I just don't run it. Can you guys > that are using it send whatever patches are necessary to make it work? > > Mike > > On Jan 26, 2008, at 4:20 PM, Shawn Van Ittersum wrote: > >> Hi Mike, >> >> Sorry to add more trouble, but some of my clients have not upgraded >> to Rails 2.0 yet and may not be able to do so until late Q2 of this >> year. Unfortunately, I don't set the upgrade schedule. Given that >> 2.0 is still relatively new, I hope you will understand a need to >> support 1.x a little while longer. >> >> Thanks, >> Shawn >> >> On Sat, 26 Jan 2008 09:10:35 -0600, Mike Mangino wrote: >>> Hmm. What error do you get for net/http_multipart_post? That is a >>> new >>> library that allows you to upload photos to facebook. >>> >>> The next error was my fault. I assumed that everybody is running >>> rails >>> 2.0. That may be the cause of other problems. I'm inclined to only >>> support rails 2.0 for now. Is anyone using facebooker successfully >>> on >>> rails 1.2? >>> >>> Mike >>> >>> On Jan 26, 2008, at 7:17 AM, Joel Nylund wrote: >>> >>>> Sorry Shane its not the yml fix thats the problem, its been a week >>>> since I installed facebooker, >>>> >>>> I think its something todo with a previous checkin: >>>> >>>> require 'net/http_multipart_post' >>>> >>>> Im not sure exactly what the issue is, after I comment this out, >>>> I get >>>> this error: >>>> >>>> ** Starting Mongrel listening at 0.0.0.0:3001 >>>> ** Starting Rails with development environment... >>>> Exiting >>>> script/../config/../vendor/plugins/facebooker/init.rb:34:in >>>> `load_plugin_without_engine_additions': undefined method >>>> `optimise_named_routes=' for ActionController::Base:Class >>>> (NoMethodError) >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >>>> `load_plugin_without_engine_additions' >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/core_ext/ >>>> kernel/reporting.rb:11:in `silence_warnings' >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >>>> `load_plugin_without_engine_additions' >>>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>>> rails_extensions/rails_initializer.rb:54:in `load_plugin' >>>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>>> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >>>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>>> rails_extensions/rails_initializer.rb:36:in `each' >>>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>>> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >>>> from ./script/../config/../vendor/plugins/engines/lib/engines.rb: >>>> 253:in `after_initialize' >>>> ... 31 levels... >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>> lib/ >>>> ruby/1.8/rubygems/custom_require.rb:27:in `require' >>>> >>>> >>>> Joel >>>> >>>> >>>> >>>> On Jan 26, 2008, at 7:50 AM, Joel Nylund wrote: >>>> >>>>> Shane, I upgraded using : >>>>> >>>>> script/plugin install >>>>> http://facebooker.rubyforge.org/svn/trunk/facebooker/ >>>>> --force >>>>> >>>>> removed old env vars from my development.rb >>>>> added my stuff to facebooker.yml >>>>> >>>>> Now when I start my server it will not start: >>>>> >>>>> ** Ruby version is up-to-date; cgi_multipart_eof_fix was not >>>>> loaded >>>>> ** Starting Mongrel listening at 0.0.0.0:3001 >>>>> ** Starting Rails with development environment... >>>>> Exiting >>>>> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ >>>>> ruby/ >>>>> 1.8/rubygems.rb:249:in `activate': can't activate rails (= 1.2.6), >>>>> already activated rails-1.2.3] (Gem::Exception) >>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>>> lib/ >>>>> ruby/1.8/rubygems/custom_require.rb:31:in `require' >>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>>> lib/ >>>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>>> dependencies.rb:495:in `require' >>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>>> lib/ >>>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>>> dependencies.rb:342:in `new_constants_in' >>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>>> lib/ >>>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>>> dependencies.rb:495:in `require' >>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>>> lib/ >>>>> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>>> lib/ >>>>> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>>> lib/ >>>>> ruby/1.8/rubygems/custom_require.rb:27:in `require' >>>>> from script/server:3 >>>>> >>>>> from googling most people say this is related to a missing gem, is >>>>> there a new gem dependency in this build? >>>>> >>>>> thanks >>>>> Joel >>>>> >>>>> >>>>> >>>>> On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: >>>>> >>>>>> If you are using facebooker as a plugin, you can now have all >>>>>> your >>>>>> configuration in one place, namely config/facebooker.yml. You >>>>>> can >>>>>> create this file with rake facebooker:setup. It is also >>>>>> generated >>>>>> when you install it as a plugin. >>>>>> >>>>>> It has a similar setup to database.yml with sections for each >>>>>> environment. You can also configure your ssh reverse tunnels. >>>>>> >>>>>> If you are upgrading, make sure to remove your facebooker >>>>>> specific >>>>>> setup in your environment files and consolidate them into >>>>>> facebooker.yml. >>>>>> >>>>>> Shane >>>>>> >>>>>> -- >>>>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>>>> crimsonjet.com >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>> >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >>> -- >>> Mike Mangino >>> http://www.elevatedrails.com >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > > From jnylund at yahoo.com Mon Jan 28 09:30:52 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Mon, 28 Jan 2008 09:30:52 -0500 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> Message-ID: one question on the facebooker.yml, once I move all the stuff to that file, do I still need this line in the environment file? ActionController::Base.asset_host = "http://myip:myport" its was in the orig readme to add this, but not mentioned in the new yml approach. thanks Joel On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: > If you are using facebooker as a plugin, you can now have all your > configuration in one place, namely config/facebooker.yml. You can > create this file with rake facebooker:setup. It is also generated > when you install it as a plugin. > > It has a similar setup to database.yml with sections for each > environment. You can also configure your ssh reverse tunnels. > > If you are upgrading, make sure to remove your facebooker specific > setup in your environment files and consolidate them into > facebooker.yml. > > Shane > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From shanev at gmail.com Mon Jan 28 13:13:27 2008 From: shanev at gmail.com (Shane Vitarana) Date: Mon, 28 Jan 2008 12:13:27 -0600 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> Message-ID: <4ab757a40801281013q3912b67h9173bfdf11e4d87d@mail.gmail.com> Hey Joel- > one question on the facebooker.yml, once I move all the stuff to that > file, do I still need this line in the environment file? > > ActionController::Base.asset_host = "http://myip:myport" > I added a callback_url field to facebooker.yml. Your asset host by default will be your callback url. You can always override it in your environment files. Shane -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From svicalifornia at gmail.com Mon Jan 28 14:02:54 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Mon, 28 Jan 2008 11:02:54 -0800 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <4ab757a40801281013q3912b67h9173bfdf11e4d87d@mail.gmail.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <4ab757a40801281013q3912b67h9173bfdf11e4d87d@mail.gmail.com> Message-ID: <20080128120254947073.1742d4af@gmail.com> Hi Shane, Per our discussion last night on AIM, I don't think asset_host will properly handle the custom callback_path issue that some of us have. I will be sharing some code tonight to solve the callback_path issues through a new url_rewrite method. The asset_host variable is designed to allow distributed store of assets across multiple hosts with wildcards. The callback_path should not be piggy-backed on asset_host, and because asset_host is for specifying hosts and not paths, I don't believe it will solve the callback_path issue. Thus I suggest that the name of your asset_host configuration variable should be different to avoid confusion with the callback_path variable that I will be adding tonight. Thanks, Shawn On Mon, 28 Jan 2008 12:13:27 -0600, Shane Vitarana wrote: > Hey Joel- > >> one question on the facebooker.yml, once I move all the stuff to that >> file, do I still need this line in the environment file? >> >> ActionController::Base.asset_host = "http://myip:myport" >> > > I added a callback_url field to facebooker.yml. Your asset host by > default will be your callback url. You can always override it in your > environment files. > > Shane > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From mmangino at elevatedrails.com Mon Jan 28 15:04:21 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Mon, 28 Jan 2008 14:04:21 -0600 Subject: [Facebooker-talk] A style question Message-ID: <307CBE50-0EC6-4925-841E-DDF0514792E5@elevatedrails.com> I'm working on the ability to share a single session between Facebook and Non-Facebook requests. Right now, to setup a shared session, you create a link like: <%= link_to "Non-Facebook view",leaders_url(facebook_session_parameters.merge(:canvas=>false))%> The facebook_session_parameters includes all of the necessary info. Is this okay, or would it be better as <%= link_to "Non-Facebook view",leaders_url(:canvas=>false,:share_session=>true)%> I hate to complicate our url_rewriting any more than we have to. Is the :share_session_approach cleaner? Mike -- Mike Mangino http://www.elevatedrails.com From shanev at gmail.com Mon Jan 28 15:58:56 2008 From: shanev at gmail.com (Shane Vitarana) Date: Mon, 28 Jan 2008 14:58:56 -0600 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <20080128120254947073.1742d4af@gmail.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <4ab757a40801281013q3912b67h9173bfdf11e4d87d@mail.gmail.com> <20080128120254947073.1742d4af@gmail.com> Message-ID: <4ab757a40801281258p13649f7ck62b90d79c1d5a1aa@mail.gmail.com> Shawn- Having the asset host be the callback_url by default is what 95% of applications will need. We will address the problem you are having separately. The term "callback path" is not part of the Facebook developer terminology and will confuse things even more. I understand the problem you are having and we'll try to come up with a solution that makes sense and will add the least amount of complexity to facebooker. We may be able to solve it without having to explicity specify the "callback path". Submit your patch to Rubyforge and the developers will take a look at it. Thanks, Shane On Jan 28, 2008 1:02 PM, Shawn Van Ittersum wrote: > Hi Shane, > > Per our discussion last night on AIM, I don't think asset_host will properly handle the custom callback_path issue that some of us have. I will be sharing some code tonight to solve the callback_path issues through a new url_rewrite method. > > The asset_host variable is designed to allow distributed store of assets across multiple hosts with wildcards. The callback_path should not be piggy-backed on asset_host, and because asset_host is for specifying hosts and not paths, I don't believe it will solve the callback_path issue. > > Thus I suggest that the name of your asset_host configuration variable should be different to avoid confusion with the callback_path variable that I will be adding tonight. > > Thanks, > Shawn > > > On Mon, 28 Jan 2008 12:13:27 -0600, Shane Vitarana wrote: > > Hey Joel- > > > >> one question on the facebooker.yml, once I move all the stuff to that > >> file, do I still need this line in the environment file? > >> > >> ActionController::Base.asset_host = "http://myip:myport" > >> > > > > I added a callback_url field to facebooker.yml. Your asset host by > > default will be your callback url. You can always override it in your > > environment files. > > > > Shane > > > > -- > > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From digidigo at gmail.com Mon Jan 28 16:22:26 2008 From: digidigo at gmail.com (David Clements) Date: Mon, 28 Jan 2008 14:22:26 -0700 Subject: [Facebooker-talk] A style question In-Reply-To: <307CBE50-0EC6-4925-841E-DDF0514792E5@elevatedrails.com> References: <307CBE50-0EC6-4925-841E-DDF0514792E5@elevatedrails.com> Message-ID: Hey Mike, Is there anyway that we can make the assumption that if we are currently in the context of a facebook session then we would want to 'share' that session with external requests? Then we could pass a :ignore_facebook_session => true if we don't want the default behavior? Then we won't have special cases checking if you should create a url that shares the session or not. For me , I have a bunch of code that I wrote in order to support an external application as an iframed application within facebook. I did this by continually passing the fb_sig_session_key and rewriting 'url_for' whenever I was in context of a facebook session. Here is the code I am currently using: def url_for(options, *parameters_for_method_reference) if(options && (Hash === options) && context?(:facebook) ) options = options.merge(:context => 'facebook', :fb_sig_session_key => params[:fb_sig_session_key]) end url = (String === options ) ? options : super return url end Dave On Jan 28, 2008 1:04 PM, Mike Mangino wrote: > I'm working on the ability to share a single session between Facebook > and Non-Facebook requests. Right now, to setup a shared session, you > create a link like: > > <%= link_to "Non-Facebook > view",leaders_url(facebook_session_parameters.merge(:canvas=>false))%> > > The facebook_session_parameters includes all of the necessary info. Is > this okay, or would it be better as > > <%= link_to "Non-Facebook > view",leaders_url(:canvas=>false,:share_session=>true)%> > > I hate to complicate our url_rewriting any more than we have to. Is > the :share_session_approach cleaner? > > Mike > > -- > Mike Mangino > http://www.elevatedrails.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From svicalifornia at gmail.com Mon Jan 28 17:06:33 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Mon, 28 Jan 2008 14:06:33 -0800 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <4ab757a40801281258p13649f7ck62b90d79c1d5a1aa@mail.gmail.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <4ab757a40801281013q3912b67h9173bfdf11e4d87d@mail.gmail.com> <20080128120254947073.1742d4af@gmail.com> <4ab757a40801281258p13649f7ck62b90d79c1d5a1aa@mail.gmail.com> Message-ID: <20080128150633156327.60a5bb61@gmail.com> > Having the asset host be the callback_url by default is what 95% of > applications will need. How do you know this? Facebooker does not currently support the case of sandboxing a Facebook app to a Rails controller, so many people have dismissed Facebooker in favor of rfacebook. So their voices have been, up until now, absent on this list. Now that rfacebook is no longer being maintained, we will now see how many people have this use case, and I am sure that it is more than 5%. If you disagree, you are free to poll the thousands of FB developers, but it is not fair to dismiss my use case (and Joel's and Sudara's) with statistics you made up out of thin air. I'm really not trying to start an argument. But the callback_url variable should allow for any callback URL that can be set in the Facebook app settings, including this: Callback URL: http://www.myserver.com/controller/ The fact that asset_host is not intended to handle path information means that it is not the proper way to handle the callback_url setting. I've written code to handle the callback_url correctly and solve all the use cases we have discussed, not just one. I'll submit the code tonight, and after you review it, I hope you'll agree that I've handled the callback_url setting much better than we can by manipulating the asset_host. Shawn On Mon, 28 Jan 2008 14:58:56 -0600, Shane Vitarana wrote: > Shawn- > > Having the asset host be the callback_url by default is what 95% of > applications will need. We will address the problem you are having > separately. The term "callback path" is not part of the Facebook > developer terminology and will confuse things even more. I understand > the problem you are having and we'll try to come up with a solution > that makes sense and will add the least amount of complexity to > facebooker. We may be able to solve it without having to explicity > specify the "callback path". > > Submit your patch to Rubyforge and the developers will take a look at it. > > Thanks, > Shane > > On Jan 28, 2008 1:02 PM, Shawn Van Ittersum wrote: >> Hi Shane, >> >> Per our discussion last night on AIM, I don't think asset_host will >> properly handle the custom callback_path issue that some of us >> have. I will be sharing some code tonight to solve the >> callback_path issues through a new url_rewrite method. >> >> The asset_host variable is designed to allow distributed store of >> assets across multiple hosts with wildcards. The callback_path >> should not be piggy-backed on asset_host, and because asset_host is >> for specifying hosts and not paths, I don't believe it will solve >> the callback_path issue. >> >> Thus I suggest that the name of your asset_host configuration >> variable should be different to avoid confusion with the >> callback_path variable that I will be adding tonight. >> >> Thanks, >> Shawn >> >> >> On Mon, 28 Jan 2008 12:13:27 -0600, Shane Vitarana wrote: >>> Hey Joel- >>> >>>> one question on the facebooker.yml, once I move all the stuff to that >>>> file, do I still need this line in the environment file? >>>> >>>> ActionController::Base.asset_host = "http://myip:myport" >>>> >>> >>> I added a callback_url field to facebooker.yml. Your asset host by >>> default will be your callback url. You can always override it in your >>> environment files. >>> >>> Shane >>> >>> -- >>> http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com >> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> > > > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From digidigo at gmail.com Mon Jan 28 17:28:40 2008 From: digidigo at gmail.com (David Clements) Date: Mon, 28 Jan 2008 15:28:40 -0700 Subject: [Facebooker-talk] Is there a test for setting the session ID to the fb_sig_session_key param? In-Reply-To: References: Message-ID: Hey Mike, I just realized that you might run into the issue that this patch was meant to fix, if you are working on sharing sessions between facebook and web accesible parts of the app. I was hoping that my patch submission was clear enough but perhaps not. Basic problem is that when hitting my app with an fb:iframe tag I do not get my session setup properly. This is because the session code is only looking at request_parameters and not the query_parameters. In this case the request_parameters were empty, since it is a GET request. IM me if that doesn't make sense. This issue only popped up for me when we moved to rails 2.0. Dave On Jan 25, 2008 10:56 AM, Mike Mangino wrote: > I think Michael wrote that code, and we decided that the tests would > be more work than they are worth. Can you explain exactly what problem > you are having? > > Mike > > > On Jan 24, 2008, at 2:32 PM, David Clements wrote: > > > Hey all, > > > > I have a patch that fixes a problem I am having with IFramed pages in > > rails 2.0. I am relying on the session being retrieved via > > fb_sig_session_key. I am looking for the test code that tests this > > functionality but I can't seem to find it. > > > > So you on the list today Chad, gotta pointer for me? > > > > > > Thanks, I want to get a test in for this fix, > > > > Dave > > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > > > From mmangino at elevatedrails.com Mon Jan 28 17:28:55 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Mon, 28 Jan 2008 16:28:55 -0600 Subject: [Facebooker-talk] A style question In-Reply-To: References: <307CBE50-0EC6-4925-841E-DDF0514792E5@elevatedrails.com> Message-ID: <187B4984-E2C3-40BE-88D2-596FB695B55E@elevatedrails.com> The beauty of the current Facebooker stuff is that it only has to happen once. If we include it the first time on external links, Rails will do the right thing afterwards. It seems a little gross to constantly include that link on every :canvas=>false link. Or do others agree with David? Mike On Jan 28, 2008, at 3:22 PM, David Clements wrote: > Hey Mike, > > Is there anyway that we can make the assumption that if we are > currently in the context of a facebook session then we would want to > 'share' that session with external requests? Then we could pass a > :ignore_facebook_session => true if we don't want the default > behavior? > > Then we won't have special cases checking if you should create a url > that shares the session or not. > > For me , I have a bunch of code that I wrote in order to support an > external application as an iframed application within facebook. I did > this by continually passing the fb_sig_session_key and rewriting > 'url_for' whenever I was in context of a facebook session. > > Here is the code I am currently using: > > def url_for(options, *parameters_for_method_reference) > if(options && (Hash === options) && context?(:facebook) ) > options = options.merge(:context => 'facebook', > :fb_sig_session_key => params[:fb_sig_session_key]) > end > url = (String === options ) ? options : super > return url > end > > Dave > > > > On Jan 28, 2008 1:04 PM, Mike Mangino > wrote: >> I'm working on the ability to share a single session between Facebook >> and Non-Facebook requests. Right now, to setup a shared session, you >> create a link like: >> >> <%= link_to "Non-Facebook >> view",leaders_url(facebook_session_parameters.merge(:canvas=>false)) >> %> >> >> The facebook_session_parameters includes all of the necessary info. >> Is >> this okay, or would it be better as >> >> <%= link_to "Non-Facebook >> view",leaders_url(:canvas=>false,:share_session=>true)%> >> >> I hate to complicate our url_rewriting any more than we have to. Is >> the :share_session_approach cleaner? >> >> Mike >> >> -- >> Mike Mangino >> http://www.elevatedrails.com >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> -- Mike Mangino http://www.elevatedrails.com From digidigo at gmail.com Mon Jan 28 17:38:27 2008 From: digidigo at gmail.com (David Clements) Date: Mon, 28 Jan 2008 15:38:27 -0700 Subject: [Facebooker-talk] A style question In-Reply-To: <187B4984-E2C3-40BE-88D2-596FB695B55E@elevatedrails.com> References: <307CBE50-0EC6-4925-841E-DDF0514792E5@elevatedrails.com> <187B4984-E2C3-40BE-88D2-596FB695B55E@elevatedrails.com> Message-ID: I agree with you that the urls become ugly for sure, and I don't really like leaking the session key out on the URL's. So I see both sides of it. If it isn't the default then I will leave my url_for hack in place to keep things less obtrusive for the IFramed app case. There is one issue that I came across when doing this in IFrames. Safari will not set the session cookie for you until the user takes some action within the IFrame. So for me I had to add that url_for hack to all my links so that the session key would be passed along to "whatever" the next action the user took. I will say this as an aside. Being able to keep the facebooker session alive as our users click all around our app within an iframe made a one month task of porting the app to facebook into a 1 week task of reworking the CSS to fit in that little box. So hurray!! for Facebooker. Dave On Jan 28, 2008 3:28 PM, Mike Mangino wrote: > The beauty of the current Facebooker stuff is that it only has to > happen once. If we include it the first time on external links, Rails > will do the right thing afterwards. It seems a little gross to > constantly include that link on every :canvas=>false link. Or do > others agree with David? > > Mike > > > On Jan 28, 2008, at 3:22 PM, David Clements wrote: > > > Hey Mike, > > > > Is there anyway that we can make the assumption that if we are > > currently in the context of a facebook session then we would want to > > 'share' that session with external requests? Then we could pass a > > :ignore_facebook_session => true if we don't want the default > > behavior? > > > > Then we won't have special cases checking if you should create a url > > that shares the session or not. > > > > For me , I have a bunch of code that I wrote in order to support an > > external application as an iframed application within facebook. I did > > this by continually passing the fb_sig_session_key and rewriting > > 'url_for' whenever I was in context of a facebook session. > > > > Here is the code I am currently using: > > > > def url_for(options, *parameters_for_method_reference) > > if(options && (Hash === options) && context?(:facebook) ) > > options = options.merge(:context => 'facebook', > > :fb_sig_session_key => params[:fb_sig_session_key]) > > end > > url = (String === options ) ? options : super > > return url > > end > > > > Dave > > > > > > > > On Jan 28, 2008 1:04 PM, Mike Mangino > > wrote: > >> I'm working on the ability to share a single session between Facebook > >> and Non-Facebook requests. Right now, to setup a shared session, you > >> create a link like: > >> > >> <%= link_to "Non-Facebook > >> view",leaders_url(facebook_session_parameters.merge(:canvas=>false)) > >> %> > >> > >> The facebook_session_parameters includes all of the necessary info. > >> Is > >> this okay, or would it be better as > >> > >> <%= link_to "Non-Facebook > >> view",leaders_url(:canvas=>false,:share_session=>true)%> > >> > >> I hate to complicate our url_rewriting any more than we have to. Is > >> the :share_session_approach cleaner? > >> > >> Mike > >> > >> -- > >> Mike Mangino > >> http://www.elevatedrails.com > >> > >> _______________________________________________ > >> Facebooker-talk mailing list > >> Facebooker-talk at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/facebooker-talk > >> > > -- > Mike Mangino > http://www.elevatedrails.com > > From mmangino at elevatedrails.com Mon Jan 28 17:38:43 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Mon, 28 Jan 2008 16:38:43 -0600 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: <20080128150633156327.60a5bb61@gmail.com> References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <4ab757a40801281013q3912b67h9173bfdf11e4d87d@mail.gmail.com> <20080128120254947073.1742d4af@gmail.com> <4ab757a40801281258p13649f7ck62b90d79c1d5a1aa@mail.gmail.com> <20080128150633156327.60a5bb61@gmail.com> Message-ID: I agree that using asset_host was a dirty hack. I'm glad that Shane has added a better named variable for this. We still will need to use asset_host to make sure that no relative image paths are generated, but I used it where it shouldn't be used. I'll try to update all of the code to use the new value. On Jan 28, 2008, at 4:06 PM, Shawn Van Ittersum wrote: >> Having the asset host be the callback_url by default is what 95% of >> applications will need. > > How do you know this? Facebooker does not currently support the > case of sandboxing a Facebook app to a Rails controller, so many > people have dismissed Facebooker in favor of rfacebook. So their > voices have been, up until now, absent on this list. Now that > rfacebook is no longer being maintained, we will now see how many > people have this use case, and I am sure that it is more than 5%. > If you disagree, you are free to poll the thousands of FB > developers, but it is not fair to dismiss my use case (and Joel's > and Sudara's) with statistics you made up out of thin air. > There's a balancing act here between code complexity and functionality. Until we see your code, it's hard to judge where that falls. In the short term, you can achieve your goal using: map.with_options :conditions=>{:canvas=>true} do |map| map.connect '',:controller=>:facebook map.resources :facebook end map.with_options :conditions=>{:canvas=>false} do |map| #rest of your routes go here end IMNSHO, using a callback url that includes a path is really confusing. I have a hard time understanding how that works within Rails. I'm going to recommend strongly that people don't do that. If this truly is a typical pattern, I would rather create some routing helpers to help with the route generation. Of course, if your fix is elegant and doesn't add complexity, I'm all for it. I'll just wait until I see code. > I'm really not trying to start an argument. But the callback_url > variable should allow for any callback URL that can be set in the > Facebook app settings, including this: > > Callback URL: http://www.myserver.com/controller/ > > The fact that asset_host is not intended to handle path information > means that it is not the proper way to handle the callback_url > setting. I've written code to handle the callback_url correctly and > solve all the use cases we have discussed, not just one. I'll > submit the code tonight, and after you review it, I hope you'll > agree that I've handled the callback_url setting much better than we > can by manipulating the asset_host. > > Shawn > -- Mike Mangino http://www.elevatedrails.com From mmangino at elevatedrails.com Mon Jan 28 17:45:01 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Mon, 28 Jan 2008 16:45:01 -0600 Subject: [Facebooker-talk] Is there a test for setting the session ID to the fb_sig_session_key param? In-Reply-To: References: Message-ID: I hit that too. I have a fix for it locally that I will commit tonight. Mike On Jan 28, 2008, at 4:28 PM, David Clements wrote: > Hey Mike, > > I just realized that you might run into the issue that this patch was > meant to fix, if you are working on sharing sessions between facebook > and web accesible parts of the app. I was hoping that my patch > submission was clear enough but perhaps not. > > Basic problem is that when hitting my app with an fb:iframe tag I do > not get my session setup properly. This is because the session code > is only looking at request_parameters and not the query_parameters. > In this case the request_parameters were empty, since it is a GET > request. > > IM me if that doesn't make sense. This issue only popped up for me > when we moved to rails 2.0. > > Dave > > > On Jan 25, 2008 10:56 AM, Mike Mangino > wrote: >> I think Michael wrote that code, and we decided that the tests would >> be more work than they are worth. Can you explain exactly what >> problem >> you are having? >> >> Mike >> >> >> On Jan 24, 2008, at 2:32 PM, David Clements wrote: >> >>> Hey all, >>> >>> I have a patch that fixes a problem I am having with IFramed pages >>> in >>> rails 2.0. I am relying on the session being retrieved via >>> fb_sig_session_key. I am looking for the test code that tests this >>> functionality but I can't seem to find it. >>> >>> So you on the list today Chad, gotta pointer for me? >>> >>> >>> Thanks, I want to get a test in for this fix, >>> >>> Dave >> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> >> -- >> Mike Mangino >> http://www.elevatedrails.com >> >> >> >> -- Mike Mangino http://www.elevatedrails.com From digidigo at gmail.com Mon Jan 28 17:47:37 2008 From: digidigo at gmail.com (David Clements) Date: Mon, 28 Jan 2008 15:47:37 -0700 Subject: [Facebooker-talk] Is there a test for setting the session ID to the fb_sig_session_key param? In-Reply-To: References: Message-ID: Cool thanks, I'll verify and close out that patch if it solves my problem. Hopefully you found it faster than me, I had too many variables going on. Dave On Jan 28, 2008 3:45 PM, Mike Mangino wrote: > I hit that too. I have a fix for it locally that I will commit tonight. > > Mike > > > On Jan 28, 2008, at 4:28 PM, David Clements wrote: > > > Hey Mike, > > > > I just realized that you might run into the issue that this patch was > > meant to fix, if you are working on sharing sessions between facebook > > and web accesible parts of the app. I was hoping that my patch > > submission was clear enough but perhaps not. > > > > Basic problem is that when hitting my app with an fb:iframe tag I do > > not get my session setup properly. This is because the session code > > is only looking at request_parameters and not the query_parameters. > > In this case the request_parameters were empty, since it is a GET > > request. > > > > IM me if that doesn't make sense. This issue only popped up for me > > when we moved to rails 2.0. > > > > Dave > > > > > > On Jan 25, 2008 10:56 AM, Mike Mangino > > wrote: > >> I think Michael wrote that code, and we decided that the tests would > >> be more work than they are worth. Can you explain exactly what > >> problem > >> you are having? > >> > >> Mike > >> > >> > >> On Jan 24, 2008, at 2:32 PM, David Clements wrote: > >> > >>> Hey all, > >>> > >>> I have a patch that fixes a problem I am having with IFramed pages > >>> in > >>> rails 2.0. I am relying on the session being retrieved via > >>> fb_sig_session_key. I am looking for the test code that tests this > >>> functionality but I can't seem to find it. > >>> > >>> So you on the list today Chad, gotta pointer for me? > >>> > >>> > >>> Thanks, I want to get a test in for this fix, > >>> > >>> Dave > >> > >>> _______________________________________________ > >>> Facebooker-talk mailing list > >>> Facebooker-talk at rubyforge.org > >>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >> > >> -- > >> Mike Mangino > >> http://www.elevatedrails.com > >> > >> > >> > >> > > -- > Mike Mangino > http://www.elevatedrails.com > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > From svicalifornia at gmail.com Mon Jan 28 22:52:58 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Mon, 28 Jan 2008 19:52:58 -0800 Subject: [Facebooker-talk] facebook_url_rewriting.rb Message-ID: <20080128205258613970.8b92ad85@gmail.com> Here's the fix for Facebook apps that specify a controller in their callback URLs. First, set this variable in your environment scripts: ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' # where controller is the name of your Facebook controller And then patch vendor/plugins/facebooker/lib/facebooker/rails/facebook_url_rewriting.rb as shown in the attached diff. Please let me know if you encounter any issues with this patch. Thanks, Shawn -------------- next part -------------- A non-text attachment was scrubbed... Name: diff.out Type: application/octet-stream Size: 750 bytes Desc: not available Url : http://rubyforge.org/pipermail/facebooker-talk/attachments/20080128/07cf36dd/attachment.obj From jnylund at yahoo.com Tue Jan 29 08:58:48 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Tue, 29 Jan 2008 08:58:48 -0500 Subject: [Facebooker-talk] Introducing facebooker.yml In-Reply-To: References: <4ab757a40801252340p741fc4eeje631c31841515c61@mail.gmail.com> <7AAF4BEF-8BDB-4CAF-AA87-D01B094C0607@yahoo.com> <1D6F59EB-FF9B-4ED4-88E4-95328754BF63@yahoo.com> <72A73C7F-D313-4560-883E-E3DE6F8231E5@elevatedrails.com> <20080126142033061203.cce67a8d@gmail.com> <3BE8DE87-093A-4AD7-AF90-4E34872C156D@elevatedrails.com> <07429241-A9A2-4F2E-9DBB-406CC5D88D5C@elevatedrails.com> Message-ID: Looks like I accidently just sent this to Mike, here are the details of the multipart issue I am seeing. Joel On Jan 27, 2008, at 11:02 PM, Joel Nylund wrote: > sure, > > details below, but now that I know where to look, I notice that in > the plugin when I install via the plugin script there are no files > in the net directory. If I checkout from svn the file > (http_multipart_post.rb) is there, I dont totally understand the > magic of the script/plugin install yet, but maybe its messing up > that file and not copying it properly? > > to reproduce: > > rails fbtest > cd fbtest > script/plugin install http://facebooker.rubyforge.org/svn/trunk/facebooker/ > > ruby script/server > > => Booting Mongrel (use 'script/server webrick' to force WEBrick) > => Rails application starting on http://0.0.0.0:3000 > => Call with -d to detach > => Ctrl-C to shutdown server > ** Ruby version is up-to-date; cgi_multipart_eof_fix was not loaded > ** Starting Mongrel listening at 0.0.0.0:3000 > ** Starting Rails with development environment... > Exiting > /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ > gems/1.8/gems/rails-1.2.6/lib/commands/servers/mongrel.rb:15: > warning: already initialized constant OPTIONS > /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ > gems/1.8/gems/rails-1.2.6/lib/commands/servers/mongrel.rb:18: > undefined method `options' for []:Array (NoMethodError) > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:32:in `gem_original_require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:32:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.4/lib/active_support/ > dependencies.rb:495:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.4/lib/active_support/ > dependencies.rb:342:in `new_constants_in' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.4/lib/active_support/ > dependencies.rb:495:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/rails-1.2.6/lib/commands/server.rb:39 > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:27:in `require' > from script/server:3 > > (this is a little different error from my real app, but still caused > by the include of http_multipart_post (If I comment it out, it goes > away) > > > ************************************************* > (my error from the real application is: > > /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/ > 1.8/rubygems.rb:249:in `activate': can't activate rails (= 1.2.6), > already activated rails-1.2.3] (Gem::Exception) > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:31:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ > dependencies.rb:495:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ > dependencies.rb:342:in `new_constants_in' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ > dependencies.rb:495:in `require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' > from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ > ruby/1.8/rubygems/custom_require.rb:27:in `require' > from script/server:3 > > ************************************************* > > > (here is the output from gem -list), im running on ruby version > 1.2.6 that comes with leopard) > > Gems: > actionmailer (1.3.6, 1.3.3) > Service layer for easy email delivery and testing. > > actionpack (1.13.6, 1.13.3) > Web-flow and rendering framework putting the VC in MVC. > > actionwebservice (1.2.6, 1.2.3) > Web service support for Action Pack. > > activerecord (1.15.6, 1.15.3) > Implements the ActiveRecord pattern for ORM. > > activesupport (1.4.4, 1.4.2) > Support and utility classes used by the Rails framework. > > acts_as_ferret (0.4.1) > acts_as_ferret - Ferret based full text search for any ActiveRecord > model > > capistrano (2.0.0) > Capistrano is a utility and framework for executing commands in > parallel on multiple remote machines, via SSH. > > cgi_multipart_eof_fix (2.2) > Fix an exploitable bug in CGI multipart parsing which affects Ruby > <= 1.8.5 when multipart boundary attribute contains a non-halting > regular expression string. > > crypt (1.1.4) > The Crypt library is a pure-ruby implementation of a number of > popular encryption algorithms. Block cyphers currently include > Blowfish, GOST, IDEA, and Rijndael (AES). Cypher Block Chaining > (CBC) has been implemented. Twofish, Serpent, and CAST256 are > planned for release soon. > > daemons (1.0.7) > A toolkit to create and control daemons in different ways > > dnssd (0.6.0) > DNS Service Discovery (aka Rendezvous) API for Ruby > > fastthread (1.0) > Optimized replacement for thread.rb primitives > > fcgi (0.8.7) > FastCGI library for Ruby. > > ferret (0.11.4) > Ruby indexing library. > > gem_plugin (0.2.2) > A plugin system based only on rubygems that uses dependencies only > > highline (1.2.9) > HighLine is a high-level command-line IO library. > > hpricot (0.6) > a swift, liberal HTML parser with a fantastic library > > libxml-ruby (0.3.8.4) > LibXML2 bindings for Ruby > > mocha (0.5.6) > Mocking and stubbing library > > mongrel (1.0.1) > A small fast HTTP library and server that runs Rails, Camping, > Nitro > and Iowa apps. > > mysql (2.7) > MySQL/Ruby provides the same functions for Ruby programs that the > MySQL C API provides for C programs. > > needle (1.3.0) > Needle is a Dependency Injection/Inversion of Control container for > Ruby. It supports both type-2 (setter) and type-3 (constructor) > injection. It takes advantage of the dynamic nature of Ruby to > provide a rich and flexible approach to injecting dependencies. > > net-sftp (1.1.0) > Net::SFTP is a pure-Ruby implementation of the SFTP client > protocol. > > net-ssh (1.1.2) > Net::SSH is a pure-Ruby implementation of the SSH2 client protocol. > > rails (1.2.6, 1.2.3) > Web-application framework with template engine, control-flow layer, > and ORM. > > rake (0.7.3) > Ruby based make-like utility. > > RedCloth (3.0.4) > RedCloth is a module for using Textile and Markdown in Ruby. > Textile > and Markdown are text formats. A very simple text format. Another > stab at making readable text that can be converted to HTML. > > rfacebook (0.9.8) > A Ruby interface to the Facebook API v1.0+. Works with RFacebook > on > Rails plugin (see http://rfacebook.rubyforge.org). > > ruby-openid (1.1.4) > A library for consuming and serving OpenID identities. > > ruby-yadis (0.3.4) > A library for performing Yadis service discovery > > rubynode (0.1.3) > RubyNode is a library that allows read only access to Ruby's > internal NODE structure. > > sources (0.0.1) > This package provides download sources for remote gem installation > > sqlite3-ruby (1.2.1) > SQLite3/Ruby is a module to allow Ruby scripts to interface with a > SQLite3 database. > > termios (0.9.4) > Termios module are simple wrapper for termios(3). It can be > included > into IO-family classes and can extend IO-family objects. In > addition, the methods can use as module function. > > tzinfo (0.3.6) > Daylight-savings aware timezone library > > thanks > Joel > > > > On Jan 27, 2008, at 10:26 PM, Mike Mangino wrote: > >> net/http_multipart_post is in the lib directory. >> >> It isn't part of Ruby, it is part of Facebooker. We'll look at this >> issue tomorrow. Can you create a sample application that >> experiences this problem after install facebooker as a plugin? >> We're running this code base okay in production. I'd love to see a >> detailed stack trace along with the versions of gems you are running. >> >> Mike >> >> >> On Jan 27, 2008, at 8:00 PM, Joel Nylund wrote: >> >>> I can help test stuff, document issues, even write tutorials, but >>> I don't have the experience yet to do much code fixes, im still >>> coming up the learning curve on facebook & rails. >>> >>> for example I spent some time looking around and cant even find >>> anything about net/http_multipart_post, I google it and nothing, >>> dont see any mention of it in ruby or rails api document. >>> >>> Joel >>> >>> On Jan 27, 2008, at 5:17 PM, Mike Mangino wrote: >>> >>>> I don't mind supporting Rails 1.2, I just don't run it. Can you >>>> guys that are using it send whatever patches are necessary to >>>> make it work? >>>> >>>> Mike >>>> >>>> On Jan 26, 2008, at 4:20 PM, Shawn Van Ittersum wrote: >>>> >>>>> Hi Mike, >>>>> >>>>> Sorry to add more trouble, but some of my clients have not >>>>> upgraded to Rails 2.0 yet and may not be able to do so until >>>>> late Q2 of this year. Unfortunately, I don't set the upgrade >>>>> schedule. Given that 2.0 is still relatively new, I hope you >>>>> will understand a need to support 1.x a little while longer. >>>>> >>>>> Thanks, >>>>> Shawn >>>>> >>>>> On Sat, 26 Jan 2008 09:10:35 -0600, Mike Mangino wrote: >>>>>> Hmm. What error do you get for net/http_multipart_post? That is >>>>>> a new >>>>>> library that allows you to upload photos to facebook. >>>>>> >>>>>> The next error was my fault. I assumed that everybody is >>>>>> running rails >>>>>> 2.0. That may be the cause of other problems. I'm inclined to >>>>>> only >>>>>> support rails 2.0 for now. Is anyone using facebooker >>>>>> successfully on >>>>>> rails 1.2? >>>>>> >>>>>> Mike >>>>>> >>>>>> On Jan 26, 2008, at 7:17 AM, Joel Nylund wrote: >>>>>> >>>>>>> Sorry Shane its not the yml fix thats the problem, its been a >>>>>>> week >>>>>>> since I installed facebooker, >>>>>>> >>>>>>> I think its something todo with a previous checkin: >>>>>>> >>>>>>> require 'net/http_multipart_post' >>>>>>> >>>>>>> Im not sure exactly what the issue is, after I comment this >>>>>>> out, I get >>>>>>> this error: >>>>>>> >>>>>>> ** Starting Mongrel listening at 0.0.0.0:3001 >>>>>>> ** Starting Rails with development environment... >>>>>>> Exiting >>>>>>> script/../config/../vendor/plugins/facebooker/init.rb:34:in >>>>>>> `load_plugin_without_engine_additions': undefined method >>>>>>> `optimise_named_routes=' for ActionController::Base:Class >>>>>>> (NoMethodError) >>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>> usr/lib/ >>>>>>> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >>>>>>> `load_plugin_without_engine_additions' >>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>> usr/lib/ >>>>>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>>>>> core_ext/ >>>>>>> kernel/reporting.rb:11:in `silence_warnings' >>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>> usr/lib/ >>>>>>> ruby/gems/1.8/gems/rails-1.2.3/lib/initializer.rb:401:in >>>>>>> `load_plugin_without_engine_additions' >>>>>>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>>>>>> rails_extensions/rails_initializer.rb:54:in `load_plugin' >>>>>>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>>>>>> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >>>>>>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>>>>>> rails_extensions/rails_initializer.rb:36:in `each' >>>>>>> from ./script/../config/../vendor/plugins/engines/lib/engines/ >>>>>>> rails_extensions/rails_initializer.rb:36:in `load_all_plugins' >>>>>>> from ./script/../config/../vendor/plugins/engines/lib/ >>>>>>> engines.rb: >>>>>>> 253:in `after_initialize' >>>>>>> ... 31 levels... >>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>> usr/lib/ >>>>>>> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>> usr/lib/ >>>>>>> ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' >>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>> usr/lib/ >>>>>>> ruby/1.8/rubygems/custom_require.rb:27:in `require' >>>>>>> >>>>>>> >>>>>>> Joel >>>>>>> >>>>>>> >>>>>>> >>>>>>> On Jan 26, 2008, at 7:50 AM, Joel Nylund wrote: >>>>>>> >>>>>>>> Shane, I upgraded using : >>>>>>>> >>>>>>>> script/plugin install >>>>>>>> http://facebooker.rubyforge.org/svn/trunk/facebooker/ >>>>>>>> --force >>>>>>>> >>>>>>>> removed old env vars from my development.rb >>>>>>>> added my stuff to facebooker.yml >>>>>>>> >>>>>>>> Now when I start my server it will not start: >>>>>>>> >>>>>>>> ** Ruby version is up-to-date; cgi_multipart_eof_fix was not >>>>>>>> loaded >>>>>>>> ** Starting Mongrel listening at 0.0.0.0:3001 >>>>>>>> ** Starting Rails with development environment... >>>>>>>> Exiting >>>>>>>> /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/ >>>>>>>> lib/ruby/ >>>>>>>> 1.8/rubygems.rb:249:in `activate': can't activate rails (= >>>>>>>> 1.2.6), >>>>>>>> already activated rails-1.2.3] (Gem::Exception) >>>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>>> usr/lib/ >>>>>>>> ruby/1.8/rubygems/custom_require.rb:31:in `require' >>>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>>> usr/lib/ >>>>>>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>>>>>> dependencies.rb:495:in `require' >>>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>>> usr/lib/ >>>>>>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>>>>>> dependencies.rb:342:in `new_constants_in' >>>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>>> usr/lib/ >>>>>>>> ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/ >>>>>>>> dependencies.rb:495:in `require' >>>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>>> usr/lib/ >>>>>>>> ruby/gems/1.8/gems/rails-1.2.3/lib/commands/server.rb:39 >>>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>>> usr/lib/ >>>>>>>> ruby/1.8/rubygems/custom_require.rb:27:in >>>>>>>> `gem_original_require' >>>>>>>> from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ >>>>>>>> usr/lib/ >>>>>>>> ruby/1.8/rubygems/custom_require.rb:27:in `require' >>>>>>>> from script/server:3 >>>>>>>> >>>>>>>> from googling most people say this is related to a missing >>>>>>>> gem, is >>>>>>>> there a new gem dependency in this build? >>>>>>>> >>>>>>>> thanks >>>>>>>> Joel >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> On Jan 26, 2008, at 2:40 AM, Shane Vitarana wrote: >>>>>>>> >>>>>>>>> If you are using facebooker as a plugin, you can now have >>>>>>>>> all your >>>>>>>>> configuration in one place, namely config/facebooker.yml. >>>>>>>>> You can >>>>>>>>> create this file with rake facebooker:setup. It is also >>>>>>>>> generated >>>>>>>>> when you install it as a plugin. >>>>>>>>> >>>>>>>>> It has a similar setup to database.yml with sections for each >>>>>>>>> environment. You can also configure your ssh reverse tunnels. >>>>>>>>> >>>>>>>>> If you are upgrading, make sure to remove your facebooker >>>>>>>>> specific >>>>>>>>> setup in your environment files and consolidate them into >>>>>>>>> facebooker.yml. >>>>>>>>> >>>>>>>>> Shane >>>>>>>>> >>>>>>>>> -- >>>>>>>>> http://myfitbuddy.com | http://shanesbrain.net | http:// >>>>>>>>> crimsonjet.com >>>>>>>>> _______________________________________________ >>>>>>>>> Facebooker-talk mailing list >>>>>>>>> Facebooker-talk at rubyforge.org >>>>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> Facebooker-talk mailing list >>>>>>>> Facebooker-talk at rubyforge.org >>>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>> >>>>>>> _______________________________________________ >>>>>>> Facebooker-talk mailing list >>>>>>> Facebooker-talk at rubyforge.org >>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>> >>>>>> -- >>>>>> Mike Mangino >>>>>> http://www.elevatedrails.com >>>>>> >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >>>> -- >>>> Mike Mangino >>>> http://www.elevatedrails.com >>>> >>>> >>>> >>> >> >> -- >> Mike Mangino >> http://www.elevatedrails.com >> >> >> > From jnylund at yahoo.com Tue Jan 29 09:06:29 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Tue, 29 Jan 2008 09:06:29 -0500 Subject: [Facebooker-talk] facebooker getting started Message-ID: <51BDE1DC-3A92-468B-BE20-A90481B1D530@yahoo.com> Hi, I posted some steps to getting started with facebooker & rails in my blog, they will likely change when the routing stuff gets settled (Shawns patch gets in). http://jnylund.typepad.com/joels_blog/2008/01/facebooker-gett.html If you want to copy/move this to the new site and modify thats fine with me, just let me know what to do. If there are issues, send them to me and I will fix them right away. thanks Joel From mniessner at elevatedrails.com Tue Jan 29 11:14:22 2008 From: mniessner at elevatedrails.com (Michael Niessner) Date: Tue, 29 Jan 2008 10:14:22 -0600 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: <20080128205258613970.8b92ad85@gmail.com> References: <20080128205258613970.8b92ad85@gmail.com> Message-ID: <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> Or you could do: map.connect '/sandboxed_controller/ sandboxed_controller/:action/:id, :controller => 'sandboxed_controller' where sandboxed_controller is the name of the controller you want to sandbox Michael Niessner On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: > Here's the fix for Facebook apps that specify a controller in their > callback URLs. First, set this variable in your environment scripts: > > ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' > # where controller is the name of your Facebook controller > > And then patch vendor/plugins/facebooker/lib/facebooker/rails/ > facebook_url_rewriting.rb as shown in the attached diff. > > Please let me know if you encounter any issues with this patch. > > Thanks, > Shawn > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From svicalifornia at gmail.com Tue Jan 29 12:19:45 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 29 Jan 2008 09:19:45 -0800 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> Message-ID: <20080129101945834192.5a645951@gmail.com> The correct way to handle this case is to make sure the link URLs are composed correctly in the first place, not to add routing to resolve bad links. Facebooker already includes URL rewriting code; I've merely modified it to generate correct links for the sandbox controller case. Thanks, Shawn On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: > Or you could do: > map.connect '/sandboxed_controller/sandboxed_controller/:action/:id, > :controller => 'sandboxed_controller' > where sandboxed_controller is the name of the controller you want to sandbox > > Michael Niessner > > On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: > >> Here's the fix for Facebook apps that specify a controller in their >> callback URLs. First, set this variable in your environment scripts: >> >> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' >> # where controller is the name of your Facebook controller >> >> And then patch >> vendor/plugins/facebooker/lib/facebooker/rails/facebook_url_rewriting.rb >> as shown in the attached diff. >> >> Please let me know if you encounter any issues with this patch. >> >> Thanks, >> Shawn >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > From mniessner at elevatedrails.com Tue Jan 29 12:30:18 2008 From: mniessner at elevatedrails.com (Michael Niessner) Date: Tue, 29 Jan 2008 11:30:18 -0600 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: <20080129101945834192.5a645951@gmail.com> References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> <20080129101945834192.5a645951@gmail.com> Message-ID: <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> I strongly disagree. Your approach leads to the very poor design decision of placing all facebook actions in a single controller. By using routing you can use multiple controllers in a sandboxed environment. Set your callback_url on facebook to http://yourhost.com/yourapp/sandbox/ Then add the following routes map.connect '/sandbox/controller_1/:action/:id', :controller => 'controller_1' map.connect '/sandbox/controller_2/:action/:id', :controller => 'controller_2' I don't think adding code to facebooker to achieve a limited subset of the functionality that can be obtained by using rails routes is the "correct way" to handle this case. Michael Niessner On Jan 29, 2008, at 11:19 AM, Shawn Van Ittersum wrote: > The correct way to handle this case is to make sure the link URLs > are composed correctly in the first place, not to add routing to > resolve bad links. Facebooker already includes URL rewriting code; > I've merely modified it to generate correct links for the sandbox > controller case. > > Thanks, > Shawn > > On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: >> Or you could do: >> map.connect '/sandboxed_controller/sandboxed_controller/:action/:id, >> :controller => 'sandboxed_controller' >> where sandboxed_controller is the name of the controller you want >> to sandbox >> >> Michael Niessner >> >> On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: >> >>> Here's the fix for Facebook apps that specify a controller in their >>> callback URLs. First, set this variable in your environment >>> scripts: >>> >>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' >>> # where controller is the name of your Facebook controller >>> >>> And then patch >>> vendor/plugins/facebooker/lib/facebooker/rails/ >>> facebook_url_rewriting.rb >>> as shown in the attached diff. >>> >>> Please let me know if you encounter any issues with this patch. >>> >>> Thanks, >>> Shawn >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080129/e5b491e0/attachment.html From mniessner at elevatedrails.com Tue Jan 29 13:44:14 2008 From: mniessner at elevatedrails.com (Michael Niessner) Date: Tue, 29 Jan 2008 12:44:14 -0600 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> <20080129101945834192.5a645951@gmail.com> <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> Message-ID: Actually, the implementation of your patch is probably correct. It's just the intent that is all wrong. If you change ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' to ENV['FACEBOOKER_SANDBOX_NAMESPACE'] = '/namespace' You get the benefits of multiple controllers without having to add a route for each one. Additionally you can take advantage of all the goodness that is map.resources. Also a unit test would be a nice addition to your patch. Michael Niessner On Jan 29, 2008, at 11:30 AM, Michael Niessner wrote: > I strongly disagree. Your approach leads to the very poor design > decision of placing all facebook actions in a single controller. By > using routing you can use multiple controllers in a sandboxed > environment. > > Set your callback_url on facebook to > http://yourhost.com/yourapp/sandbox/ > Then add the following routes > map.connect '/sandbox/controller_1/:action/:id', :controller => > 'controller_1' > map.connect '/sandbox/controller_2/:action/:id', :controller => > 'controller_2' > > I don't think adding code to facebooker to achieve a limited subset > of the functionality that can be obtained by using rails routes is > the "correct way" to handle this case. > > Michael Niessner > > On Jan 29, 2008, at 11:19 AM, Shawn Van Ittersum wrote: > >> The correct way to handle this case is to make sure the link URLs >> are composed correctly in the first place, not to add routing to >> resolve bad links. Facebooker already includes URL rewriting code; >> I've merely modified it to generate correct links for the sandbox >> controller case. >> >> Thanks, >> Shawn >> >> On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: >>> Or you could do: >>> map.connect '/sandboxed_controller/sandboxed_controller/:action/:id, >>> :controller => 'sandboxed_controller' >>> where sandboxed_controller is the name of the controller you want >>> to sandbox >>> >>> Michael Niessner >>> >>> On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: >>> >>>> Here's the fix for Facebook apps that specify a controller in their >>>> callback URLs. First, set this variable in your environment >>>> scripts: >>>> >>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' >>>> # where controller is the name of your Facebook controller >>>> >>>> And then patch >>>> vendor/plugins/facebooker/lib/facebooker/rails/ >>>> facebook_url_rewriting.rb >>>> as shown in the attached diff. >>>> >>>> Please let me know if you encounter any issues with this patch. >>>> >>>> Thanks, >>>> Shawn >>>> _______________________________________________ >>>> Facebooker-talk mailing list >>>> Facebooker-talk at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/facebooker-talk/attachments/20080129/900a1d0d/attachment.html From bjclark at scidept.com Tue Jan 29 14:02:53 2008 From: bjclark at scidept.com (BJ Clark) Date: Tue, 29 Jan 2008 12:02:53 -0700 Subject: [Facebooker-talk] Off Loading tasks to Background.rb Message-ID: <042DBAAA-009C-4B2A-956B-43D8CCE0FC86@scidept.com> Didn't someone mention that they were using background.rb to move some of the api calls to a background process? Can they explain what they are doing a little further? I think it was Mike, but I can't find the message in my archives. Thanks, ----- BJ Clark the science department bjclark at scidept.com www.scidept.com From digidigo at gmail.com Tue Jan 29 14:04:20 2008 From: digidigo at gmail.com (David Clements) Date: Tue, 29 Jan 2008 12:04:20 -0700 Subject: [Facebooker-talk] Facebook Redirects to Callback Path after log in Message-ID: Hey, I am wondering if anyone has run into this issue before. I can't seem to figure out what Facebook is doing. I have an application that only requires Facebook Authentication, the user doesn't need to "add" the app. So at the top of my main controller I have class GettingStartedController < ApplicationController ensure_authenticated_to_facebook ...... end I hit the app and get this URL http://www.facebook.com/tos.php?api_key=442c6504bd2362d8a7fba7303cd583ca&next=&v=1.0# After I get the log in screen facebook sends a redirect to the CALLBACK path http://staging.travelerstable.com:8888/?auth_token=8a83bf3c4f33b5cb16d423c292663c59 Anyone else see this? I don't think it has anything to do with Facebooker, or does it? If you look in the tos url you can see next= , I wonder what that is for. Dave From svicalifornia at gmail.com Tue Jan 29 14:12:58 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 29 Jan 2008 11:12:58 -0800 Subject: [Facebooker-talk] Facebook Redirects to Callback Path after log in In-Reply-To: References: Message-ID: <20080129121258772834.b2bdb60f@gmail.com> I think I've seen this with IFRAME apps... I forget what caused it or how to mitigate. Anyone else? Shawn On Tue, 29 Jan 2008 12:04:20 -0700, David Clements wrote: > Hey, > > I am wondering if anyone has run into this issue before. I can't seem > to figure out what Facebook is doing. > > I have an application that only requires Facebook Authentication, the > user doesn't need to "add" the app. So at the top of my main > controller I have > > > class GettingStartedController < ApplicationController > ensure_authenticated_to_facebook > ...... > > > end > > I hit the app and get this URL > > http://www.facebook.com/tos.php?api_key=442c6504bd2362d8a7fba7303cd583ca&next=&v=1.0# > > > After I get the log in screen facebook sends a redirect to the CALLBACK path > > http://staging.travelerstable.com:8888/?auth_token=8a83bf3c4f33b5cb16d423c292663c59 > > Anyone else see this? I don't think it has anything to do with > Facebooker, or does it? If you look in the tos url you can see next= > , I wonder what that is for. > > Dave > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From heavysixer at gmail.com Tue Jan 29 14:19:45 2008 From: heavysixer at gmail.com (Heavy Sixer) Date: Tue, 29 Jan 2008 13:19:45 -0600 Subject: [Facebooker-talk] Facebook Redirects to Callback Path after log in In-Reply-To: <20080129121258772834.b2bdb60f@gmail.com> References: <20080129121258772834.b2bdb60f@gmail.com> Message-ID: <1BB59437-081B-4DAD-9DE9-AD5708712BA4@gmail.com> Facebook does not "follow" the link the user originally clicked when they tripped the "login" filter. Once the user has been logged in however that link will work as expected. The way that I got around this was adding a before_filter in my application.rb file looking for the auth_token and then just redirecting it on to my facebook controller. Mark On Jan 29, 2008, at 1:12 PM, Shawn Van Ittersum wrote: > I think I've seen this with IFRAME apps... I forget what caused it > or how to mitigate. Anyone else? > > Shawn > > On Tue, 29 Jan 2008 12:04:20 -0700, David Clements wrote: >> Hey, >> >> I am wondering if anyone has run into this issue before. I can't >> seem >> to figure out what Facebook is doing. >> >> I have an application that only requires Facebook Authentication, the >> user doesn't need to "add" the app. So at the top of my main >> controller I have >> >> >> class GettingStartedController < ApplicationController >> ensure_authenticated_to_facebook >> ...... >> >> >> end >> >> I hit the app and get this URL >> >> http://www.facebook.com/tos.php? >> api_key=442c6504bd2362d8a7fba7303cd583ca&next=&v=1.0# >> >> >> After I get the log in screen facebook sends a redirect to the >> CALLBACK path >> >> http://staging.travelerstable.com:8888/? >> auth_token=8a83bf3c4f33b5cb16d423c292663c59 >> >> Anyone else see this? I don't think it has anything to do with >> Facebooker, or does it? If you look in the tos url you can see next= >> , I wonder what that is for. >> >> Dave >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From svicalifornia at gmail.com Tue Jan 29 14:20:45 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 29 Jan 2008 11:20:45 -0800 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> <20080129101945834192.5a645951@gmail.com> <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> Message-ID: <20080129122045533499.e1089f89@gmail.com> Hi Michael, I agree with you about namespaces. To be clear, my example code was only one possible implementation. My patch is not intended to force sandboxing to one controller only, but rather to any namespace desired by the developer. I would still like to keep the config variable named FACEBOOKER_CALLBACK_PATH, as it relates directly to the Facebook callback URL setting. So to update the example: ENV['FACEBOOKER_CALLBACK_PATH'] = '/namespace' # where Facebook Developer callback url = http://yourserver.com:port/namespace Shawn On Tue, 29 Jan 2008 12:44:14 -0600, Michael Niessner wrote: > Actually, the implementation of your patch is probably correct. It's > just the intent that is all wrong. If you change > > ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' to > ENV['FACEBOOKER_SANDBOX_NAMESPACE'] = '/namespace' > > You get the benefits of multiple controllers without having to add a > route for each one. Additionally you can take advantage of all the > goodness that is map.resources. > > Also a unit test would be a nice addition to your patch. > > Michael Niessner > > > On Jan 29, 2008, at 11:30 AM, Michael Niessner wrote: >> I strongly disagree. Your approach leads to the very poor design >> decision of placing all facebook actions in a single controller. By >> using routing you can use multiple controllers in a sandboxed >> environment. >> >> Set your callback_url on facebook to >> http://yourhost.com/yourapp/sandbox/ >> Then add the following routes >> map.connect '/sandbox/controller_1/:action/:id', :controller => >> 'controller_1' >> map.connect '/sandbox/controller_2/:action/:id', :controller => >> 'controller_2' >> >> I don't think adding code to facebooker to achieve a limited subset >> of the functionality that can be obtained by using rails routes is >> the "correct way" to handle this case. >> >> Michael Niessner >> >> On Jan 29, 2008, at 11:19 AM, Shawn Van Ittersum wrote: >>> The correct way to handle this case is to make sure the link URLs >>> are composed correctly in the first place, not to add routing to >>> resolve bad links. Facebooker already includes URL rewriting code; >>> I've merely modified it to generate correct links for the sandbox >>> controller case. >>> >>> Thanks, >>> Shawn >>> >>> On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: >>>> Or you could do: >>>> map.connect '/sandboxed_controller/sandboxed_controller/:action/:id, >>>> :controller => 'sandboxed_controller' >>>> where sandboxed_controller is the name of the controller you want >>>> to sandbox >>>> >>>> Michael Niessner >>>> >>>> On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: >>>> >>>>> Here's the fix for Facebook apps that specify a controller in their >>>>> callback URLs. First, set this variable in your environment scripts: >>>>> >>>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' >>>>> # where controller is the name of your Facebook controller >>>>> >>>>> And then patch >>>>> vendor/plugins/facebooker/lib/facebooker/rails/facebook_url_rewriting.rb >>>>> as shown in the attached diff. >>>>> >>>>> Please let me know if you encounter any issues with this patch. >>>>> >>>>> Thanks, >>>>> Shawn >>>>> _______________________________________________ >>>>> Facebooker-talk mailing list >>>>> Facebooker-talk at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>> >> > From mniessner at elevatedrails.com Tue Jan 29 14:28:41 2008 From: mniessner at elevatedrails.com (Michael Niessner) Date: Tue, 29 Jan 2008 13:28:41 -0600 Subject: [Facebooker-talk] Facebook Redirects to Callback Path after log in In-Reply-To: <1BB59437-081B-4DAD-9DE9-AD5708712BA4@gmail.com> References: <20080129121258772834.b2bdb60f@gmail.com> <1BB59437-081B-4DAD-9DE9-AD5708712BA4@gmail.com> Message-ID: If you guys want to redirect to the original request after login just add the following to your application controller. def application_is_not_installed_by_facebook_user redirect_to session[:facebook_session].install_url(:next => "#{request.request_uri}") end On Jan 29, 2008, at 1:19 PM, Heavy Sixer wrote: > Facebook does not "follow" the link the user originally clicked when > they tripped the "login" filter. Once the user has been logged in > however that link will work as expected. The way that I got around > this was adding a before_filter in my application.rb file looking for > the auth_token and then just redirecting it on to my facebook > controller. > > Mark > > > On Jan 29, 2008, at 1:12 PM, Shawn Van Ittersum wrote: > >> I think I've seen this with IFRAME apps... I forget what caused it >> or how to mitigate. Anyone else? >> >> Shawn >> >> On Tue, 29 Jan 2008 12:04:20 -0700, David Clements wrote: >>> Hey, >>> >>> I am wondering if anyone has run into this issue before. I can't >>> seem >>> to figure out what Facebook is doing. >>> >>> I have an application that only requires Facebook Authentication, >>> the >>> user doesn't need to "add" the app. So at the top of my main >>> controller I have >>> >>> >>> class GettingStartedController < ApplicationController >>> ensure_authenticated_to_facebook >>> ...... >>> >>> >>> end >>> >>> I hit the app and get this URL >>> >>> http://www.facebook.com/tos.php? >>> api_key=442c6504bd2362d8a7fba7303cd583ca&next=&v=1.0# >>> >>> >>> After I get the log in screen facebook sends a redirect to the >>> CALLBACK path >>> >>> http://staging.travelerstable.com:8888/? >>> auth_token=8a83bf3c4f33b5cb16d423c292663c59 >>> >>> Anyone else see this? I don't think it has anything to do with >>> Facebooker, or does it? If you look in the tos url you can see >>> next= >>> , I wonder what that is for. >>> >>> Dave >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From mniessner at elevatedrails.com Tue Jan 29 15:00:13 2008 From: mniessner at elevatedrails.com (Michael Niessner) Date: Tue, 29 Jan 2008 14:00:13 -0600 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: <20080129122045533499.e1089f89@gmail.com> References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> <20080129101945834192.5a645951@gmail.com> <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> <20080129122045533499.e1089f89@gmail.com> Message-ID: I feel mixed about the name. I like that callback_path translates to the path component of your callback url. I like that sandbox_namespace signals an intention to sandbox the app using a namespace, providing guidance of how to use the setting. I prefer whichever name people would have an easier time understanding. Maybe a few others on the list could chime in? Michael Niessner On Jan 29, 2008, at 1:20 PM, Shawn Van Ittersum wrote: > Hi Michael, > > I agree with you about namespaces. To be clear, my example code was > only one possible implementation. My patch is not intended to force > sandboxing to one controller only, but rather to any namespace > desired by the developer. I would still like to keep the config > variable named FACEBOOKER_CALLBACK_PATH, as it relates directly to > the Facebook callback URL setting. So to update the example: > > ENV['FACEBOOKER_CALLBACK_PATH'] = '/namespace' > # where Facebook Developer callback url = http://yourserver.com:port/ > namespace > > Shawn > > On Tue, 29 Jan 2008 12:44:14 -0600, Michael Niessner wrote: >> Actually, the implementation of your patch is probably correct. It's >> just the intent that is all wrong. If you change >> >> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' to >> ENV['FACEBOOKER_SANDBOX_NAMESPACE'] = '/namespace' >> >> You get the benefits of multiple controllers without having to add a >> route for each one. Additionally you can take advantage of all the >> goodness that is map.resources. >> >> Also a unit test would be a nice addition to your patch. >> >> Michael Niessner >> >> >> On Jan 29, 2008, at 11:30 AM, Michael Niessner wrote: >>> I strongly disagree. Your approach leads to the very poor design >>> decision of placing all facebook actions in a single controller. By >>> using routing you can use multiple controllers in a sandboxed >>> environment. >>> >>> Set your callback_url on facebook to >>> http://yourhost.com/yourapp/sandbox/ >>> Then add the following routes >>> map.connect '/sandbox/controller_1/:action/:id', :controller => >>> 'controller_1' >>> map.connect '/sandbox/controller_2/:action/:id', :controller => >>> 'controller_2' >>> >>> I don't think adding code to facebooker to achieve a limited subset >>> of the functionality that can be obtained by using rails routes is >>> the "correct way" to handle this case. >>> >>> Michael Niessner >>> >>> On Jan 29, 2008, at 11:19 AM, Shawn Van Ittersum wrote: >>>> The correct way to handle this case is to make sure the link URLs >>>> are composed correctly in the first place, not to add routing to >>>> resolve bad links. Facebooker already includes URL rewriting code; >>>> I've merely modified it to generate correct links for the sandbox >>>> controller case. >>>> >>>> Thanks, >>>> Shawn >>>> >>>> On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: >>>>> Or you could do: >>>>> map.connect '/sandboxed_controller/ >>>>> sandboxed_controller/:action/:id, >>>>> :controller => 'sandboxed_controller' >>>>> where sandboxed_controller is the name of the controller you want >>>>> to sandbox >>>>> >>>>> Michael Niessner >>>>> >>>>> On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: >>>>> >>>>>> Here's the fix for Facebook apps that specify a controller in >>>>>> their >>>>>> callback URLs. First, set this variable in your environment >>>>>> scripts: >>>>>> >>>>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' >>>>>> # where controller is the name of your Facebook controller >>>>>> >>>>>> And then patch >>>>>> vendor/plugins/facebooker/lib/facebooker/rails/ >>>>>> facebook_url_rewriting.rb >>>>>> as shown in the attached diff. >>>>>> >>>>>> Please let me know if you encounter any issues with this patch. >>>>>> >>>>>> Thanks, >>>>>> Shawn >>>>>> _______________________________________________ >>>>>> Facebooker-talk mailing list >>>>>> Facebooker-talk at rubyforge.org >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>> >>> >> From mmangino at elevatedrails.com Tue Jan 29 15:03:14 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Tue, 29 Jan 2008 14:03:14 -0600 Subject: [Facebooker-talk] Off Loading tasks to Background.rb In-Reply-To: <042DBAAA-009C-4B2A-956B-43D8CCE0FC86@scidept.com> References: <042DBAAA-009C-4B2A-956B-43D8CCE0FC86@scidept.com> Message-ID: We're using stomp queues. We place messages into a queue and a backend processes them. I think Shane is using ap4r in a similar way. Unfortunately, that's code that I can't share. Mike On Jan 29, 2008, at 1:02 PM, BJ Clark wrote: > Didn't someone mention that they were using background.rb to move some > of the api calls to a background process? > Can they explain what they are doing a little further? > I think it was Mike, but I can't find the message in my archives. > > Thanks, > ----- > BJ Clark > the science department > bjclark at scidept.com > www.scidept.com > > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From svicalifornia at gmail.com Tue Jan 29 15:56:25 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 29 Jan 2008 12:56:25 -0800 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: <511B0893-F144-4FEA-B938-199C635AB495@gmail.com> References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> <20080129101945834192.5a645951@gmail.com> <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> <20080129122045533499.e1089f89@gmail.com> <511B0893-F144-4FEA-B938-199C635AB495@gmail.com> Message-ID: <20080129135625725217.d7914824@gmail.com> I think that CALLBACK_PATH is the clearer variable name for the reason you mentioned, and that we should explain the namespace use of this variable in the documentation, with a couple examples. I'm happy to cover that as we build out the docs, which are in progress. Shawn On Tue, 29 Jan 2008 13:59:26 -0600, Michael Niessner wrote: > I feel mixed about the name. I like that callback_path translates to > the path component of your callback url. I like that > sandbox_namespace signals an intention to sandbox the app using a > namespace, providing guidance of how to use the setting. I prefer > whichever name people would have an easier time understanding. Maybe > a few others on the list could chime in? > > Michael Niessner > > On Jan 29, 2008, at 1:20 PM, Shawn Van Ittersum wrote: > >> Hi Michael, >> >> I agree with you about namespaces. To be clear, my example code was >> only one possible implementation. My patch is not intended to force >> sandboxing to one controller only, but rather to any namespace >> desired by the developer. I would still like to keep the config >> variable named FACEBOOKER_CALLBACK_PATH, as it relates directly to >> the Facebook callback URL setting. So to update the example: >> >> ENV['FACEBOOKER_CALLBACK_PATH'] = '/namespace' >> # where Facebook Developer callback url = >> http://yourserver.com:port/namespace >> >> Shawn >> >> On Tue, 29 Jan 2008 12:44:14 -0600, Michael Niessner wrote: >>> Actually, the implementation of your patch is probably correct. It's >>> just the intent that is all wrong. If you change >>> >>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' to >>> ENV['FACEBOOKER_SANDBOX_NAMESPACE'] = '/namespace' >>> >>> You get the benefits of multiple controllers without having to add a >>> route for each one. Additionally you can take advantage of all the >>> goodness that is map.resources. >>> >>> Also a unit test would be a nice addition to your patch. >>> >>> Michael Niessner >>> >>> >>> On Jan 29, 2008, at 11:30 AM, Michael Niessner wrote: >>>> I strongly disagree. Your approach leads to the very poor design >>>> decision of placing all facebook actions in a single controller. By >>>> using routing you can use multiple controllers in a sandboxed >>>> environment. >>>> >>>> Set your callback_url on facebook to >>>> http://yourhost.com/yourapp/sandbox/ >>>> Then add the following routes >>>> map.connect '/sandbox/controller_1/:action/:id', :controller => >>>> 'controller_1' >>>> map.connect '/sandbox/controller_2/:action/:id', :controller => >>>> 'controller_2' >>>> >>>> I don't think adding code to facebooker to achieve a limited subset >>>> of the functionality that can be obtained by using rails routes is >>>> the "correct way" to handle this case. >>>> >>>> Michael Niessner >>>> >>>> On Jan 29, 2008, at 11:19 AM, Shawn Van Ittersum wrote: >>>>> The correct way to handle this case is to make sure the link URLs >>>>> are composed correctly in the first place, not to add routing to >>>>> resolve bad links. Facebooker already includes URL rewriting code; >>>>> I've merely modified it to generate correct links for the sandbox >>>>> controller case. >>>>> >>>>> Thanks, >>>>> Shawn >>>>> >>>>> On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: >>>>>> Or you could do: >>>>>> map.connect '/sandboxed_controller/sandboxed_controller/:action/:id, >>>>>> :controller => 'sandboxed_controller' >>>>>> where sandboxed_controller is the name of the controller you want >>>>>> to sandbox >>>>>> >>>>>> Michael Niessner >>>>>> >>>>>> On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: >>>>>> >>>>>>> Here's the fix for Facebook apps that specify a controller in their >>>>>>> callback URLs. First, set this variable in your environment scripts: >>>>>>> >>>>>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' >>>>>>> # where controller is the name of your Facebook controller >>>>>>> >>>>>>> And then patch >>>>>>> vendor/plugins/facebooker/lib/facebooker/rails/facebook_url_rewriting.rb >>>>>>> as shown in the attached diff. >>>>>>> >>>>>>> Please let me know if you encounter any issues with this patch. >>>>>>> >>>>>>> Thanks, >>>>>>> Shawn >>>>>>> _______________________________________________ >>>>>>> Facebooker-talk mailing list >>>>>>> Facebooker-talk at rubyforge.org >>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>> >>>> >>> > From shanev at gmail.com Tue Jan 29 16:10:34 2008 From: shanev at gmail.com (Shane Vitarana) Date: Tue, 29 Jan 2008 15:10:34 -0600 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> <20080129101945834192.5a645951@gmail.com> <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> <20080129122045533499.e1089f89@gmail.com> Message-ID: <4ab757a40801291310g7c0815fejb2b10f4fd832336b@mail.gmail.com> What about just keeping callback_url, and assume the /path/ component is a namespace? Shane On Jan 29, 2008 2:00 PM, Michael Niessner wrote: > I feel mixed about the name. I like that callback_path translates to > the path component of your callback url. I like that sandbox_namespace > signals an intention to sandbox the app using a namespace, providing > guidance of how to use the setting. I prefer whichever name people > would have an easier time understanding. Maybe a few others on the > list could chime in? > > Michael Niessner > > > On Jan 29, 2008, at 1:20 PM, Shawn Van Ittersum wrote: > > > Hi Michael, > > > > I agree with you about namespaces. To be clear, my example code was > > only one possible implementation. My patch is not intended to force > > sandboxing to one controller only, but rather to any namespace > > desired by the developer. I would still like to keep the config > > variable named FACEBOOKER_CALLBACK_PATH, as it relates directly to > > the Facebook callback URL setting. So to update the example: > > > > ENV['FACEBOOKER_CALLBACK_PATH'] = '/namespace' > > # where Facebook Developer callback url = http://yourserver.com:port/ > > namespace > > > > Shawn > > > > On Tue, 29 Jan 2008 12:44:14 -0600, Michael Niessner wrote: > >> Actually, the implementation of your patch is probably correct. It's > >> just the intent that is all wrong. If you change > >> > >> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' to > >> ENV['FACEBOOKER_SANDBOX_NAMESPACE'] = '/namespace' > >> > >> You get the benefits of multiple controllers without having to add a > >> route for each one. Additionally you can take advantage of all the > >> goodness that is map.resources. > >> > >> Also a unit test would be a nice addition to your patch. > >> > >> Michael Niessner > >> > >> > >> On Jan 29, 2008, at 11:30 AM, Michael Niessner wrote: > >>> I strongly disagree. Your approach leads to the very poor design > >>> decision of placing all facebook actions in a single controller. By > >>> using routing you can use multiple controllers in a sandboxed > >>> environment. > >>> > >>> Set your callback_url on facebook to > >>> http://yourhost.com/yourapp/sandbox/ > >>> Then add the following routes > >>> map.connect '/sandbox/controller_1/:action/:id', :controller => > >>> 'controller_1' > >>> map.connect '/sandbox/controller_2/:action/:id', :controller => > >>> 'controller_2' > >>> > >>> I don't think adding code to facebooker to achieve a limited subset > >>> of the functionality that can be obtained by using rails routes is > >>> the "correct way" to handle this case. > >>> > >>> Michael Niessner > >>> > >>> On Jan 29, 2008, at 11:19 AM, Shawn Van Ittersum wrote: > >>>> The correct way to handle this case is to make sure the link URLs > >>>> are composed correctly in the first place, not to add routing to > >>>> resolve bad links. Facebooker already includes URL rewriting code; > >>>> I've merely modified it to generate correct links for the sandbox > >>>> controller case. > >>>> > >>>> Thanks, > >>>> Shawn > >>>> > >>>> On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: > >>>>> Or you could do: > >>>>> map.connect '/sandboxed_controller/ > >>>>> sandboxed_controller/:action/:id, > >>>>> :controller => 'sandboxed_controller' > >>>>> where sandboxed_controller is the name of the controller you want > >>>>> to sandbox > >>>>> > >>>>> Michael Niessner > >>>>> > >>>>> On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: > >>>>> > >>>>>> Here's the fix for Facebook apps that specify a controller in > >>>>>> their > >>>>>> callback URLs. First, set this variable in your environment > >>>>>> scripts: > >>>>>> > >>>>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' > >>>>>> # where controller is the name of your Facebook controller > >>>>>> > >>>>>> And then patch > >>>>>> vendor/plugins/facebooker/lib/facebooker/rails/ > >>>>>> facebook_url_rewriting.rb > >>>>>> as shown in the attached diff. > >>>>>> > >>>>>> Please let me know if you encounter any issues with this patch. > >>>>>> > >>>>>> Thanks, > >>>>>> Shawn > >>>>>> _______________________________________________ > >>>>>> Facebooker-talk mailing list > >>>>>> Facebooker-talk at rubyforge.org > >>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk > >>>>> > >>> > >> > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From mniessner at elevatedrails.com Tue Jan 29 16:32:10 2008 From: mniessner at elevatedrails.com (Michael Niessner) Date: Tue, 29 Jan 2008 15:32:10 -0600 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: <4ab757a40801291310g7c0815fejb2b10f4fd832336b@mail.gmail.com> References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> <20080129101945834192.5a645951@gmail.com> <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> <20080129122045533499.e1089f89@gmail.com> <4ab757a40801291310g7c0815fejb2b10f4fd832336b@mail.gmail.com> Message-ID: Shane's idea is the winner. When facebooker.yml parses callback_url it can put the host component in where it currently does and stuff the path into ENV['FACEBOOKER_SANDBOX_NAMESPACE']. Then developers only need to copy their callback_url into callback_url of facebooker.yml. Michael Niessner On Jan 29, 2008, at 3:10 PM, Shane Vitarana wrote: > What about just keeping callback_url, and assume the /path/ component > is a namespace? > > Shane > > On Jan 29, 2008 2:00 PM, Michael Niessner > wrote: >> I feel mixed about the name. I like that callback_path translates to >> the path component of your callback url. I like that >> sandbox_namespace >> signals an intention to sandbox the app using a namespace, providing >> guidance of how to use the setting. I prefer whichever name people >> would have an easier time understanding. Maybe a few others on the >> list could chime in? >> >> Michael Niessner >> >> >> On Jan 29, 2008, at 1:20 PM, Shawn Van Ittersum wrote: >> >>> Hi Michael, >>> >>> I agree with you about namespaces. To be clear, my example code was >>> only one possible implementation. My patch is not intended to force >>> sandboxing to one controller only, but rather to any namespace >>> desired by the developer. I would still like to keep the config >>> variable named FACEBOOKER_CALLBACK_PATH, as it relates directly to >>> the Facebook callback URL setting. So to update the example: >>> >>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/namespace' >>> # where Facebook Developer callback url = http:// >>> yourserver.com:port/ >>> namespace >>> >>> Shawn >>> >>> On Tue, 29 Jan 2008 12:44:14 -0600, Michael Niessner wrote: >>>> Actually, the implementation of your patch is probably correct. >>>> It's >>>> just the intent that is all wrong. If you change >>>> >>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' to >>>> ENV['FACEBOOKER_SANDBOX_NAMESPACE'] = '/namespace' >>>> >>>> You get the benefits of multiple controllers without having to >>>> add a >>>> route for each one. Additionally you can take advantage of all the >>>> goodness that is map.resources. >>>> >>>> Also a unit test would be a nice addition to your patch. >>>> >>>> Michael Niessner >>>> >>>> >>>> On Jan 29, 2008, at 11:30 AM, Michael Niessner wrote: >>>>> I strongly disagree. Your approach leads to the very poor design >>>>> decision of placing all facebook actions in a single controller. >>>>> By >>>>> using routing you can use multiple controllers in a sandboxed >>>>> environment. >>>>> >>>>> Set your callback_url on facebook to >>>>> http://yourhost.com/yourapp/sandbox/ >>>>> Then add the following routes >>>>> map.connect '/sandbox/controller_1/:action/:id', :controller => >>>>> 'controller_1' >>>>> map.connect '/sandbox/controller_2/:action/:id', :controller => >>>>> 'controller_2' >>>>> >>>>> I don't think adding code to facebooker to achieve a limited >>>>> subset >>>>> of the functionality that can be obtained by using rails routes is >>>>> the "correct way" to handle this case. >>>>> >>>>> Michael Niessner >>>>> >>>>> On Jan 29, 2008, at 11:19 AM, Shawn Van Ittersum wrote: >>>>>> The correct way to handle this case is to make sure the link URLs >>>>>> are composed correctly in the first place, not to add routing to >>>>>> resolve bad links. Facebooker already includes URL rewriting >>>>>> code; >>>>>> I've merely modified it to generate correct links for the sandbox >>>>>> controller case. >>>>>> >>>>>> Thanks, >>>>>> Shawn >>>>>> >>>>>> On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: >>>>>>> Or you could do: >>>>>>> map.connect '/sandboxed_controller/ >>>>>>> sandboxed_controller/:action/:id, >>>>>>> :controller => 'sandboxed_controller' >>>>>>> where sandboxed_controller is the name of the controller you >>>>>>> want >>>>>>> to sandbox >>>>>>> >>>>>>> Michael Niessner >>>>>>> >>>>>>> On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: >>>>>>> >>>>>>>> Here's the fix for Facebook apps that specify a controller in >>>>>>>> their >>>>>>>> callback URLs. First, set this variable in your environment >>>>>>>> scripts: >>>>>>>> >>>>>>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' >>>>>>>> # where controller is the name of your Facebook controller >>>>>>>> >>>>>>>> And then patch >>>>>>>> vendor/plugins/facebooker/lib/facebooker/rails/ >>>>>>>> facebook_url_rewriting.rb >>>>>>>> as shown in the attached diff. >>>>>>>> >>>>>>>> Please let me know if you encounter any issues with this patch. >>>>>>>> >>>>>>>> Thanks, >>>>>>>> Shawn >>>>>>>> _______________________________________________ >>>>>>>> Facebooker-talk mailing list >>>>>>>> Facebooker-talk at rubyforge.org >>>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>> >>>>> >>>> >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk >> > > > > -- > http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From svicalifornia at gmail.com Tue Jan 29 17:01:01 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Tue, 29 Jan 2008 15:01:01 -0700 Subject: [Facebooker-talk] facebook_url_rewriting.rb In-Reply-To: References: <20080128205258613970.8b92ad85@gmail.com> <92A9C88C-FA9D-4AA4-84F5-7FE714491E63@gmail.com> <20080129101945834192.5a645951@gmail.com> <8522FB7F-E88B-4D79-9C52-3FB786ACCA36@gmail.com> <20080129122045533499.e1089f89@gmail.com> <4ab757a40801291310g7c0815fejb2b10f4fd832336b@mail.gmail.com> Message-ID: <20080129150101916705.ebab03c9@gmail.com> Works for me. Thanks, guys! Shawn On Tue, 29 Jan 2008 15:32:10 -0600, Michael Niessner wrote: > Shane's idea is the winner. When facebooker.yml parses callback_url > it can put the host component in where it currently does and stuff > the path into ENV['FACEBOOKER_SANDBOX_NAMESPACE']. Then developers > only need to copy their callback_url into callback_url of > facebooker.yml. > > Michael Niessner > > On Jan 29, 2008, at 3:10 PM, Shane Vitarana wrote: > >> What about just keeping callback_url, and assume the /path/ component >> is a namespace? >> >> Shane >> >> On Jan 29, 2008 2:00 PM, Michael Niessner >> wrote: >>> I feel mixed about the name. I like that callback_path translates to >>> the path component of your callback url. I like that sandbox_namespace >>> signals an intention to sandbox the app using a namespace, providing >>> guidance of how to use the setting. I prefer whichever name people >>> would have an easier time understanding. Maybe a few others on the >>> list could chime in? >>> >>> Michael Niessner >>> >>> >>> On Jan 29, 2008, at 1:20 PM, Shawn Van Ittersum wrote: >>> >>>> Hi Michael, >>>> >>>> I agree with you about namespaces. To be clear, my example code was >>>> only one possible implementation. My patch is not intended to force >>>> sandboxing to one controller only, but rather to any namespace >>>> desired by the developer. I would still like to keep the config >>>> variable named FACEBOOKER_CALLBACK_PATH, as it relates directly to >>>> the Facebook callback URL setting. So to update the example: >>>> >>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/namespace' >>>> # where Facebook Developer callback url = http://yourserver.com:port/ >>>> namespace >>>> >>>> Shawn >>>> >>>> On Tue, 29 Jan 2008 12:44:14 -0600, Michael Niessner wrote: >>>>> Actually, the implementation of your patch is probably correct. It's >>>>> just the intent that is all wrong. If you change >>>>> >>>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' to >>>>> ENV['FACEBOOKER_SANDBOX_NAMESPACE'] = '/namespace' >>>>> >>>>> You get the benefits of multiple controllers without having to add a >>>>> route for each one. Additionally you can take advantage of all the >>>>> goodness that is map.resources. >>>>> >>>>> Also a unit test would be a nice addition to your patch. >>>>> >>>>> Michael Niessner >>>>> >>>>> >>>>> On Jan 29, 2008, at 11:30 AM, Michael Niessner wrote: >>>>>> I strongly disagree. Your approach leads to the very poor design >>>>>> decision of placing all facebook actions in a single controller. By >>>>>> using routing you can use multiple controllers in a sandboxed >>>>>> environment. >>>>>> >>>>>> Set your callback_url on facebook to >>>>>> http://yourhost.com/yourapp/sandbox/ >>>>>> Then add the following routes >>>>>> map.connect '/sandbox/controller_1/:action/:id', :controller => >>>>>> 'controller_1' >>>>>> map.connect '/sandbox/controller_2/:action/:id', :controller => >>>>>> 'controller_2' >>>>>> >>>>>> I don't think adding code to facebooker to achieve a limited subset >>>>>> of the functionality that can be obtained by using rails routes is >>>>>> the "correct way" to handle this case. >>>>>> >>>>>> Michael Niessner >>>>>> >>>>>> On Jan 29, 2008, at 11:19 AM, Shawn Van Ittersum wrote: >>>>>>> The correct way to handle this case is to make sure the link URLs >>>>>>> are composed correctly in the first place, not to add routing to >>>>>>> resolve bad links. Facebooker already includes URL rewriting code; >>>>>>> I've merely modified it to generate correct links for the sandbox >>>>>>> controller case. >>>>>>> >>>>>>> Thanks, >>>>>>> Shawn >>>>>>> >>>>>>> On Tue, 29 Jan 2008 10:14:22 -0600, Michael Niessner wrote: >>>>>>>> Or you could do: >>>>>>>> map.connect '/sandboxed_controller/ >>>>>>>> sandboxed_controller/:action/:id, >>>>>>>> :controller => 'sandboxed_controller' >>>>>>>> where sandboxed_controller is the name of the controller you want >>>>>>>> to sandbox >>>>>>>> >>>>>>>> Michael Niessner >>>>>>>> >>>>>>>> On Jan 28, 2008, at 9:52 PM, Shawn Van Ittersum wrote: >>>>>>>> >>>>>>>>> Here's the fix for Facebook apps that specify a controller in >>>>>>>>> their >>>>>>>>> callback URLs. First, set this variable in your environment >>>>>>>>> scripts: >>>>>>>>> >>>>>>>>> ENV['FACEBOOKER_CALLBACK_PATH'] = '/controller' >>>>>>>>> # where controller is the name of your Facebook controller >>>>>>>>> >>>>>>>>> And then patch >>>>>>>>> vendor/plugins/facebooker/lib/facebooker/rails/ >>>>>>>>> facebook_url_rewriting.rb >>>>>>>>> as shown in the attached diff. >>>>>>>>> >>>>>>>>> Please let me know if you encounter any issues with this patch. >>>>>>>>> >>>>>>>>> Thanks, >>>>>>>>> Shawn >>>>>>>>> _______________________________________________ >>>>>>>>> Facebooker-talk mailing list >>>>>>>>> Facebooker-talk at rubyforge.org >>>>>>>>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>>>>>>> >>>>>> >>>>> >>> >>> _______________________________________________ >>> Facebooker-talk mailing list >>> Facebooker-talk at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/facebooker-talk >>> >> >> >> >> -- >> http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com > From shanev at gmail.com Wed Jan 30 18:59:33 2008 From: shanev at gmail.com (Shane Vitarana) Date: Wed, 30 Jan 2008 17:59:33 -0600 Subject: [Facebooker-talk] Publish templatized action with JSON gotcha in Rails 1.2 Message-ID: <4ab757a40801301559i2b2c46cdw9284cc2bb0b415a2@mail.gmail.com> Hey guys- to_json in Rails 1.2 produces json with unquoted keys, which is invalid. Therefore, publish_templatized_action produces invalid json for feed publishing, and you'll get an error from Facebook. To fix this, put this line in environment.rb: ActiveSupport::JSON.unquote_hash_key_identifiers = false You don't need to do this if you're running Rails 2.0. Just a heads up.. because this stumped me for a while. Shane -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From jnylund at yahoo.com Thu Jan 31 11:14:55 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Thu, 31 Jan 2008 11:14:55 -0500 Subject: [Facebooker-talk] presenting validation errors via fbml? Message-ID: <13F08D5D-C9C2-4094-8B9B-E7FC64030EF1@yahoo.com> Hi Facebookers, Is there a helper or suggested approach for presenting validation errors on an fbml form? Something to translate rails error markup to fbml:error markup? thanks Joel From sudara at alonetone.com Thu Jan 31 13:16:16 2008 From: sudara at alonetone.com (sudara) Date: Thu, 31 Jan 2008 19:16:16 +0100 Subject: [Facebooker-talk] Using facebooker AND Haml/Sass Message-ID: For anyone using both and encountering trouble with stylesheets (specifically, the paths being incorrect in production mode)... Removing facebooker solves the issue. But I bet you don't want to do that, eh? So, simply setting ActionController::Base.asset_host = '' also works like butter. I'm not 100% clear on why asset_host has anything to do with facebooker, or if people will in other cases NEED to use it, but this solved it for me. After reading the discussion on this list, I'm still a bit confused about the various constants and configs and which are important and which are not in theory. In reality (revision 160), this worked great for me (in tandem with using facebooker.yml). I'm finally up and running (after having major issues with rFacebook and routes, brain farts with the concepts behind facebooker, and the hidden rules of the facebook API itself) and have a nice little (actually, lengthly) tutorial to get folks started. I'm formatting this and will post to the group in the next day or two!) Thanks to Mike for being patient and responsive Sudara From shanev at gmail.com Thu Jan 31 14:30:26 2008 From: shanev at gmail.com (Shane Vitarana) Date: Thu, 31 Jan 2008 13:30:26 -0600 Subject: [Facebooker-talk] presenting validation errors via fbml? In-Reply-To: <13F08D5D-C9C2-4094-8B9B-E7FC64030EF1@yahoo.com> References: <13F08D5D-C9C2-4094-8B9B-E7FC64030EF1@yahoo.com> Message-ID: <4ab757a40801311130s2747bb8fh12f9557903028959@mail.gmail.com> Joel- Just wrap your flash[:error] inside an fb_error helper. Or put <%= facebook_messages %> in your layout. Shane On Jan 31, 2008 10:14 AM, Joel Nylund wrote: > Hi Facebookers, > > Is there a helper or suggested approach for presenting validation > errors on an fbml form? > > Something to translate rails error markup to fbml:error markup? > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk > -- http://myfitbuddy.com | http://shanesbrain.net | http://crimsonjet.com From svicalifornia at gmail.com Thu Jan 31 15:10:13 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 31 Jan 2008 13:10:13 -0700 Subject: [Facebooker-talk] Using facebooker AND Haml/Sass In-Reply-To: References: Message-ID: <20080131131013907272.f2eb3a51@gmail.com> I've already commented out the asset_host line in the Facebooker config stuff, and it works fine. Shawn On Thu, 31 Jan 2008 19:16:16 +0100, sudara wrote: > For anyone using both and encountering trouble with stylesheets > (specifically, the paths being incorrect in production mode)... > > Removing facebooker solves the issue. > > But I bet you don't want to do that, eh? So, simply setting > > ActionController::Base.asset_host = '' > > also works like butter. > > I'm not 100% clear on why asset_host has anything to do with > facebooker, or if people will in other cases NEED to use it, but this > solved it for me. After reading the discussion on this list, I'm still > a bit confused about the various constants and configs and which are > important and which are not in theory. In reality (revision 160), this > worked great for me (in tandem with using facebooker.yml). > > I'm finally up and running (after having major issues with rFacebook > and routes, brain farts with the concepts behind facebooker, and the > hidden rules of the facebook API itself) and have a nice little > (actually, lengthly) tutorial to get folks started. I'm formatting > this and will post to the group in the next day or two!) > > Thanks to Mike for being patient and responsive > Sudara > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From jbresnik at gmail.com Thu Jan 31 15:13:55 2008 From: jbresnik at gmail.com (John Bresnik) Date: Thu, 31 Jan 2008 12:13:55 -0800 Subject: [Facebooker-talk] Multiple FB apps in a single Facebooker app? Message-ID: <3b8cec990801311213u2beaf1abgf304d75c49b68e4c@mail.gmail.com> May seem strange but I've gotten a couple requests from clients [2 out of 4] abt this.. generally the requirement is that they want to serve up slightly different content but from more or less the same app.. I dug into init.rb and determined that its seems likely with some rearranging of facebooker.yml config - is there anything else of the top of anybody's head that might be an issue? thanks in advance.. brez From mmangino at elevatedrails.com Thu Jan 31 15:24:50 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Thu, 31 Jan 2008 14:24:50 -0600 Subject: [Facebooker-talk] Multiple FB apps in a single Facebooker app? In-Reply-To: <3b8cec990801311213u2beaf1abgf304d75c49b68e4c@mail.gmail.com> References: <3b8cec990801311213u2beaf1abgf304d75c49b68e4c@mail.gmail.com> Message-ID: <9C3A3D8D-3523-454E-996A-E3A290670372@elevatedrails.com> We use the same code base but different instances to do this. It seems a lot easier then trying to keep track of two different sessions. Mike On Jan 31, 2008, at 2:13 PM, John Bresnik wrote: > May seem strange but I've gotten a couple requests from clients [2 out > of 4] abt this.. generally the requirement is that they want to serve > up slightly different content but from more or less the same app.. I > dug into init.rb and determined that its seems likely with some > rearranging of facebooker.yml config - is there anything else of the > top of anybody's head that might be an issue? thanks in advance.. > > brez > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From mmangino at elevatedrails.com Thu Jan 31 15:25:31 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Thu, 31 Jan 2008 14:25:31 -0600 Subject: [Facebooker-talk] Using facebooker AND Haml/Sass In-Reply-To: References: Message-ID: <04E0EC26-BA81-4834-9588-21D1E2BA5F89@elevatedrails.com> The ActionController::Base.asset_host parameter is used by Rails to decide where to load images and such from. It is intended to allow you to spread assets out over multiple machines. It is used by Facebooker to load images from your machine instead of through the apps.facebook.com host. Unfortunately, they want to serve stylesheets. We should be able to patch stylesheet_link_tag to fix this Shawn, do images work for you with that line commented out? Mike On Jan 31, 2008, at 12:16 PM, sudara wrote: > For anyone using both and encountering trouble with stylesheets > (specifically, the paths being incorrect in production mode)... > > Removing facebooker solves the issue. > > But I bet you don't want to do that, eh? So, simply setting > > ActionController::Base.asset_host = '' > > also works like butter. > > I'm not 100% clear on why asset_host has anything to do with > facebooker, or if people will in other cases NEED to use it, but this > solved it for me. After reading the discussion on this list, I'm still > a bit confused about the various constants and configs and which are > important and which are not in theory. In reality (revision 160), this > worked great for me (in tandem with using facebooker.yml). > > I'm finally up and running (after having major issues with rFacebook > and routes, brain farts with the concepts behind facebooker, and the > hidden rules of the facebook API itself) and have a nice little > (actually, lengthly) tutorial to get folks started. I'm formatting > this and will post to the group in the next day or two!) > > Thanks to Mike for being patient and responsive > Sudara > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From mmangino at elevatedrails.com Thu Jan 31 15:27:13 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Thu, 31 Jan 2008 14:27:13 -0600 Subject: [Facebooker-talk] session handling for non-facebook requests Message-ID: <7132212E-2AE1-489A-8072-4659611B79C8@elevatedrails.com> I just committed a patch from David Clements to fix session sharing between Facebook and Non-Facebook requests. I also cleaned up some of the code so that you won't get exceptions raised for InvalidSignatures on non-Facebook requests. Mike -- Mike Mangino http://www.elevatedrails.com From svicalifornia at gmail.com Thu Jan 31 15:30:43 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 31 Jan 2008 13:30:43 -0700 Subject: [Facebooker-talk] Facebooker and file_column Message-ID: <20080131133043322445.dbb9db98@gmail.com> Facebooker URL Rewriter stuff overloads ActionController::AbstractRequest.relative_url_root, causing a conflict with the plugin file_column and possibly other utilities. file_column constructs image URLs using the server host and relative_url_root This is not related to the sandbox patch I added to the rewriter. Facebooker overloaded relative_url_root before I touched it. I've rewritten the facebooker_url_rewriting.rb script to do the same stuff but without overloading relative_url_root. I'll send it in later today. Shawn From mmangino at elevatedrails.com Thu Jan 31 15:51:08 2008 From: mmangino at elevatedrails.com (Mike Mangino) Date: Thu, 31 Jan 2008 14:51:08 -0600 Subject: [Facebooker-talk] Facebooker and file_column In-Reply-To: <20080131133043322445.dbb9db98@gmail.com> References: <20080131133043322445.dbb9db98@gmail.com> Message-ID: Shawn, that's great. I think that is going to clean up a lot of our code. The asset path patches can go away at that point. I look forward to seeing this. Mike On Jan 31, 2008, at 2:30 PM, Shawn Van Ittersum wrote: > Facebooker URL Rewriter stuff overloads > ActionController::AbstractRequest.relative_url_root, causing a > conflict with the plugin file_column and possibly other utilities. > file_column constructs image URLs using the server host and > relative_url_root > > This is not related to the sandbox patch I added to the rewriter. > Facebooker overloaded relative_url_root before I touched it. > > I've rewritten the facebooker_url_rewriting.rb script to do the same > stuff but without overloading relative_url_root. I'll send it in > later today. > > Shawn > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk -- Mike Mangino http://www.elevatedrails.com From jbresnik at gmail.com Thu Jan 31 16:07:13 2008 From: jbresnik at gmail.com (John Bresnik) Date: Thu, 31 Jan 2008 13:07:13 -0800 Subject: [Facebooker-talk] Multiple FB apps in a single Facebooker app? In-Reply-To: <9C3A3D8D-3523-454E-996A-E3A290670372@elevatedrails.com> References: <3b8cec990801311213u2beaf1abgf304d75c49b68e4c@mail.gmail.com> <9C3A3D8D-3523-454E-996A-E3A290670372@elevatedrails.com> Message-ID: <3b8cec990801311307r72efaf94j91b3c72e167cf3e@mail.gmail.com> Thanks Mike - yea that was essentially the solution as well [but with rfacebook - Im brand new to Facebooker but real happy so far] for one.. the other was in fact different business logic/views but the same domain model - i.e. really separate codebases. Solution there was to pull out the core similarities into a plugin and then two separate projects with a -x install - and so far has worked well.. brez On Jan 31, 2008 12:24 PM, Mike Mangino wrote: > We use the same code base but different instances to do this. It seems > a lot easier then trying to keep track of two different sessions. > > Mike > > > On Jan 31, 2008, at 2:13 PM, John Bresnik wrote: > > > May seem strange but I've gotten a couple requests from clients [2 out > > of 4] abt this.. generally the requirement is that they want to serve > > up slightly different content but from more or less the same app.. I > > dug into init.rb and determined that its seems likely with some > > rearranging of facebooker.yml config - is there anything else of the > > top of anybody's head that might be an issue? thanks in advance.. > > > > brez > > _______________________________________________ > > Facebooker-talk mailing list > > Facebooker-talk at rubyforge.org > > http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > > From jnylund at yahoo.com Thu Jan 31 16:52:31 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Thu, 31 Jan 2008 16:52:31 -0500 Subject: [Facebooker-talk] request to install app Message-ID: <6D32CDE5-E8AF-4CFC-A7C7-51FEF3BDFCAC@yahoo.com> Hi, I would like to generate a facebook call on behalf of a user to create a request to another user to install the app. Is there a way to do this without being in a fb_request_form? the use case is: Fred is creating a task, he assign it to a friend Sally , if Sally has already installed & setup my app, no problem, if she hasnt, I want to send an add request from Fred along with details of the task. I have a create task form with tons of stuff in it including a friend selector, so I have the friends id. thanks Joel From svicalifornia at gmail.com Thu Jan 31 17:02:43 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 31 Jan 2008 15:02:43 -0700 Subject: [Facebooker-talk] Using facebooker AND Haml/Sass In-Reply-To: <04E0EC26-BA81-4834-9588-21D1E2BA5F89@elevatedrails.com> References: <04E0EC26-BA81-4834-9588-21D1E2BA5F89@elevatedrails.com> Message-ID: <20080131150243435063.0ac0e655@gmail.com> Hi Mike, Since commenting that line out, I've been using absolute URLs to get to images. Any suggestions/fixes are welcome. :) Shawn On Thu, 31 Jan 2008 14:25:31 -0600, Mike Mangino wrote: > The ActionController::Base.asset_host parameter is used by Rails to > decide where to load images and such from. It is intended to allow > you to spread assets out over multiple machines. > > It is used by Facebooker to load images from your machine instead of > through the apps.facebook.com host. Unfortunately, they want to serve > stylesheets. We should be able to patch stylesheet_link_tag to fix > this > > Shawn, do images work for you with that line commented out? > > Mike > On Jan 31, 2008, at 12:16 PM, sudara wrote: > >> For anyone using both and encountering trouble with stylesheets >> (specifically, the paths being incorrect in production mode)... >> >> Removing facebooker solves the issue. >> >> But I bet you don't want to do that, eh? So, simply setting >> >> ActionController::Base.asset_host = '' >> >> also works like butter. >> >> I'm not 100% clear on why asset_host has anything to do with >> facebooker, or if people will in other cases NEED to use it, but this >> solved it for me. After reading the discussion on this list, I'm still >> a bit confused about the various constants and configs and which are >> important and which are not in theory. In reality (revision 160), this >> worked great for me (in tandem with using facebooker.yml). >> >> I'm finally up and running (after having major issues with rFacebook >> and routes, brain farts with the concepts behind facebooker, and the >> hidden rules of the facebook API itself) and have a nice little >> (actually, lengthly) tutorial to get folks started. I'm formatting >> this and will post to the group in the next day or two!) >> >> Thanks to Mike for being patient and responsive >> Sudara >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk > > -- > Mike Mangino > http://www.elevatedrails.com > From svicalifornia at gmail.com Thu Jan 31 17:05:55 2008 From: svicalifornia at gmail.com (Shawn Van Ittersum) Date: Thu, 31 Jan 2008 15:05:55 -0700 Subject: [Facebooker-talk] request to install app In-Reply-To: <6D32CDE5-E8AF-4CFC-A7C7-51FEF3BDFCAC@yahoo.com> References: <6D32CDE5-E8AF-4CFC-A7C7-51FEF3BDFCAC@yahoo.com> Message-ID: <20080131150555802244.3a5fdc27@gmail.com> FYI, FB changed their API to prevent developers from generating a request URL on the backend, which is now a deprecated behavior and may be dropped at any time. You should use fb:request-form. I'll let the others answer on whether Facebooker still supports the old deprecated request API. Shawn On Thu, 31 Jan 2008 16:52:31 -0500, Joel Nylund wrote: > Hi, > > I would like to generate a facebook call on behalf of a user to create > a request to another user to install the app. > > Is there a way to do this without being in a fb_request_form? > > the use case is: > > Fred is creating a task, he assign it to a friend Sally , if Sally has > already installed & setup my app, no problem, if she hasnt, I want to > send an add request from Fred along with details of the task. > > I have a create task form with tons of stuff in it including a friend > selector, so I have the friends id. > > thanks > Joel > > _______________________________________________ > Facebooker-talk mailing list > Facebooker-talk at rubyforge.org > http://rubyforge.org/mailman/listinfo/facebooker-talk From jnylund at yahoo.com Thu Jan 31 17:09:24 2008 From: jnylund at yahoo.com (Joel Nylund) Date: Thu, 31 Jan 2008 17:09:24 -0500 Subject: [Facebooker-talk] request to install app In-Reply-To: <20080131150555802244.3a5fdc27@gmail.com> References: <6D32CDE5-E8AF-4CFC-A7C7-51FEF3BDFCAC@yahoo.com> <20080131150555802244.3a5fdc27@gmail.com> Message-ID: <1163FD02-2AC8-448F-8EB8-4B2565A8EA45@yahoo.com> ok, cool, thats good enough, I got enough deprecation in my system , no need to add more :) I guess I will just send them to a followup page. thanks Joel On Jan 31, 2008, at 5:05 PM, Shawn Van Ittersum wrote: > FYI, FB changed their API to prevent developers from generating a > request URL on the backend, which is now a deprecated behavior and > may be dropped at any time. You should use fb:request-form. I'll > let the others answer on whether Facebooker still supports the old > deprecated request API. > > Shawn > > On Thu, 31 Jan 2008 16:52:31 -0500, Joel Nylund wrote: >> Hi, >> >> I would like to generate a facebook call on behalf of a user to >> create >> a request to another user to install the app. >> >> Is there a way to do this without being in a fb_request_form? >> >> the use case is: >> >> Fred is creating a task, he assign it to a friend Sally , if Sally >> has >> already installed & setup my app, no problem, if she hasnt, I want to >> send an add request from Fred along with details of the task. >> >> I have a create task form with tons of stuff in it including a friend >> selector, so I have the friends id. >> >> thanks >> Joel >> >> _______________________________________________ >> Facebooker-talk mailing list >> Facebooker-talk at rubyforge.org >> http://rubyforge.org/mailman/listinfo/facebooker-talk