PHP Classes

File: examples/radio.php

Recommend this page to a friend!
  Classes of Michele Brodoloni   PHP Dialog   examples/radio.php   Download  
File: examples/radio.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP Dialog
Create console based UIs with the dialog program
Author: By
Last change:
Date: 11 years ago
Size: 436 bytes
 

Contents

Class file image Download
#!/usr/bin/php
<?php

require_once '../include/class.dialog.php';

$dialog = Dialog::factory('radio');

$options = array(
    array(
'one', "One", false),
    array(
'two', "Two", true),
    array(
       
'id' => 'five',
       
'caption' => 'Five',
    )
);

$dialog->returnCaption(false)
       ->
setCaption('test')
       ->
addOptions($options)
       ->
addOption('six', "Six");

$res = $dialog->show();

echo
"Risultato: $res\n";
var_dump($res);

exit();