News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

SitePoint PHP Blog:
Build a Database with Eloquent, Faker and Flysystem
August 28, 2014 @ 11:55:09

In the latest post to the SitePoint PHP blog Aleksander Koko continues with his series about creating an application with PHP and EmberJS with a look at building databases. In the first part of the series he introduced the main toolset and set up a simple Laravel application inside of a Homestead instance. This latest post builds on that platform.

In this part, we will create the structure of the database. We will create the tables using migrations and seed the database using seeders. Also, you will learn how to grab some random images from LoremPixel and put them on the filesystem using Flysystem. You'll also be adding some randomly generated data using the Faker library. Much like with part 1, you can download this part's code from github.

He shows you how to get all the needed libraries installed and run the migrate command to create the needed tables. He also helps you set up a Dropbox application so you can use their API and configure the application with your API settings. Next he modifies the migrations and seeds the sample data. Next up he makes the models for each of the tables and integrates Faker to populate them with better seed data, making seeder classes to handle some of the more custom logic.

0 comments voice your opinion now!
database eloquent faker flysystem dropbox seed data tutorial emberjs

Link: http://www.sitepoint.com/build-database-eloquent-faker-flysystem/

blog comments powered by Disqus

Similar Posts

DevShed: Building Your Own System Tray Application Using PHP-GTK

Inside DealTaker Blog: Kohana PHP 2.3.x Tutorial Part 1

Zend Developer Zone: Zend Framework Articles and Tutorials

Oracle Technology Network: DeployPHP Series, Part 5 - Zend Core for Oracle Quick Start

Community News: Sara Golemon & Christopher Jones - First Day Summaries of php|works


Community Events





Don't see your event here?
Let us know!


release introduction series composer package opinion version update library application framework community podcast voicesoftheelephpant tool security symfony interview laravel language

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework