PHPackages                             fbf/laravel-mobile-facebook-app - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Search &amp; Filtering](/categories/search)
4. /
5. fbf/laravel-mobile-facebook-app

ActiveLibrary[Search &amp; Filtering](/categories/search)

fbf/laravel-mobile-facebook-app
===============================

A Laravel Filter for Facebook Page Tab Apps that need to work on mobile too.

v0.1.0(12y ago)3321MITPHPPHP &gt;=5.3.0

Since Sep 11Pushed 12y ago5 watchersCompare

[ Source](https://github.com/FbF/Laravel-Mobile-Facebook-App)[ Packagist](https://packagist.org/packages/fbf/laravel-mobile-facebook-app)[ RSS](/packages/fbf-laravel-mobile-facebook-app/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (1)Dependencies (3)Versions (2)Used By (0)

Laravel Mobile Facebook App
===========================

[](#laravel-mobile-facebook-app)

A Laravel Filter for Facebook Page Tab Apps that need to work on mobile too.

Concept
-------

[](#concept)

For all routes that you apply the filter too, it checks to see if the user is not on mobile and is not the facebook bot and hasn't already been redirected to Facebook (prevents endless redirection once inside the iFrame), then redirects the user to the tab app on your Facebook Page, on the page in your app that the user was trying to access originally.

However, if the user is on mobile (or it's the Facebook bot that gets open graph data), don't do the redirect and just show them the page they are after.

All links to your app that get shared on social networks and other websites or apps should be to your domain, not the Facebook Tab App URL.

I.e.

[http://myfacebookapp.com/path/to/page?query=string&amp;shared=true](http://myfacebookapp.com/path/to/page?query=string&shared=true)

not

[http://www.facebook.com/pages/mypage?sk\_app=123456789&amp;app\_data=](http://www.facebook.com/pages/mypage?sk_app=123456789&app_data=)...

Note the shared=true query string param in the above URL - this is required in all links to your app that are shared on social networks or included on other websites. It's needed in case this is the second or third etc time that the user visited your app not on a mobile device and they already have a valid session. It's required because we set a flag in the session to remember that the user has been redirected to facebook, so when the app is loaded again inside the iFrame the user is not redirected again, resulting in an infinite loop. However, if this is not the first time a user follows a link to your app, and they already have a session, this shared=true query string parameter removes this flag from the session before checking whether they have already been redirected, so that they get redirected again. Get that? No? Me neither.

Installation
------------

[](#installation)

Add the following to you composer.json file

```
"fbf/laravel-mobile-facebook-app": "dev-master"

```

Run

```
composer update

```

Add the following to app/config/app.php

```
'Fbf\LaravelMobileFacebookApp\LaravelMobileFacebookAppServiceProvider'

```

Publish the config from thomaswelton/laravel-facebook to app/config/packages (this library is used to decode the signed request and to get the tab app URL for your app)

```
php artisan config:publish thomaswelton/laravel-facebook

```

Add your app id and secret to the published config file

Usage
-----

[](#usage)

Register and apply the filter, add the following to app/routes.php

```
Route::filter('facebook', 'LaravelMobileFacebookAppFilter');
Route::when('my/routes/*', 'facebook');

```

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

4629d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/c1890fa7f83fd77b7c73d984199cb9a45ba9871acb4133490f43115c19fe845f?d=identicon)[neilcrookes](/maintainers/neilcrookes)

---

Top Contributors

[![neilcrookes](https://avatars.githubusercontent.com/u/24232?v=4)](https://github.com/neilcrookes "neilcrookes (1 commits)")

---

Tags

laravelfacebookfiltermobile

### Embed Badge

![Health badge](/badges/fbf-laravel-mobile-facebook-app/health.svg)

```
[![Health](https://phpackages.com/badges/fbf-laravel-mobile-facebook-app/health.svg)](https://phpackages.com/packages/fbf-laravel-mobile-facebook-app)
```

###  Alternatives

[kyslik/laravel-filterable

Using URL query strings to filter Eloquent queries.

11539.0k](/packages/kyslik-laravel-filterable)[stolz/laravel-html-tidy

HTML Tidy middleware for Laravel

268.7k](/packages/stolz-laravel-html-tidy)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
