package Customizer::ItemCGI;

use strict qw(vars);
use vars qw(@ISA @EXPORT);
use Exporter;

use Customizer::Item;

@ISA = qw(Customizer::Item);
@EXPORT = qw(attributes);

attributes qw();

################################################################
sub AsSelect($)
{
    my $self = shift;

    my $name = $self->name;
    my $data = $self->data;
    my $value = 
    my $rtn = sprintf(qq(%d: %s : ), $self->number, $self->comment);
    if ($self->type eq 'bool'){
	my ($check_yes, $check_no);
	if ($data){
	    $check_yes = "checked";
	} else {
	    $check_no = "checked";
	}
	$rtn .= qq(<input type="radio" name="$name" value="1" $check_yes>Yes
		   <input type="radio" name="$name" value="0" $check_no>No<br>);
    } else {
	$rtn .= qq(<input type="text" name="$name" value="$data"><br>);
    }
    return $rtn;
}
1;
