Laravel Starter

Laravel Starter

Shawn McCool

Language: English

Pages: 64

ISBN: 1782160906

Format: PDF / Kindle (mobi) / ePub


The definitive introduction to the Laravel PHP web development framework.

Overview

  • Create databases and models using Laravel migrations and the powerful Eloquent model
  • Get started with a useful application example that is immediately applicable to real-world applications
  • Learn how to implement powerful relationships with Eloquent

In Detail

Laravel is fundamentally changing the PHP web-development landscape. Laravel is bringing the paradigm-shifts that PHP developers have been craving. We now can take control of our application architecture and advance our craft without needing to fight against our tools. Laravel's philosophy is to provide a highly flexible architecture and an extremely expressive API while emphasizing PHP’s strengths and abstracting out its weaknesses. For these reasons Laravel is ideal for quickly creating high performance, robust applications. By providing developers with tools for automating tasks including database schema modification, CRUD operations, and testing we're able to reduce our workload, application complexity, and human-error.

"Laravel Starter" is the ideal introduction to this game-changing framework. Learn best-practiced approaches to web-application development with Laravel from a seasoned professional.

It starts out by installing and configuring the framework step-by-step. Then you'll use Laravel best-practices to create a private user administration system that is ready for real-world use. The later part deals with digging deep into Eloquent relationships, exploring the different relationship types and how Eloquent is working under-the-hood to simplify your life without forcing you to relinquish control. Exploring Laravel's simple yet flexible authentication system, data validation, and filters allows you to easily run code before and after your controller actions. Finally, it discusses Laravel bundles, the most flexible PHP modular code implementation in its weightclass.

Focused on the how as much as the why, Laravel Starter gives you the tools to immediately begin creating professional web-applications with Laravel.

What you will learn from this book

  • How to install and configure Laravel
  • Creating and using Eloquent models
  • How to understand and utilize Eloquent relationships
  • Routing to controllers and closures
  • Using Laravel's authentication system
  • Utilizing filters to secure your site's private areas
  • Learn how to use bundles to add functionality to your site
  • Use Laravel's validator class to validate your forms or anything else
  • Use form and HTML helpers to abstract and ease working with some HTML elements

Approach

This book is a practical, task-based, step-by-step tutorial that demonstrates topics ranging from MVC code-separation, to code-modularity, to utilizing ActiveRecord for data abstraction which are explained from the ground-up to provide a strong framework of understanding for creating professional web-applications with Laravel.

Who this book is written for

This book is ideal for programmers familiar with PHP who are interested in learning the Laravel way of solving the common problems faced in their day to day work.

Foundations of Object-Oriented Languages Types and Semantics

Dart: Up and Running

Visual Studio 2010 Best Practices

Bandit Algorithms for Website Optimization

The Dragon's Gift: The Real Story of China in Africa

 

 

 

 

 

 

 

 

 

 

 

array( 'username' => Input::get('email'), 'password' => Input::get('password'), ); if(Auth::attempt($credentials)) { return "User has been logged in."; } else { return Redirect::back()->with_input(); } } With the addition of this method, we now have a functioning login form. Feel free to go ahead and try it out! Let's look at how we validate a user's e-mail and password. First, we create an array that contains the credentials received from the login form. Notice that we're storing e-mail and

{{ Auth::user()->real_name }} @endif As you've seen, Laravel's authentication system is driver-based. In this example, we used the Eloquent driver. However, you also have the ability to create custom authentication drivers. This gives you the power to authenticate users with different means and return different types of data with the standard Auth class' API. Covering the development of custom drivers is outside the scope of this document. However, it's simple and powerful. Be sure to

locations include /Users/Shawn/Sites, c:\sites, and /var/www/vhosts/ depending on your operating system. We'll assume that your first Laravel installation is in c:\sites\myfirst\. Step 3 – Configuring hosts Let's go ahead and set up our web server to host our site. We need to choose a host name for our example application. This is our first application and we're working on our local development environment, so let's use http://myfirst.dev?. In Linux and OSX, simply add the following

changes to any number of systems without the potential for human error. Note Migrations are especially useful for projects in which you're collaborating with others. Like using source control, migrations are always a good idea. Developers who are new to migrations might believe them unnecessary or believe that they add too much additional work at first. But, stick with it and their value will become quickly apparent. Let's start by creating our migration template with Laravel's

Sharma Proofreader Maria Gould Graphics Aditi Gajjar Production Coordinator Prachali Bhiwandkar Cover Work Prachali Bhiwandkar Cover Image Sheetal Aute Foreword When I first wrote the Laravel framework, it was because I needed a way to quickly develop my ideas for great web applications. Even more, I wanted to enjoy developing them. It turns out that the things I built to make my development enjoyable others have found enjoyable as well. Laravel has grown into a mature

Download sample

Download