1. Go to this page and download the library: Download motaword/active-laravel library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
motaword / active-laravel example snippets
return [
'active' => [
/*
|--------------------------------------------------------------------------
| MotaWord Active Project Token
|--------------------------------------------------------------------------
|
| Set your MotaWord Active token here. It will be sent via the X-MotaWord-Token header.
|
*/
'token' => env('MOTAWORD_ACTIVE_TOKEN'),
/*
|--------------------------------------------------------------------------
| MotaWord Active Project ID
|--------------------------------------------------------------------------
|
| Set your MotaWord Active project ID here. You can find this ID on your MotaWord dashboard, under Active > Configuration.
|
*/
'project_id' => env('MOTAWORD_ACTIVE_PROJECT_ID'),
/*
|--------------------------------------------------------------------------
| MotaWord Active - Widget ID
|--------------------------------------------------------------------------
|
| Set your MotaWord Active widget ID here. You can find this ID on your MotaWord dashboard, under Active > Configuration.
|
*/
'widget_id' => env('MOTAWORD_ACTIVE_WIDGET_ID'),
/*
|--------------------------------------------------------------------------
| Enable MotaWord Active
|--------------------------------------------------------------------------
|
| Set this field to false to fully disable the MotaWord Active service.
|
*/
'serve_enable' => env('MOTAWORD_ACTIVE_SERVE_ENABLE', true),
/*
|--------------------------------------------------------------------------
| Serve URL
|--------------------------------------------------------------------------
|
| This is the base URL for our localization-specific CDN service, Active Serve.
|
*/
'serve_url' => env('MOTAWORD_ACTIVE_SERVE_URL', 'https://serve.motaword.com'),
/*
|--------------------------------------------------------------------------
| Return soft HTTP status codes
|--------------------------------------------------------------------------
|
| By default MotaWord Active returns soft HTTP codes. If you would like it to
| return the real ones in case of Redirection (3xx) or status Not Found (404),
| set this parameter to false.
| Keep in mind that returning real HTTP codes '*.torrent',
'*.eot',
'*.ttf',
'*.otf',
'*.woff',
'*.woff2'
],
/*
|--------------------------------------------------------------------------
| Crawler User Agents
|--------------------------------------------------------------------------
|
| Requests from crawlers that do not support _escaped_fragment_ will
| nevertheless be served with prerendered pages. You can customize
| the list of crawlers here.
|
*/
'crawler_user_agents' => [
'googlebot',
'yahoo',
'bingbot',
'yandex',
'baiduspider',
'facebookexternalhit',
'twitterbot',
'rogerbot',
'linkedinbot',
'embedly',
'bufferbot',
'quora link preview',
'showyoubot',
'outbrain',
'pinterest',
'pinterest/0.',
'developers.google.com/+/web/snippet',
'www.google.com/webmasters/tools/richsnippets',
'slackbot',
'vkShare',
'W3C_Validator',
'redditbot',
'Applebot',
'WhatsApp',
'flipboard',
'tumblr',
'bitlybot',
'SkypeUriPreview',
'nuzzel',
'Discordbot',
'Google Page Speed',
'Qwantify'
],
],
];
// motaword.php:
'whitelist' => [
'/frontend/*' // only Serve pages starting with '/frontend/'
],
// motaword.php:
'blacklist' => [
'/api/*' // do not Serve pages starting with '/api/'
],