How to Build Web Application Signup with Laravel 5.2

How to Build Web Application Signup with Laravel 5.2

This tutorial is about How to Build Web Application Signup with Laravel 5.2

Introduction

In this section, we’ll be creating simple mesosfer web application for user signup with Laravel 5.2 based on mesosfer docs.

Prerequisites

To follow this tutorial, you will need to prepare item below :

  • Sign up for an account in mesosfer cloud platform then create application to get applicationId.
  • Install composer.
  • Download source framework laravel version 5.2 using composer or download directly from laravel site.

Getting Started

To get our web application working, You need to have an applicationId from mesosfer cloud platform. Login and goto Apps –> then click App Setting like picture below.

holyapps

Install Laravel

Run composer in your directory like command below :

Add Guzzle Package

Guzzle is a PHP HTTP client that makes it easy to send HTTP requests and trivial to integrate with web services. Install on your laravel using run composer on root application like command below :

Edit config/app.php then update array ‘providers’ append guzzle provider folder to this array.

Still in the config/app.php. enable guzzle facade in array ‘aliases’.

Let’s Start Coding!

You have to define routes first, this script is used to handle navigation or link to controller or view. Edit file app/Http/routes.php and add some line code below :

After routes defined, you have to create UserController.php on app/Http/Controller, then fill code below :

Add method register for handling navigation to page register.

Then create directory pages in resources/views and add file register.blade.php on that directory. Add code below to that file :

Start service your web server using php serve in laravel root directory :

If you open in browser, it will show page like the picture below :

how-to-build-web-application-signup-with-laravel-5-2-1
Add method signup for handling action from register page. Then use Illuminate\Http\Request above the namespace like code below :

If you try to execute submit form register, the result is like json data below :

Let’s try and share to your community. Download complete code here.

Conclusion

In this tutorial we’ve tried to create simple module signup user with mesosfer and laravel. By using mesosfer you will reduce your development time. Mesosfer also provide some other platform of SDK such as mobile application, game, and others so you can transfer your data in another platform easily.

Mesosfer helps you connect your project to the cloud. Cut off the development process so you can straight into the delivery process instead stumble on the complicated infrastructure.

Lead Mobile Software Engineer. Having more than 8 years in IT Consultant. Love working with new mobile platform technology. Expert in Android and iOS Mobile Development.

Leave a Reply