# fluentform/1.2.4/framework/Foundation/AppProvider.php

Fluent Forms – Customizable Contact Forms, Survey, Quiz, &amp; Conversational Form Builder, version 1.2.4. 44 lines.

- Page: https://pluginprobe.com/plugins/fluentform/1.2.4/code/framework/Foundation/AppProvider.php
- Raw: https://pluginprobe.com/plugins/fluentform/1.2.4/raw/framework/Foundation/AppProvider.php
- Modified: 2017-12-29T16:40:50+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/fluentform/1.2.4/code/framework/Foundation/AppProvider.php#L10-L20`.

```php
<?php

namespace FluentForm\Framework\Foundation;

use FluentForm\Framework\Foundation\Provider;

class AppProvider extends Provider
{
    /**
     * The provider booting method to boot this provider
     * @return void
     */
    public function booting()
    {
        $this->app->bind(
            'app', $this->app, 'App', 'FluentForm\Framework\Foundation\Application'
        );
    }

    /**
     * The provider booted method to be called after booting
     * @return void
     */
    public function booted()
    {   
        // Framework is booted and ready
        $this->app->booted(function($app) {
            $app->load($app->appPath('Global/Common.php'));
            $app->bootstrapWith($app->getCommonProviders());
        });

        // Application is booted and ready
        $this->app->ready(function($app) {
            $app->load($app->appPath('Hooks/Common.php'));
            if ($app->isUserOnAdminArea()) {
                $app->load($app->appPath('Hooks/Backend.php'));
            } else {
                $app->load($app->appPath('Hooks/Frontend.php'));   
            }
            $app->load($app->appPath('Hooks/Ajax.php'));
        });
    }
}

```
