Ajouter un commentaire

Dot PHP

Par:
fredericmazue

mer, 21/04/2004 - 00:00

Il s'agit d'un concept spécial de développement par conposants Web comme sous ASP.NET. Mieux qu'un grand discours voici une petite application développée en DOT PHP.



Comme vous pourrez le constater le code de l'évènement "click sur un bouton" ($obj2->on_click) est représenté sous la forme d'une fonction "function first_event".

$dp = new web('dp');
$dp->render_start();

function form_create() {

global $dp;

$obj2 = new button('obj2');
$obj2->caption = 'my button';
$obj2->on_click = 'first_event';
$obj2->render();

$lab = new llabel('lab');
$lab->render();

}

function first_event() {

global $dp;
global $lab;

$lab->caption = 'You clicked the button';
$lab->render();

}

$dp->render_end();
?>

Filtered HTML

Plain text

CAPTCHA
Cette question permet de vérifier que vous n'êtes pas un robot spammeur :-)
 H  H  H  H   QQQ     SSS    CCC 
H H H H Q Q S C
HHHH HHHH Q Q SSS C
H H H H Q QQ S C
H H H H QQQQ SSSS CCC
Q