I’m trying to develop a mobile version of an existing site for use on the iPhone, and I’m using a straight hyperlink who’s target is defined thusly:
$fb = $this->facebook->getLoginUrl(array(
'redirect_uri' => $redirect,
'scope' => 'email,publish_stream,offline_access,friends_location',
'display' => 'popup'
));
$data['fb_login_url'] = $fb;
However, tapping on this in mobile safari on my iPhone takes me to what appears to be the desktop-sized Facebook login page:

How can I get a mobile-optimized version of this Facebook login page?
If you need to use the login function of the facebook javascript SDK see https://developers.facebook.com/docs/guides/mobile/web/#sdk
Specifically this example
Calling
FB.login()will cause the mobile web version to open in a new mobile safari ‘tab’