/**
  * Store a newly created main meta in storage.
  *
  * @return Response
  */
 public function store()
 {
     //Create the validator to process input for validation.
     $input = Input::except('_token', 'page_main_content');
     $mainContent = $this->purifier->clean(Input::get('page_main_content'));
     $input['page_main_content'] = $mainContent;
     $validator = Validator::make($input, MainMetaValidator::validationRules());
     if ($validator->fails()) {
         return Redirect::to('/admin/main_meta')->withErrors($validator)->withInput($input);
     }
     $mainMeta = new MainMeta();
     $mainMeta->fill($input);
     $mainMeta->save();
     Session::flash('success_message_add', 'The main meta has successfully been created and stored!');
     return Redirect::to('/admin/main_meta/');
 }
 public static function activatedAdBlockBlocking()
 {
     return MainMeta::firstOrFail()->prevent_adblock_blocking;
 }
 /**
  * Create and download main meta data as CSV file.
  */
 public function getMainMetaData()
 {
     $mainMeta = MainMeta::all();
     $this->createCsv($mainMeta, 'main_meta');
 }
 /**
  * Display the main page.
  *
  * @return Response
  */
 public function index()
 {
     $mainMeta = MainMeta::firstOrFail() != null ? MainMeta::firstOrFail() : null;
     return view('rotator.index', compact('mainMeta'));
 }
<?php

use App\MainMeta;
$mainMeta = MainMeta::firstOrFail();
?>

<script>
    (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
                (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
            m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
    })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
    ga('create', '{{ $mainMeta->google_analytics_id }}', 'auto');
    ga('send', 'pageview');
</script>
 public static function disqusShortName()
 {
     return MainMeta::firstOrFail()->disqus_shortname;
 }
 public function run()
 {
     MainMeta::truncate();
     $main_meta = new MainMeta(['title' => 'FreeBTC.website - Earn Free Bitcoins from our Bitcoin Faucet Rotator', 'description' => 'Visit our bitcoin faucet rotator and earn upwards of 100,000 free satoshis per day. Intervals from every minute to every 24 hours. We welcome new faucets.', 'keywords' => 'Free Bitcoins, Bitcoin Faucet Rotator, Satoshis, Free BTC Website', 'google_analytics_id' => 'UA-57957173-1', 'yandex_verification' => '6bd366f4a927b8e4', 'bing_verification' => '01CE0CA0B4512F8EF0B231C935E124E1']);
     $main_meta->save();
 }