-
Notifications
You must be signed in to change notification settings - Fork 10
Devin Smith edited this page Dec 8, 2015
·
3 revisions
The Tipsy app can be accessed either by it's static methods, object methods, or a combination of both.
$t = new Tipsy\Tipsy;
$r->router()->home(function() {
echo "it's good to be home";
});
$t->run();
Tipsy\Tipsy::router()->home(function() {
echo "it's good to be home";
});
Tipsy\Tipsy::run();
or
use Tipsy\Tipsy;
Tipsy::router()->home(function() {
echo "it's good to be home";
});
Tipsy::run();
You probably only need this if you are doing weird stuff.
use Tipsy\Tipsy;
$tipsy = Tipsy::app();
$tipsy->router()->home(function() {
echo "it's good to be home";
});
Tipsy::run();
- Home
- Getting Started
- Server Config
- Installation
- Installing Composer
- App
- Route Shorthand
- Config
- Routes
- Methods
- Controller Types
- Params & Regex
- Aliases
- Dependency Injection
- Advanced Routing
- Services
- User Defined Services
- Built in Services
- Middleware
- Views
- Templates
- Scope
- Resource
- Factory
- Looper
- Examples
- Plugins
- About