]> jspc29.x-matter.uni-frankfurt.de Git - trb3web.git/commitdiff
first Perl-version
authorJan Michel <j.michel@gsi.de>
Fri, 10 May 2013 16:19:00 +0000 (18:19 +0200)
committerJan Michel <j.michel@gsi.de>
Fri, 10 May 2013 16:19:00 +0000 (18:19 +0200)
frame.pm [new file with mode: 0755]
index.pl [new file with mode: 0755]
logo.png [new file with mode: 0644]
styleold.css [new file with mode: 0644]

diff --git a/frame.pm b/frame.pm
new file mode 100755 (executable)
index 0000000..cd0dbdf
--- /dev/null
+++ b/frame.pm
@@ -0,0 +1,78 @@
+#!/usr/bin/perl -w\r
+use Data::Dumper;\r
+\r
+#Entries for top menu\r
+my $toplink = {"index.pl" => "Main",\r
+               "contact.pl" => "Contact"\r
+               };\r
+\r
+#Entries for sidebar menu\r
+my $menues = {\r
+    toplevel => {"index.pl" => "Main",\r
+                 "contact.pl" => "Contact"\r
+                 },\r
+    contact  => {"index.pl" => "Main",\r
+                 }\r
+           };\r
+\r
+\r
+\r
+sub makeframe {\r
+my ($menu) = @_;\r
+\r
+print <<HDOC;\r
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">\r
+<html>\r
+\r
+<head>\r
+ <title>TRB Readout Platform</title>\r
+ <link rel="stylesheet" type="text/css" href="styleold.css">\r
+ <meta http-equiv="Content-Language" content="en">\r
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">\r
+</head>\r
+\r
+<body>\r
+\r
+<div id="head">\r
+<h1 class="header">TRB3</h1>\r
+\r
+<ul id="menu">\r
+HDOC\r
+\r
+foreach my $k (keys %$toplink) {\r
+  print "<li><a href=\"$k\">$toplink->{$k}</a>\n";\r
+  }\r
+\r
+\r
+print <<HDOC;\r
+</ul>\r
+\r
+<div id="logo"><img src="logo.png" alt="Logo"></div>\r
+\r
+<h2 class="header">the ultimate read-out platform</h2>\r
+</div>\r
+<div id="main">\r
+HDOC\r
+\r
+print "<dl id=\"navigation\"><dt>\n";\r
+print "\n<dd><ul>\n";\r
+foreach my $k (keys $menues->{$menu}) {\r
+  print "<li><a href=\"$k\">$menues->{$menu}->{$k}</a>\n";\r
+  }\r
+print "</ul></dl>\r\n";\r
+}\r
+\r
+\r
+\r
+sub makefoot() {\r
+print <<HDOC;\r
+</div>\r
+<!--<div id="footer"></div>-->\r
+\r
+\r
+</body>\r
+</html>\r
+HDOC\r
+}\r
+\r
+1;
\ No newline at end of file
diff --git a/index.pl b/index.pl
new file mode 100755 (executable)
index 0000000..bf690be
--- /dev/null
+++ b/index.pl
@@ -0,0 +1,16 @@
+#!/usr/bin/perl -w
+print "Content-type: text/html\n\n";
+
+use frame;
+
+makeframe("toplevel");
+
+print <<HDOC;
+<div id="content">
+<h3>Basic Stuff</h3>
+Very good thing, indeed.
+</div>
+HDOC
+
+
+makefoot();
\ No newline at end of file
diff --git a/logo.png b/logo.png
new file mode 100644 (file)
index 0000000..24b6372
Binary files /dev/null and b/logo.png differ
diff --git a/styleold.css b/styleold.css
new file mode 100644 (file)
index 0000000..423da57
--- /dev/null
@@ -0,0 +1,232 @@
+/*Farben
+oliv:               #b2c979
+beige             #ffe
+dark blue       #405774
+light blue       #ddeaf4
+lightest blue  #e5f2fc
+
+*/
+
+html {
+   height:100%;
+   width:100%;
+   min-width:700px;
+   max-width:1300px;
+   margin:0;
+   padding:0;
+  }
+
+body {
+  margin:0;
+  padding:0;
+  background-color: #ffe; /*#dddde1;#e5ebdf*/
+  font-size: .9em;
+  width:100%;
+  font-family: Lucida Sans, Verdana, Arial, Helvetica, SunSans-Regular, Sans-Serif;
+  color:#474756;  
+  /*margin: 100px 140px  5px 190px;*/
+  text-align: center;
+}
+
+#head {
+   float:left;
+   width:100%;
+   }
+
+#logo {
+   left:19px;
+   top:10px;
+   height:134px;
+   background:#b2c979;
+   border:solid white;
+   border-width:2px 2px 2px 2px;
+   position:absolute;
+   z-index:23;
+   _float:left;
+   }   
+   
+.header {
+   /*margin:-90px -140px 0 -190px;*/
+   display:block;
+   overflow:hidden;
+   text-align:left;
+   height:30px;
+   background:#405774;
+   z-index:21;
+   position:absolute;
+   _width:100%;
+   right:0;
+   _float:left;
+   font-family: Lucida Sans, Verdana, Arial, Helvetica, SunSans-Regular, Sans-Serif;
+   color:#ffe;
+   margin:0;
+   line-height:100%;
+   border: solid #ddeaf4;
+   }
+
+body>#head>.header {
+   left:0;
+   }
+
+h1.header {
+   top:25px;
+   padding:12px 0 3px 200px;
+   _height:45px;
+   font-size:25px;
+   border-width:1px 0 0 0;
+   }
+   
+h2.header {
+   top:70px;
+   padding:10px 0 0 200px;
+   _height:40px;
+   border-width:0 0 1px 0;
+   font-weight:normal;
+   font-size:20px;
+   }
+
+h3, h4 {
+   border-bottom:1px dotted #405774;
+   }
+
+#main {
+   _float:left;
+   margin:0;
+   padding:0 0 20px 0;
+   z-index:2;
+   overflow:hidden;
+   background:transparent;
+   }
+
+#menu {
+   text-align:right;
+   position:absolute;
+   top:100px;
+   left:190px;
+   right:0;
+   margin:0px 0 0 0;
+   padding:0 0 5px 0;
+   z-index:30;
+   }
+
+#menu li {
+   list-style:none;
+   display:inline;
+   padding:0 20px;
+   margin:0px 5px;
+   border:1px solid black;
+   background:#405774;
+   color:#ddeaf4;
+   }
+    
+#menu li:hover {
+   background:#ddeaf4;
+   color:#405774;
+   }
+#content { 
+  _float:left;
+  padding: 0px;
+  text-align: left;
+  margin:110px 20px 35px 200px;
+  _margin-top:130px;
+  line-height:140%;
+  overflow: auto;
+  text-align:justify;
+  z-index:3;
+  margin-bottom: -10000px; padding-bottom: 10000px;
+  min-width:100px;
+  min-height:600px;
+  }
+
+#footer {
+   text-align:right;
+   margin:0;
+   padding:2px;
+   background:#405774;
+   color:#ddeaf4;
+   }
+
+#search {
+   position:absolute;
+   font-size:80%;
+   top:5px;
+   right:5px;
+   background:white;
+   border:1px solid black;
+   width:200px;
+   height:15px;
+   text-align:left;
+   z-index:22;
+   }
+   
+#infobar {
+   display:block;
+   background:#ffe;
+   width:150px;
+   float:right;
+   margin:130px 0 0 0 ;
+   _margin:0;
+   padding:20px 5px 0 5px;
+   border:solid #405774;
+   border-width:0 0 0 1px;
+   z-index:5;
+   margin-bottom: -2000px; 
+   padding-bottom: 2000px;
+   }
+   
+#navigation{
+   display:block;
+   background:#ddeaf4;/*rgb(217,229,239); d9e5ef*/
+   width:170px;
+   float:left;
+   /height:100%;
+   margin-top:-15px;
+   _margin-top:0px;
+   margin-left:11px;
+   _margin-left:6px;
+   padding-top:180px;
+   padding-bottom:100px;
+   border:solid black;
+   border-width:0 1px;
+   z-index:5;
+   margin-bottom: -2000px; padding-bottom: 2000px;
+   }
+
+#navigation a, #menu a{
+   color:inherit;
+   text-decoration:none;
+   }
+   
+#navigation dt, #infobar dt {
+   font-weight:bold;
+   font-size:110%;
+   margin:10px 0 2px 0;
+   }
+   
+#navigation dd, #infobar dd {
+   margin:0 0 20px 10px;
+   padding:0;
+   }
+   
+#navigation ul, #infobar ul {
+   margin:10px 10px 0 0;
+   padding:0;
+   border-top:1px solid white;
+   }
+
+#navigation li:hover, #infobar li:hover {
+   background:#e5f2fc;
+   }
+   
+#navigation li, #infobar li {
+   list-style:none;
+   margin:0;
+   padding:5px 0 5px 5px;
+   border-bottom:1px solid white;
+   }
+
+dt {
+   font-weight:bold;
+   }
\ No newline at end of file