My personal blog developed on the Slim Framework

Overview

nesbot.com

I am making the source code of my personal site available publicly in case it helps anybody. It's developed using the Slim Framework.

I am working on a blog post about the rewrite and it should get posted in the next few days finally got posted: http://nesbot.com/2013/1/11/this-blog-trimmed-the-fat-now-powered-by-slim-2.

Installation

The dependencies are resolved using composer.

If you have PHP 5.4+ installed you can be up and running in 10 seconds +/- 5 seconds for slower typers or copy & pasters.

git clone git://github.com/briannesbitt/nesbot.com.git
cd nesbot.com
curl -s http://getcomposer.org/installer | php
php composer.phar update
touch env.local
cd public
php -S 127.0.0.1:80

Thats it. Open a browser to http://127.0.0.1/ and you should see the site as you see at nesbot.com

If you are running a version of PHP 5.3, the setup for nginx and apache are shown below. Either way you will still need to perform the first 5 commands from above.

Nginx

http://docs.slimframework.com/pages/routing-url-rewriting/#nginx

The root should be pointing to the /your/install/path/nesbot.com/public directory of the project.

Apache

http://docs.slimframework.com/pages/routing-url-rewriting/#apache_and_mod_rewrite

As shown you will need to create a .htaccess file in the 'public/' folder. I try not to use apache if possible so there isn't one in the repo.

The DocumentRoot should be pointing to the /your/install/path/nesbot.com/public directory of the project.

How do I?

Bundle assets

To generate the posts file, compile the less and minify/combine the js run the following command from the project root.

php bundle.php

This command is run on every page load when in local (development) mode.

Add a post

  • Create a new file in views/posts/ with a format of yyyy-m-d-slug.php.
  • The first line in the file needs to be .
  • Run php genposts.php from the project root. (this is automatically ran when in local mode)

This will parse the files in the views/posts/ directory and extract the date, slug and title for each post and generate a new posts.php.

See the posts already in there for examples of functions you can use while writing posts.

What about... ?

This isn't your grandma's blog... read the code and figure it out.

Author

Brian Nesbitt - [email protected] - http://twitter.com/NesbittBrian

License

Source code

The code for this project is licensed under the MIT License.

Blog posts

You are free to copy, distribute, modify or display any or all of the blog post material. However you may not use it, in any way, for commercial purposes.

Previous versions

Previously the site was developed against different versions of the Play framework.

You might also like...
Juliangut Slim Framework Doctrine handler middleware

Juliangut Slim Framework Doctrine handler middleware Doctrine handler middleware for Slim Framework. Slim3 version Doctrine integration service for Sl

This Slim Framework middleware will compile LESS CSS files on-the-fly using the Assetic library

This Slim Framework middleware will compile LESS CSS files on-the-fly using the Assetic library. It supports minification and caching, also via Asseti

Strict PSR-7 implementation used by the Slim Framework

Strict PSR-7 implementation used by the Slim Framework, but you may use it separately with any framework compatible with the PSR-7 standard.

Slim Framework custom views

Slim Views This repository contains custom View classes for the template frameworks listed below. You can use any of these custom View classes by eith

Access control middleware for Slim framework

Slim Access Access control middleware for Slim framework. Supported formats IPv4 and IPv6 addresses CIDR notation all keyword Installation composer re

Redis cache middleware for Slim framework

RedisCache Redis cache middleware for Slim framework. Installation composer require abouvier/slim-redis-cache Usage Cache every successful HTTP respo

Slim Framework using Jade for templates

Welcome to Slim-Jade What? This is a boilerplate. It's the Slim Framework with jade.php to render views Why? I like the Sinatra style MVC and love Jad

The Slim PHP micro framework paired with Laravel's Illuminate Database toolkit.

Slim & Eloquent The Slim PHP micro framework paired with Laravel's Illuminate Database toolkit. Getting started # Download composer curl -s https://ge

A set of shady Slim Framework middlewares that can solve some annoyances...

Shady A set of shady Slim Framework middlewares that can solve some annoyances... What does it contain? Available middlewares: ApacheVirtualHostFix Ur

Owner
Brian Nesbitt
Brian Nesbitt
FlyCubePHP is an MVC Web Framework developed in PHP and repeating the ideology and principles of building WEB applications, embedded in Ruby on Rails.

FlyCubePHP FlyCubePHP is an MVC Web Framework developed in PHP and repeating the ideology and principles of building WEB applications, embedded in Rub

Anton 1 Dec 21, 2021
Slim is a PHP micro framework that helps you quickly write simple yet powerful web applications and APIs.

Slim Framework Slim is a PHP micro-framework that helps you quickly write simple yet powerful web applications and APIs. Installation It's recommended

Slim Framework 11.5k Jan 4, 2023
Slim Framework - Prerequisite Checker

Slim Framework - Server Configuration Checker Upload the file check.php to your webserver Browse to the file: https://example.com/check.php Check the

Daniel Opitz 6 Aug 30, 2022
REST APIs using Slim framework. Implemented all CRUD operations on the MySql database

PHP REST API using slim framework and CRUD operations ?? Hi there, this is a simple REST API built using the Slim framework. And this is for the folks

Hanoak 2 Jun 1, 2022
A Slim PHP MVC framework built just for fun!

Aura Framework A Slim PHP MVC framework built just for fun! en: Note: This repository only contains the core code of the Aura framework. If you want t

Murilo Magalhães Barreto 2 Dec 16, 2021
Slim Framework skeleton application with MVC Schema

Slim Framework skeleton application with MVC Schema

JingwenTian 9 Apr 29, 2021
This repository contains a library of optional middleware for your Slim Framework application

Slim Framework Middleware This repository contains a library of optional middleware for your Slim Framework application. How to Install Update your co

Slim Framework 47 Nov 7, 2022
A curated list of awesome tutorials and other resources for the Slim micro framework

Awesome Slim A curated list of awesome tutorials and other resources for the Slim micro framework Table of Contents Essentials Tutorials Packages and

Sawyer Charles 466 Dec 8, 2022
Slim Framework 3 Skeleton Application + PagSeguro Lib

Slim Framework 3 Skeleton Application + PagSeguro Lib Aplicação simples para geração do Token para pagamentos no PagSeguro (método transparente) e env

Raí Siqueira 1 Feb 26, 2018
Plates Template Integration for Slim micro framework 3

Plates Template Integration for Slim micro framework 3 Render your Slim 3 application views using Plates template engine. Install Via Composer $ compo

Projek XYZ 26 Feb 5, 2022