Anita Ashford - 2005-01-29

At the bottom of this message are my $get_data_sub lines and the template lines in question.

I'm using the columns template shown in the documentation. How do I add links or javascript to the data inside the column. For instance, make the product name a link or add a javascript function to the image?

The template shows the <form> tags placed outside the <table> tags. If you need a <form> inside the table, for instance, an add_to_cart button, how is that handled?

Thank you in advance for any assistance.

Ashford

##### from the get data subroutine #####
my $get_data_sub = sub {
my ($offset, $rows) = @_;
my @return_array;

for (my $x = 0; $x < $rows; $x++) {
   push(@return_array, [
       $data[$offset + $x]{name},
       $data[$offset + $x]{code},
       $data[$offset + $x]{image}
       ]
   );
}
     return \@return_array;
  }

##### from the template #####
<TMPL_LOOP NAME="PAGER_DATA_LIST">
<TR>
<TD BGCOLOR=#ffffff><TMPL_VAR NAME="PAGER_DATA_COL_0"></TD>
<TD BGCOLOR=#ffffff><TMPL_VAR NAME="PAGER_DATA_COL_1"></TD>
<TD BGCOLOR=#ffffff><TMPL_VAR NAME="PAGER_DATA_COL_2"></TD>
</TR>
</TMPL_LOOP>

##### eof message #####