GithubHelp home page GithubHelp logo

mmg1 / flash Goto Github PK

View Code? Open in Web Editor NEW

This project forked from 5l1v3r1/flash

0.0 1.0 0.0 290 KB

Flash is a high performance, open source web application framework.

Home Page: https://rajkumardusad.github.io/flash

License: MIT License

PHP 98.93% HTML 1.07%

flash's Introduction

Flash Framework

Flash Logo

Flash is a high performance, open source web application framework. Flash web framework follows the MVT (Model-View-Template) architectural pattern or you can say MVC (Model-View-Controller) pattern, because controller is handle by the system. Flash is fast, lightweight, powerful, simple and easy to use.

Flash allows user to create web applications in easy and simplest way, in Flash framework user can create their own services and library.

Features

  • Fast and Powerful.
  • Extremely Light Weight.
  • MVT Architecture.
  • You can build RESTful APIs faster.
  • Security and XSS Filtering.
  • Simple and Easy to learn.
  • Easy to Deploy on any server.

Installation

Flash web framework is for PHP, so it's requires PHP 5.6 or newer. now you won’t need to setup anything just yet.

Flash can be installed in few steps:

  • Download the Flash files.
  • Unzip the package.
  • Upload all the Flash folders and files (system, application, .htaccess, index.php) on the server.

That's it, in the Flash web framework there is nothing to configure and setup. it's always ready to go.

Simple Example

A simple Hello, World web application in Flash web framework.

Create View

Let’s write the first view. Open the app/views.php file and put the following PHP code in it:

class view extends Views {

  function __construct() {
    parent::__construct();
  }

  function hello_world() {
    return $this->response("hello, world !!");
  }
}

Hello world view is created now map this view with URLs.

Map URLs with Views

Let's create URL and map with views. open app/urls.php file and put the following code in it:

//include views to route URLs
require_once("views.php");

$urlpatterns=[
  '/' => 'view.hello_world',
];

Now a simple hello world web app is created.

Simple Web Api Example

A simple Hello, World web Api in Flash web framework.

Create View

Let’s write the first view. Open the app/views.php file and put the following PHP code in it:

class view extends Views {

  function __construct() {
    parent::__construct();
  }

  function hello_world() {
    $data = [
      'status' => true,
      'data' => 'Hello, World',
    ];
    //Send Json Response
    return $this->response_json($data);
  }
}

Hello world view is created now map this view with URLs.

Map URLs with Views

Let's create URL and map with views. open app/urls.php file and put the following code in it:

//include views to route URLs
require_once("views.php");

$urlpatterns=[
  '/' => 'view.hello_world',
];

Now a simple Hello, World web Api is created.

Documentation

License

MIT License

flash's People

Contributors

rajkumardusad avatar

Watchers

James Cloos 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.