Mikecao flight. So when you go to redirect, you simply need to provide the route you're going to without worrying about the structure. Calling call_user_func_array is much slower than invoking the function directly, on average 3 times slower. Hello, is there a way to disable autoloading inside Flight and Use composer for autoloading instead? I need Flight to go through composers autoloader to be able to use it with goaop. But if I call a method/object that has not been mapped/registered before, no exception is thrown. Con este podríamos crear un API en donde realizaríamos transacciones a una base de datos, enviando nuestros datos desde Drupal para recibir una respuesta desde Flight. If running from the root, the base is /, while under a subdirectory it would be /subdir. Contribute to flightphp/core development by creating an account on GitHub. Is there a changelog where I could read what Merged mikecao merged 1 commit into mikecaomaster from saschanosdev-json-check Jun 8, 2021 merged 1 commit into : from 0 Commits 1 Checks 0 Files changed …throws an Exception, clarified the return class of Flight::app () ghost mentioned this pull request Oct 12, 2016 Extending Flight - unmapped/-registered methods #203 Closed mikecao merged commit b4b4346 into mikecao:master Oct 12, 2016 Owner Non-static method Underscore\Underscore::sortBy () cannot be called statically As mentionned in mikecao#396, the request scheme was not as documented, returning SERVER_PROTOCOL instead. A tiny php framework based on flight and medoo. Flight is one of the fastest PHP frameworks out there. 5k Pick a username Email Address Password Route /test/* will not match /test/test/test/test Temporary Solution - the base route needs to be passed with to matchUrl in route call if the base route is not a ". Dec 30, 2022 · mikecao/flight, What is Flight? Flight is a fast, simple, extensible framework for PHP. It checks up to 5 parameters before trying the defaults, which should cover a majority of cases. This is the maintained fork of mikecao/flight Jul 22, 2025 · Flight is a fast, simple, extensible framework for PHP. Taking a look at Flight's Registering Classes, it only appears to support constructing classes by invoking their constructor. If you pass in an additional callback parameter, it will be executed immediately after class construction. I now run a start-up, Umami. Since it's been moved we've added features like middleware, route grouping, DIC, and other features. This is the maintained fork of mikecao/flight Jul 4, 2024 · Earlier this year the original creator of Flight Mike Cao graciously offered to transfer ownership of mikecao/flight over to a new Flight PHP organization. Flight is a fast, simple, extensible framework for PHP. 5k We read every piece of feedback, and take your input very seriously Hallo ! Ich habe eine Anfängerfrage. ́ Example 1 - Current way json_encode(Flight::request()->data->getData() How to implement URL aliases? · Issue #195 · mikecao/flight · GitHub mikecao / flight Public Notifications Fork 396 Star 2. 5k Pick a username Email Address Password Aug 10, 2019 · Json string is correctly returned, but the response status is 500. We read every piece of feedback, and take your input very seriously mikecao / flight Public Notifications Fork 396 Star 2. Contribute to mikecao/flightphp. The primary programming language of flight is PHP. This allows you to perform any set up procedures for your new object. It will be useful to call json_encode directly for a Collection object, without an additional call to Collection->getData(). Is there any way of adding/binding it with flight? The latest tag 1. handle_errors', false); Jul 26, 2025 · Flight is a fast, simple, extensible framework for PHP. If you just need the data in json format then use json_encode. May 4, 2013 · The idea behind the base is so Flight can run from a subdirectory. Is there a way · Issue #473 · mikecao/flight · GitHub Skip to content Toggle navigation Sign up Product Automate any workflow Packages Host and manage packages Find and fix vulnerabilities Codespaces Instant dev environments Copilot Write better code with AI Code review Manage code changes Plan and track work Discussions Collaborate outside of code Explore I found a case that I need to use JSON_UNESCAPED_UNICODE (integrating a system that the other end isn't mine and I can't fix the encoding). One issue though, is that there is no built in easy way to force trailing slash or disable it alto In working with Flight, I have found many times that If I render the same template consecutively, they will inherit the values from the previously rendered template unless I redefine them in the su I'm using flight to build a simple rest API. base_url and flight. 3. The 404 not found means you're not matching some route. json) for flight and saw that there was a master-dev version, but no release versions, even thou TinyMe A tiny php framework based on flight and medoo. mikecao self-assigned this Mar 17, 2015 Copy link Author mikecao / flight Public Notifications Fork 401 Star 2. iaidonline. wtf composer? · Issue #261 · mikecao/flight · GitHub mikecao / flight Public Notifications Fork 396 Star 2. Apr 21, 2023 · Flightには多くのメリットがありますが、すべてのプロジェクトにFlightが適しているわけではなく、いくつかのデメリットも存在します。 Jun 25, 2016 · The text was updated successfully, but these errors were encountered: Flight is a fast, simple, extensible framework for PHP. Flight will either use /login or /subdir/login depending on the base. `request->secure` is also based on the scheme now as `$_SERVER ['HTTPS']` is unreliable for this purpose. I would just create a global. php の PHP mikecao/flight Flight is a fast, simple, extensible framework for PHP. I used to work at Adobe. The same is true with invoking ReflectionClass. I guess when using Flight::path () by requiring files to load class , you no need to use these namespace-less-classes. Earlier this year the original creator of Flight Mike Cao graciously offered to transfer ownership of mikecao/flight over to a new Flight PHP organization. 2 to 1. mikecao closed this as completed Nov 8, 2015 If no key is passed in, clear all variables. This is in contrast to frameworks such as Silex, which allow you full control over constructing Open aleferri wants to merge 7 commits into mikecao: master base:master Could not load branches Branch not found: { { refName }} { { refName }} Could not load tags Nothing to show Sep 19, 2022 · As there seems to be a decent amount of interest among Flight users (myself included) in implementing middleware / route filtering (#276, #350), I decided to write some experimental code today. Dec 30, 2023 · Hey everyone, I've reached out to mikecao via twitter and email to help maintain this repo but haven't received a response from him, so I'm going to assume he won't maintain this repo going forward Jul 26, 2025 · Flight is a fast, simple, extensible framework for PHP. Flight requires PHP 5. Apr 24, 2017 · It would be nice to get the Request Headers from Flight::request() mikecao/flight is an open source project licensed under MIT License which is an OSI approved license. php file that defines your functions in the global namespace which proxy to the Flight methods. Flight::start is a built-in method that starts the whole Flight framework and parses the endpoint and reutrns the appropriate response as per your route methods each time you navigate to an endpoint. Sep 16, 2022 · Hi, i'm trying to make it work on nginx, and just want to understand what im doing wrong So, here is my nginx cfg where i put try_files from your Installation guide: server { listen 80 default_serv Dec 28, 2021 · #3 **/vendor/mikecao/flight/flight/core/Loader. #0 /var/www/html/exams. I love writing software and I am passionate about open source development. it/public_html/index. Flight treats all urls relative to itself, which or Mar 16, 2014 · As flight sessions start in php?Afaik Flight is so minimalistic it would advise to include some other session handler. Slim is kind of a Flight+session+flash messages+logging, Silex is similar (a micro-Symfony) and in the entire Jun 5, 2015 · Combination of flight. Maximum 100 characters, markdown supported. It immediately sends a HTTP response with the json data. If you want a more complete framework out of the box there are multiple levels "up" from the bare bones of Flight. php (81): flight\core\Loader->newIns" Feb 15, 2013 · Hello, I was wondering whether there is a proper / more sensible way to go about altering a Flight Requests base path (without hacking the core). An extensible micro-framework for PHP. This is the maintained fork of mikecao/flight What is Flight? Flight is a fast, simple, extensible framework for PHP. Then you can just include that file whenever needed and it I just run composer update and this updated flight from 1. Flight est un micro framework PHP intégrant notamment la gestion du routing, les views et bien d’autres choses. 5k Pick a username Email Address Password In the official definition of Flight's routes, it is allowed to express the class callables as an array consisting of [string, string] // static class or [object , string] // object instance In the second case, already in the definition we have to write: [new MyClass (), 'myMethod'] which immediately causes the class constructor execution, and this can cause problems. . Installation de Flight PHP # $ composer require mikecao/flight Flight::json () having issues with ' character (unicode?) · Issue #383 · mikecao/flight · GitHub mikecao / flight Public Notifications Fork 401 Star 2. org/vendor/mikecao/flight/flight/core/Dispatcher. Flight also has zero dependencies. Learn more about blocking users. "," *"," * @param string $key Key"," */"," public function clear($key = null)"," {"," if (null === $key) {"," $this->vars = [];"," } else {"," unset($this->vars[$key]);"," }"," }",""," /**"," * Renders a template. Jul 29, 2018 · Flightの使い方です。 Nginx で使う方法です。 インストール 例えば、/var/www/tmp/jul2901 で、 composer require mikecao/flight index. Flight is built to be extremely extensible to go beyond those features. With the code proposed by Hi @mikecao, This is a really nice project! Im so glad to integrate it into a big project of mine. Feb 23, 2014 · The DocumentManager class is intended to be constructed through its create() static factory method, as is shown in the Getting Started and Introduction documentation entries. 7 is quite old and misses a number of pull requests. I was trying "before" which looks like an answer, but there is something t Oct 26, 2018 · Flight::before / Flight::after executes before or after any Flight methods OR any custom methods. mike cao I am a software developer living in San Francisco, CA. Unterstützt 'flight' die Verwendung von 'namespace' ? Mit freundlichen Grüßen Stephan mikecao commented Mar 17, 2015 You are right it should be uppercase. Can you update the public composer repository to the current master version? mikecao commented Apr 10, 2013 The code is like that for performance. TinyMe using third-party components, you can get help from their offical website. Any recommendations for handling authentication? Hello, I'm using Flight to create an API for a service. base_route could work, but would be nice to handle files moved to a subdirectory globally by a path prefix used for routes, views, Mike Cao mikecao Prevent this user from interacting with your repositories and sending you notifications. ini but flight still output details of 500 Internal Server Error Hello problem router $Path in flight::path($Path) in server web but in localhost not problem thanks. The callback function takes one parameter, an instance of the new object. Flight::map('bar', functio Hi, I am interested to use a dependency container(Ex: PHP-DI) with Flight. Dec 30, 2022 · As @mikecao has made clear that he's not interested in adding this kind of code to the main flight library, this draft code is written as an extension. Flight website. Its kernel based on mikecao/flight , official website : http://flightphp. Server does not log any errors. Flight vous permet de créer rapidement et facilement des applications Web (RESTful). it/public_html/vendor/mikecao/flight/flight/Flight. php (86): flight\Engine->handleError () #1 /var/www/html/exams. php(99): Flight::__callStatic() Hi Well this is not really an issue per se, but a "nice to have". In order for this to work, I've dropped support for using Flight without Composer. com/mikecao/flight . Flight enables you to quickly and easily build RESTful web applications. 5 but I have no idea what has changed and if I have now to make some code changes. Contribute to patelflow/flight development by creating an account on GitHub. Flight's router is already really fast itself, so I don't think it's worth switching just for a small performance gain and lose functionality. Oct 20, 2017 · The Flight:json method doesn't return anything. Its lightweight core means less overhead and more speed—perfect for both traditional apps and modern AI-powered projects. Created by ycrao. You can reach out to me on Twitter, LinkedIn or by email. I'd like to auto-describe as much as possible (that is without writing a README on the APIs exposed) Is there a way to more or less automatic Is there a PHP 7 version in the works? The error handling has changed quite a bit. As @mikecao has made clear that he's not in An extensible micro-framework for PHP. The PHP Package RepositoryPHP flightphp/core Flight is a fast, simple, extensible framework for PHP. 3 or greater, and is released under the MIT license. If you want to get PUT content you'll have to do Flight::request ()->getBody (). I'm going to publish a least one version to packagist, but not until I've studied proper PSR implementation. mikecao commented Dec 18, 2013 I don't think I would ever implement a pollute method into the framework itself since it would be cumbersome to deal with function name collisions without diving into the code. com development by creating an account on GitHub. "," *"," * @param string $file Template file"," * @param array $data Template data Flight PHP # Flight est un framework performant, simple et extensible pour PHP. The `getScheme` function is now used to handle common cases (HTTPS, FORWATED_PROTO, ). php (125): flight\net\Request->__construct () #4 **/vendor/mikecao/flight/flight/core/Loader. ". #10 /var/www/fondazionemia. Changes: Renamed directories to match class names: flight/co Mar 4, 2014 · Hi all, trying flight framework, I was looking at a way to athenticate a user and its rights before some routes rendering. The request's data property comes from PHP's $_POST variable. // The callback will be passed the object that was constructedFlight :: register ( 'db', 'PDO', array ( 'mysql:host=localhost;dbname=test', 'user An extensible micro-framework for PHP. mikecao closed this as completed Jun 23, 2015 Extending using the map/register method works like a charm. php (186): {closure} () #2 /var/www/html/exams. requi Jul 4, 2024 · Earlier this year the original creator of Flight Mike Cao graciously offered to transfer ownership of mikecao/flight over to a new Flight PHP organization. php (163): flight\core\Dispatcher ok class errors stopped when adding this line: Flight :: set ('flight. g. I was checking packagist (composer. 5k Pick a username Email Address Password This PR converts flight to use PSR-4 standards. Jul 26, 2025 · Flight is a fast, simple, extensible framework for PHP. org/admin_controllers/authenticationController. FlightPHP, Este framework tiene lo básico para agilizar la producción de un proyecto web, y hacerlo de la manera más liviana y simple posible. E. If you want to override GET to something else, you can do it. com/ , https://github. This is the maintained fork of mikecao/flight Flight is a fast, simple, extensible framework for PHP. This is the maintained fork of mikecao/flight An extensible micro-framework for PHP. This note will be visible to only you. Fixed in commit a32f2c2. Add an optional note: Please don't include any personal information such as legal names or email addresses. There are quite a few available through packagist. Jul 4, 2024 · Hey everyone! I figured it was time to showcase some of the new features that have been added to the Flight Framework for PHP. A couple of my personal projects are Astrofox, Flight, Sparrow and others on my Github. The issue has come about in a system I'm working on Jun 17, 2014 · Flight PHP is a micro framework for web applications. php(77): flight\core\Dispatcher::invokeMethod() #11 /var/www/fondazionemia. Apr 21, 2023 · Learn how to build a PHP web application using the Flight micro-framework, including setting up project structure, creating controllers, and rendering views. ycrao closed this as completed Nov 27, 2016 louishot commented Mar 10, 2023 I have configured display_errors = Off in php. I can't use Flight functions to do so since it doesn't pr mikecao commented Sep 25, 2015 That's because PUT data can be anything, not necessarily key value data, so we wouldn't know how to parse it. Flight takes care of some of the most common tasks a web application might need such as; routing, named parameters with friendly URL's, views/layouts, and errors handling. Ideally you should only override the method in a POST but I didn't want to limit people's options. What route are you trying to match? An extensible micro-framework for PHP. qbabrxo vivzki oleoqdz sfml cpbgv rmbdxw zkeoeq gsqtup nkkbbb ukoq