Leanpub Header

Skip to main content

Laravel 4.2.x Docs

Most up-to-date offline documentation

This book is an up-to-date compilation of the official documentation pages, for 4.2.x version of Laravel, hosted on http://laravel.com/docs to help the community to have an easy to read & organized offline documentation that can be used as a portable reference.
Free With Membership

With Membership

Free!

$7.99

You pay

$7.99

Author earns

$6.39
$

...Or Buy With Credits!

You can get credits monthly with a Reader Membership
PDF
EPUB
WEB
3,401
Readers
343
Pages
About

About

About the Book

This book is an up-to-date compilation of the official documentation pages hosted on http://laravel.com/docs to help the community to have an easy to read & organised offline documentation that can be used as a portable reference.

I will try my best to keep this book in sync with the official documentation by reviewing the changes in documentation repo periodically. If you find any error in the documentation or want to contribute, please feel free to fork the documentation repo in github and send pull request with corrections/enhancements. When your pull request will be accepted & merged into the repo, those updates will automatically be available in this book through next periodic sync.

Share this book

Categories

License

Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License

Author

About the Author

M N Islam Shihan

Founder & CTO at Sphinx Corporation

An accomplished Software Engineer & Leader specializing in Object-Oriented Design and Analysis with extensive experience in the full life cycle of the software design process including requirement analysis, prototyping, proof of concept, design of application, platform and user interface architecture design, implementation, testing and maintenance. Additional expertise includes project management and strong communication skills on both technical and business domains.

Social Profiles

Contents

Table of Contents

Preface

Introduction

  1. Where To Start
  2. Laravel Philosophy

Laravel Quickstart

  1. Installation
  2. Local Development Environment
  3. Routing
  4. Creating A View
  5. Creating A Migration
  6. Eloquent ORM
  7. Displaying Data
  8. Deploying Your Application

Release Notes

  1. Laravel 4.2
  2. Laravel 4.1

Upgrade Guide

  1. Upgrading To 4.2 From 4.1
  2. Upgrading To 4.1.29 From <= 4.1.x
  3. Upgrading To 4.1.26 From <= 4.1.25
  4. Upgrading To 4.1 From 4.0

Contribution Guide

  1. Introduction
  2. Core Development Discussion
  3. New Features
  4. Bugs
  5. Which Branch?
  6. Security Vulnerabilities
  7. Coding Style
  8. Getting Started

Installation

  1. Install Composer
  2. Install Laravel
  3. Server Requirements
  4. Configuration
  5. Pretty URLs

Configuration

  1. Introduction
  2. Environment Configuration
  3. Protecting Sensitive Configuration
  4. Maintenance Mode

Laravel Homestead

  1. Introduction
  2. Included Software
  3. Installation & Setup
  4. Daily Usage
  5. Ports

Request Lifecycle

  1. Overview
  2. Request Lifecycle
  3. Start Files
  4. Application Events

Routing

  1. Basic Routing
  2. Route Parameters
  3. Route Filters
  4. Named Routes
  5. Route Groups
  6. Sub-Domain Routing
  7. Route Prefixing
  8. Route Model Binding
  9. Throwing 404 Errors
  10. Routing To Controllers

Requests & Input

  1. Basic Input
  2. Cookies
  3. Old Input
  4. Files
  5. Request Information

Views & Responses

  1. Basic Responses
  2. Redirects
  3. Views
  4. View Composers
  5. Special Responses
  6. Response Macros

Controllers

  1. Basic Controllers
  2. Controller Filters
  3. Implicit Controllers
  4. RESTful Resource Controllers
  5. Handling Missing Methods

Errors & Logging

  1. Configuration
  2. Handling Errors
  3. HTTP Exceptions
  4. Handling 404 Errors
  5. Logging

Security

  1. Configuration
  2. Storing Passwords
  3. Authenticating Users
  4. Manually Logging In Users
  5. Protecting Routes
  6. HTTP Basic Authentication
  7. Password Reminders & Reset
  8. Encryption
  9. Authentication Drivers

Laravel Cashier

  1. Introduction
  2. Configuration
  3. Subscribing To A Plan
  4. No Card Up Front
  5. Swapping Subscriptions
  6. Subscription Quantity
  7. Cancelling A Subscription
  8. Resuming A Subscription
  9. Checking Subscription Status
  10. Handling Failed Payments
  11. Handling Other Stripe Webhooks
  12. Invoices

Cache

  1. Configuration
  2. Cache Usage
  3. Increments & Decrements
  4. Cache Tags
  5. Database Cache

Extending The Framework

  1. Introduction
  2. Managers & Factories
  3. Where To Extend
  4. Cache
  5. Session
  6. Authentication
  7. IoC Based Extension
  8. Request Extension

Events

  1. Basic Usage
  2. Wildcard Listeners
  3. Using Classes As Listeners
  4. Queued Events
  5. Event Subscribers

Facades

  1. Introduction
  2. Explanation
  3. Practical Usage
  4. Creating Facades
  5. Mocking Facades
  6. Facade Class Reference

Forms & HTML

  1. Opening A Form
  2. CSRF Protection
  3. Form Model Binding
  4. Labels
  5. Text, Text Area, Password & Hidden Fields
  6. Checkboxes and Radio Buttons
  7. Number
  8. File Input
  9. Drop-Down Lists
  10. Buttons
  11. Custom Macros
  12. Generating URLs

Helper Functions

  1. Arrays
  2. Paths
  3. Strings
  4. URLs
  5. Miscellaneous

IoC Container

  1. Introduction
  2. Basic Usage
  3. Where To Register Bindings
  4. Automatic Resolution
  5. Practical Usage
  6. Service Providers
  7. Container Events

