Mercurial > judyates
view perl/meet_the_artist_descriptions.pl @ 17:46fdf059b154 judyates
preparing to add google analytics
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Mon, 11 Jul 2011 02:43:59 -0400 |
parents | 60668cf4f443 |
children |
line wrap: on
line source
1 @namess = qw(2 hunting_13 hunting_24 hunting_35 hunting_46 hunting_57 hunting_68 hunting_79 hunting_810 hunting_911 hunting_1012 hunting_1113 hunting_1214 stamp00115 stamp00316 stamp00517 stamp00718 stamp00919 stamp01120 );23 foreach(0..$#namess){24 $nnnum = $_;25 $finla = $namess[$nnnum];26 $prevla = $namess[$nnnum-1].".html";27 $nextla = $namess[$nnnum+1].".html";28 $galnum = int($nnnum/9 + 1);30 if ($namess[$_]=~/^s/){31 print "stamp";32 $galname = "Duck Stamps";33 $galla = "../Meet the Artist2.html";}35 if ($namess[$_]=~/^h/){36 print "hunt";37 $galname = "Hunting Pics";38 $galla = "../Meet the Artist1.html";}43 print "../artwork_descriptions/$finla.html\n" ;44 open FILE, ">../artwork_descriptions/$finla.html";48 select FILE;50 print <<HERE;51 <html>52 <title> Gallery of Original Artwork by Judy Yates</title>53 <head>54 <link rel="stylesheet" type="text/css"55 href="../firetest.css" />56 </head>57 <body>58 <span>59 <img src = "../album_pics/3_logo.jpg"></img>60 </span>61 HERE63 open MENU, "<../menu2.html";64 while (<MENU>){print;}65 close MENU;67 print <<HERE;68 <table cellpadding="0" cellspacing="0" width="740">71 HERE73 if($nnnum == 0){74 print "<tr><td><a class = \"menu\" href = \"$galla\">$galname</a><a class = \"menu\" href = \"$nextla\">Next</a></td></tr><tr><td align = \"center\">";75 }77 elsif ($nnnum == $#namess){79 print "<tr><td><a class = \"menu\" href = \"$prevla\">Previous</a><a class = \"menu\" href = \"$galla\">$galname</a></td></tr><tr><td align = \"center\">";80 }82 else {83 print "<tr><td><a class = \"menu\" href = \"$prevla\">Previous</a><a class = \"menu\" href = \"$galla\">$galname</a><a class = \"menu\" href = \"$nextla\">Next</a></td></tr><tr><td align=\"center\">";84 }88 print "<img src = \"../images/$finla.jpg\"></img>\n";90 print <<HERE;92 </td> </tr>93 </table>98 HERE103 if (open TXT, "<../texts/$finla.txt"){104 while (<TXT>){print;}105 close TXT;106 }110 open MENU, "<../menu2.html";111 while (<MENU>){print;}112 close MENU;114 print <<HERE;115 </body>116 </html>117 HERE119 close FILE;120 select STDOUT; }