3 <TITLE>test pirate page</TITLE>
7 <html><head><title>Select island</title></head><body>
8 <form action="/ucgi/~clareb/mason/something" method="get">
9 <select name="islandid">
11 my $sth=$dbh->prepare("SELECT islandid,archipelago,islandname
13 ORDER BY archipelago,islandname;");
17 % while ($row=$sth->fetchrow_hashref) {
18 <option value="<% $row->{'islandid'} |h %>"><% $row->{'archipelago'} |h %> -
19 <% $row->{'islandname'} |h %>
21 <input type=submit name=submit value="Go">
24 my $sth=$dbh->prepare(
25 "SELECT a.commodname,b.price,c.price,d.stallname,e.islandname
27 JOIN buy as b on a.commodid=b.commodid
28 JOIN buy as c on a.commodid=c.commodid
29 JOIN stalls as d on d.stallid=b.stallid
30 JOIN islands as e on e.islandid=d.islandid
31 WHERE a.commodname like 'Wood'
36 <table frame=box rules=all>
38 <tr><td>Island</td><td>Arch</td><td>Stall</td><td>buy price</td><td>sell price</td></tr>
41 % while (@row=$sth->fetchrow_array) {
43 % foreach my $cell (@row) {
57 my $dbh= dbw_connect('Midnight');