Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Creating a table using cgi.pm - a unique problem

by pg (Canon)
on Oct 29, 2005 at 00:47 UTC ( [id://503814]=note: print w/replies, xml ) Need Help??


in reply to Creating a table using cgi.pm - a unique problem

What we see here is the distributive property of HTML shortcuts. if you don't want a tg be part of the dirtibution list, then just take it out:

use CGI; my $cgi = CGI->new(); print $cgi->Tr( {-align=>LEFT, -valign=>TOP}, [ $cgi->td( [ $cgi->a({-href=>"..", -target=>"_new"}, $c +gi->img("blah.gif")), ] ) . $cgi->td( {-OnClick=>"javascript:dothis()" }, [ $cgi->a({}, "a"), $cgi->hidden(-name=>'name2', -value=>'b') +. $cgi->a("b"), $cgi->hidden(-name=>'name3', -value=>'c') +. $cgi->a("c") ] ) ] );

This gives:

<tr align="LEFT" valign="TOP"> <td><a target="_new" href=".."><img>blah.gif</img></a></td> <td onclick="javascript:dothis()"><a>a</a></td> <td onclick="javascript:dothis()"><input type="hidden" name="name2" va +lue="b" /><a>b</a></td> <td onclick="javascript:dothis()"><input type="hidden" name="name3" va +lue="c" /><a>c</a></td> </tr>

Replies are listed 'Best First'.
Re^2: Creating a table using cgi.pm - a unique problem
by sara2005 (Scribe) on Oct 31, 2005 at 14:37 UTC

    Thanks PG

    You exactly got what my requirement is.. This is exactly what I wanted.

    You are the best..

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://503814]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (5)
As of 2024-03-29 13:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found