Organizing routes in Laravel 4

Reading time ~1 minute

Laravel 4 is centered almost completely around routing. So organizing it is a must. There is no default organization for routes, but we can easily fix this.

Add the following to your `bootstrap/start.php` file:

 * Require Routes for better organization.
$files = new FilesystemIterator(dirname(dirname(__FILE__)) . '/app/routes');
foreach ($files as $file)
    if ($file->isFile())
        require $file->getPathname();
Then you can create a `routes` directory inside the `app` folder and save your routes in there. You can name them whatever you want, but I like to name them after the controller I am working on.

Happy coding!

Asyncio Basics Python 35

# Asyncio basics in pythonPython 3.5 brought with it asyncio. An event loop based paradigm previously available as a library but now it i...… Continue reading

Quick Laravel/Lumen install with Docker!

Published on March 02, 2016

PHP To Python

Published on February 24, 2016