Help for this page

Select Code to Download


  1. or download this
    opendir DIR, $dir;
    while ($file = readdir DIR) {
        if ($file =~ /\.jpg$/) {
    ...
        }
    }
    closedir DIR;
    
  2. or download this
    use HTML::Template;
    
    $t = HTML::Template->new(filename => 'dropdown.tmpl');
    $t->param(IMAGES => \@images);
    print "Content-Type: text/html\n\n", $t->output;
    
  3. or download this
    <form action="">
    <select name="images">
    <TMPL_LOOP IMAGES>
    <option><TMPL_VAR image></option>
    </TMPL_LOOP>
    </form>
    
  4. or download this
    #!/usr/bin/perl -w
    use strict;
    use vars qw($my $vars $are $here);