Created
July 11, 2009 16:02
-
-
Save biakaveron/145295 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// bootstrap.php | |
Route::set('artist','(sales(/<month>(/<day>)))') | |
->defaults(array( | |
'controller' => 'sales', | |
'action' => 'month', | |
)); | |
// classes/sales.php | |
class Controller_Sales extends Controller { | |
public function action_month() { | |
echo $this->request->param('month', 'month not set'); | |
echo $this->request->param('day', 'day not set'); | |
} | |
} | |
// classes/contacts.php | |
class Controller_Contacts extends Controller { | |
public function action_profile() { | |
echo Request::factory('sales/july')->execute(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment