pluf2

pluf2 Commit Details


Date:2008-11-20 12:58:29 (16 years 1 month ago)
Author:Loic d'Anterroches
Branch:master
Commit:1aa66025b77aeb5a17860888652762b368e14fee
Parents: 42d7f1bee48e64d88b6523ca19e389a8621c2349
Message:Added the helloworld application.

Changes:

File differences

apps/helloworld/Hello/Views.php
1
2
3
4
5
6
7
8
<?php
class Hello_Views
{
public function hello($request, $match)
{
return new Pluf_HTTP_Response('Hello World!');
}
}
apps/helloworld/Hello/conf/hello.php
1
2
3
4
<?php
return array('hello_urls' => dirname(__FILE__).'/urls.php');
apps/helloworld/Hello/conf/urls.php
1
2
3
4
5
6
7
8
9
10
11
<?php
return array(
array(
'regex' => '#^/hello/$#',
'base' => '',
'priority' => 4,
'model' => 'Hello_Views',
'method' => 'hello'
)
);
apps/helloworld/index.php
1
2
3
4
5
6
7
<?php
set_include_path('../../src');
require 'Pluf.php';
Pluf::start(dirname(__FILE__).'/Hello/conf/hello.php');
Pluf_Dispatcher::loadControllers(Pluf::f('hello_urls'));
Pluf_Dispatcher::dispatch(Pluf_HTTP_URL::getAction());

Archive Download the corresponding diff file

Branches

Number of commits:
Page rendered in 0.06036s using 13 queries.