Exemplo n.º 1
0
 public function landingPageJson()
 {
     $return_array = array();
     $landingpage = Landingpage::all();
     foreach ($landingpage as $landingpage) {
         $data_array['id'] = $landingpage->id;
         $data_array['heading'] = $landingpage->heading;
         $data_array['content'] = $landingpage->content;
         $data_array['content_admin'] = $landingpage->content_admin;
         array_push($return_array, $data_array);
     }
     echo json_encode($return_array);
 }
Exemplo n.º 2
0
 public function index()
 {
     $landingpage = landingpage::all();
     $data = array('landingpage' => $landingpage);
     return view('welcome.index', $data);
 }