Localization

  1. Introduction
  2. Language Files
  3. Basic Usage
  4. Pluralization
  5. Validation
  6. Overriding Package Language Files

Mail

  1. Configuration
  2. Basic Usage
  3. Embedding Inline Attachments
  4. Queueing Mail
  5. Mail & Local Development

Package Development

  1. Introduction
  2. Creating A Package
  3. Package Structure
  4. Service Providers
  5. Deferred Providers
  6. Package Conventions
  7. Development Workflow
  8. Package Routing
  9. Package Configuration
  10. Package Views
  11. Package Migrations
  12. Package Assets
  13. Publishing Packages

Pagination

  1. Configuration
  2. Usage
  3. Appending To Pagination Links
  4. Converting To JSON
  5. Custom Presenters

Queues

  1. Configuration
  2. Basic Usage
  3. Queueing Closures
  4. Running The Queue Listener
  5. Daemon Queue Worker
  6. Push Queues
  7. Failed Jobs

Security

  1. Configuration
  2. Storing Passwords
  3. Authenticating Users
  4. Manually Logging In Users
  5. Protecting Routes
  6. HTTP Basic Authentication
  7. Password Reminders & Reset
  8. Encryption
  9. Authentication Drivers

Session

  1. Configuration
  2. Session Usage
  3. Flash Data
  4. Database Sessions
  5. Session Drivers

SSH

  1. Configuration
  2. Basic Usage
  3. Tasks
  4. SFTP Downloads
  5. SFTP Uploads
  6. Tailing Remote Logs
  7. Envoy Task Runner

Templates

  1. Controller Layouts
  2. Blade Templating
  3. Other Blade Control Structures
  4. Extending Blade

Testing

  1. Introduction
  2. Defining & Running Tests
  3. Test Environment
  4. Calling Routes From Tests
  5. Mocking Facades
  6. Framework Assertions
  7. Helper Methods
  8. Refreshing The Application

Validation

  1. Basic Usage
  2. Working With Error Messages
  3. Error Messages & Views
  4. Available Validation Rules
  5. Conditionally Adding Rules
  6. Custom Error Messages
  7. Custom Validation Rules
  8. Database

Basic Database Usage

  1. Configuration
  2. Read / Write Connections
  3. Running Queries
  4. Database Transactions
  5. Accessing Connections
  6. Query Logging

Query Builder

  1. Introduction
  2. Selects
  3. Joins
  4. Advanced Wheres
  5. Aggregates
  6. Raw Expressions
  7. Inserts
  8. Updates
  9. Deletes
  10. Unions
  11. Pessimistic Locking
  12. Caching Queries

Eloquent ORM

  1. Introduction
  2. Basic Usage
  3. Mass Assignment
  4. Insert, Update, Delete
  5. Soft Deleting
  6. Timestamps
  7. Query Scopes
  8. Global Scopes
  9. Relationships
  10. Querying Relations
  11. Eager Loading
  12. Inserting Related Models
  13. Touching Parent Timestamps
  14. Working With Pivot Tables
  15. Collections
  16. Accessors & Mutators
  17. Date Mutators
  18. Model Events
  19. Model Observers
  20. Converting To Arrays / JSON

Schema Builder

  1. Introduction
  2. Creating & Dropping Tables
  3. Adding Columns
  4. Renaming Columns
  5. Dropping Columns
  6. Checking Existence
  7. Adding Indexes
  8. Foreign Keys
  9. Dropping Indexes
  10. Dropping Timestamps & SoftDeletes
  11. Storage Engines

Migrations & Seeding

  1. Introduction
  2. Creating Migrations
  3. Running Migrations
  4. Rolling Back Migrations
  5. Database Seeding

Redis

  1. Introduction
  2. Configuration
  3. Usage
  4. Pipelining
  5. Artisan CLI

Artisan CLI

  1. Introduction
  2. Usage

Artisan Development

  1. Introduction
  2. Building A Command
  3. Registering Commands
  4. Calling Other Commands

The Leanpub 60 Day 100% Happiness Guarantee

Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.

Now, this is technically risky for us, since you'll have the book or course files either way. But we're so confident in our products and services, and in our authors and readers, that we're happy to offer a full money back guarantee for everything we sell.

You can only find out how good something is by trying it, and because of our 100% money back guarantee there's literally no risk to do so!

So, there's no reason not to click the Add to Cart button, is there?

See full terms...

Earn $8 on a $10 Purchase, and $16 on a $20 Purchase

We pay 80% royalties on purchases of $7.99 or more, and 80% royalties minus a 50 cent flat fee on purchases between $0.99 and $7.98. You earn $8 on a $10 sale, and $16 on a $20 sale. So, if we sell 5000 non-refunded copies of your book for $20, you'll earn $80,000.

(Yes, some authors have already earned much more than that on Leanpub.)

In fact, authors have earned over $14 million writing, publishing and selling on Leanpub.

Learn more about writing on Leanpub

Free Updates. DRM Free.

If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).

Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.

Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.

Learn more about Leanpub's ebook formats and where to read them

Write and Publish on Leanpub

You can use Leanpub to easily write, publish and sell in-progress and completed ebooks and online courses!

Leanpub is a powerful platform for serious authors, combining a simple, elegant writing and publishing workflow with a store focused on selling in-progress ebooks.

Leanpub is a magical typewriter for authors: just write in plain text, and to publish your ebook, just click a button. (Or, if you are producing your ebook your own way, you can even upload your own PDF and/or EPUB files and then publish with one click!) It really is that easy.

Learn more about writing on Leanpub