PROXY  WHOIS  RQUOTE  TEXTS  SOFT  FOREX  BBOARD
 Music  Philosophy  Code  Literature  Russian

= ROOT|Technical|Code_Examples|Perl|site_perl|HTML|AsSubs.pm =

page 2 of 2



           frame frameset noframe
	  );

for (@TAGS) {
	my $code;
	$code = "sub $_ { _elem('$_', \@_); }\n" ;
	push(@EXPORT, $_);
	eval $code;
	if ($@) {
		die $@;
	}
}

=head1 Private Functions

=head2 _elem()

The _elem() function is wrapped by all the html 'tag' functions. It
takes a tag-name, optional hashref of attributes and a list of content
as parameters.

=cut

sub _elem
{
    my $tag = shift;
    my $attributes;
    if (@_ and defined $_[0] and ref($_[0]) eq "HASH") {
	$attributes = shift;
    }
    my $elem = HTML::Element->new( $tag, %$attributes );
    $elem->push_content(@_);
    $elem;
}

1;
=2=
THE END

1| < PREV = PAGE 2 =

UP TO ROOT | UP TO DIR | TO FIRST PAGE

Google
 

E-mail Facebook Google Digg del.icio.us BlinkList Fark Furl Ma.gnolia Netscape NewsVine Reddit Slashdot Spurl StumbleUpon Technorati YahooMyWeb LiveJournal Blogmarks TwitThis Live News2.ru BobrDobr.ru Memori.ru MoeMesto.ru

0.01843 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)