In the newest dev in fb_canvas.module > fb_canvas_url_outbound_alter() near line 510
$options['query'] = str_replace('destination=', 'fb_canvas_destination=', $options['query']);
affects the normal drupal login procedure: Drupal no longer jumps to the login destination (e.g. "node") but to your profile when not logged in via fb connect.

It may affect only older Drupal installation since mine is 6.6. but is reproducible every time with this version. So I let the report here for documentation purposes.

I circumvented this by moving the whole block into the if(fb_canvas_is_iframe)-block like this:

if (fb_canvas_is_iframe()) {
      if (!$options['absolute']) {
        // Could append all 'fb_sig' params to internal links.  But for now we rely on fb_canvas_process.
      }
      else {
        //dpm($options, "fb_canvas_url_outbound_alter($path)");
      }

      // Drupal has a habit of adding ?destination=... to some URLs.
      // And Facebook for no good reason screws up when you do that.
      if ($options['query']) {
        $options['query'] = str_replace('destination=', 'fb_canvas_destination=', $options['query']);
      }
    }

Comments

Dave Cohen’s picture

Assigned: Unassigned » Dave Cohen
Status: Active » Reviewed & tested by the community

Thanks for catching that. You're right, that should be only on canvas pages. I will commit your patch when I have a moment.

Dave Cohen’s picture

Component: Code » Canvas Pages (iframe)
Status: Reviewed & tested by the community » Fixed

committed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.