Giter Site home page Giter Site logo

mini's Introduction

MINI - A naked barebone PHP application

MINI

MINI is an extremely simple and easy to understand skeleton PHP application, reduced to the max. MINI is NOT a professional framework and it does not come with all the stuff real frameworks have. If you just want to show some pages, do a few database calls and a little-bit of AJAX here and there, without reading in massive documentations of highly complex professional frameworks, then MINI might be very useful for you. MINI is easy to install, runs nearly everywhere and doesn't make things more complicated than necessary.

Features

  • extremely simple, easy to understand
  • simple but clean structure
  • makes "beautiful" clean URLs
  • demo CRUD actions: Create, Read, Update and Delete database entries easily
  • demo AJAX call
  • tries to follow PSR 1/2 coding guidelines
  • uses PDO for any database requests, comes with an additional PDO debug tool to emulate your SQL statements
  • commented code
  • uses only native PHP code, so people don't have to learn a framework

Requirements

  • PHP 5.3.0+
  • MySQL
  • mod_rewrite activated (tutorials below)

Installation

  1. Edit the database credentials in application/config/config.php
  2. Execute the .sql statements in the _installation/-folder (with PHPMyAdmin for example).
  3. Make sure you have mod_rewrite activated on your server / in your environment. Some guidelines: Ubuntu 14.04 LTS, Ubuntu 12.04 LTS, EasyPHP on Windows, AMPPS on Windows/Mac OS, XAMPP for Windows, MAMP on Mac OS

MINI runs without any further configuration.

When installing in a sub-folder

In case you run the script inside a sub-folder: Then the AJAX-calls will not work by default. To fix this, you'll need to add the folder's name to all paths in AJAX-calls in public/js/application.js. This will be fixed in future versions.

Security

The script makes use of mod_rewrite and blocks all access to everything outside the /public folder. Your .git folder/files, operating system temp files, the application-folder and everything else is not accessible (when set up correctly). For database requests PDO is used, so no need to think about SQL injection.

Goodies

MINI comes with a little PDO debugger tool, making it easy to see your PDO statements.

License

This project is licensed under the MIT License. This means you can use and modify it for free in private or commercial projects.

Support

If you want to support MINI, then rent your next server at A2Hosting or donate a coffee via PayPal, GitTip or Flattr.

TODO: documentation

coming soon

TODO: quick-start

coming soon

History

MINI is the successor of php-mvc. As php-mvc didn't provide a real MVC structure (and several people complained about that - which is totally right!) I've renamed and rebuild the project.

Dear haters, trolls and everything-sucks-people...

... MINI is just a simple helper-tool I've created for my daily work, simply because it was much easier to setup and to handle than real frameworks. For daily agency work, quick prototyping and frontend-driven projects it's totally okay.

I've written this unpaid, voluntarily, in my free-time and uploaded it on GitHub to share. It's totally free, for private and commercial use. If you don't like it, don't use it. If you see issues, then please write a ticket (and if you are really cool: I'm very thankful for any commits!). But don't bash, don't complain, don't hate. Only bad people do so.

Contribute

Please commit into the develop branch (which holds the in-development version), not into master branch (which holds the tested and stable version).

Changelog

November 2014

  • [panique] removed all "models", using one model file now
  • [panique] full project renaming, re-branding

October 2014

  • [tarcnux/panique] PDO debugging
  • [panique] demo ajax call
  • [panique] better output escaping
  • [panique] renamed /libs to /core
  • [tarcnux] basic CRUD (create/read/update/delete) examples have now an U (update)
  • [panique] URL is now config-free, application detects URL and sub-folder
  • [elysdir] htaccess has some good explanation-comments now
  • [bst27] fallback for non-existing controller / method
  • [panique] fallback will show error-page now
  • [digitaltoast] URL split fix to make php-mvc work flawlessly on nginx
  • [AD7six] security improvement: moved index.php to /public, route ALL request to /public

September 2014

  • [panique] added link to support forum
  • [panique] added link to Facebook page

August 2014

  • [panique] several changes in the README, donate-button changes

June 2014

  • [digitaltoast] removed X-UA-Compatible meta tag from header (as it's not needed anymore these days)
  • [digitaltoast] removed protocol in jQuery URL (modern way to load external files, making it independent to protocol change)
  • [digitaltoast] downgraded jQuery from 2.1 to 1.11 to avoid problems when working with IE7/8 (jQuery 2 dropped IE7/8 support)
  • [panique] moved jQuery loading to footer (to avoid page render blocking)

April 2014

  • [panique] updated jQuery link to 2.1
  • [panique] more than 3 parameters (arguments to be concrete) are possible
  • [panique] cleaner way of parameter handling
  • [panique] smaller cleanings and improvements
  • [panique] Apache 2.4 install information

January 2014

  • [panique] fixed .htaccess issue when there's a controller named "index" and a base index.php (which collide)

mini's People

Contributors

panique avatar alexgarrettsmith avatar bst27 avatar ad7six avatar antonisgr avatar bitdeli-chef avatar grahamcampbell avatar grrnikos avatar tarcnux avatar adamholte avatar

Watchers

James Cloos avatar Paul Brinkmeier avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.