Code

Some changes
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 7 Nov 2007 07:08:09 +0000 (07:08 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 7 Nov 2007 07:08:09 +0000 (07:08 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6-playground@7740 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa.conf
include/class_ObjectListViewport.inc
test.php

index 7833c6644b23cf46476b1697253281e97db004b3..e30c923c2f84423e0757dc52ff247b5f3c10fd31 100644 (file)
--- a/gosa.conf
+++ b/gosa.conf
@@ -119,6 +119,6 @@ kiosk-path = "/var/spool/kiosk"
 ppd-path = "/var/spool/ppds"
 
 [plugin/sample]
-headline= "|{18px}|{:L}Name|{64px:R}Actions|"
+headline= "|{18px}|{:L}Name|{100px:R}Actions|"
 footer= "Statistics with no information currently"
 entryFormat= "|{_icon}|{cn} ({_filter(uppercase,{cn})})|{_actions}|"
index 970d1aa0edbb73bdb5f4c9bb0491bac27f53f026..7d51f7b8b5f74390aa364b526a8fd5c95bae221b 100644 (file)
@@ -89,6 +89,7 @@ class ObjectListViewport {
     foreach($this->headline as $key => $value){
       $buffer .= "<td class='ObjectListViewport_Headline_Cell' style='".$value['style']."'>".$value['name']."</td>\n";
     }
+    $buffer.="<td style='width:12px;'>&nbsp;</td>";
     $buffer.="</tr>\n";
     $buffer.="</table>\n";
     return $buffer;
@@ -154,7 +155,18 @@ class ObjectListViewport {
 
     $buffer="<tr>\n";
     foreach($tmp as $key => $value){
-      $buffer .= "<td class='ObjectListViewport_Entry_Cell' style='".$this->headline[$key]['style']."'>".$value."</td>\n";
+
+      if(empty($this->headline[$key]['width']) || preg_match("/\%/",$this->headline[$key]['width'])){
+        $buffer .= "<td nowrap class='ObjectListViewport_Entry_Cell' style='".$this->headline[$key]['style']."'>".
+          "<div style='overflow:hidden;width:100%;'>".
+          $value.
+          "</div>".
+          "</td>\n";
+      }else{
+        $buffer .= "<td class='ObjectListViewport_Entry_Cell' style='".$this->headline[$key]['style']."'>".
+          $value.
+          "</td>\n";
+      }
     }
     $buffer.="</tr>\n";
 
@@ -188,13 +200,13 @@ class ObjectListViewport {
     /* Apply current filter */
     $objects= new ObjectListFilterIterator($this->objects->getIterator());
     
-    $buffer.="<div style='overflow:scroll; height:400px;'>
+    $buffer.="<table><tr><td>
               <table class='ObjectListViewport_Entry_Table'>\n"; 
     foreach ($objects as $value){
-      $buffer.= $this->renderEntry($value);
+      $buffer.= "<br>";//$this->renderEntry($value);
     }
     $buffer.="</table>
-              </div>\n"; 
+              </td></tr></table>\n"; 
 
     /* Generate footer */
     $buffer.= $this->renderFooter();
index 1393296955d6dfbf414dfb1e98911bc757105fe7..c3ff99321e0e080e269ca75cffaaa01b2c7cee60 100644 (file)
--- a/test.php
+++ b/test.php
        border: 1px solid #000000;
 }
 </style>
+<script type="text/javascript">
+       function setHeight() {
+       //      document.getElementById("tolletable").style.height=document.defaultView.getComputedStyle(document.getElementById("tolletable"),"").getPropertyValue("height"))+"px";
+               alert(document.getElementById("tolletable").style.height());
+       }
+</script>
 </head>
 <body>
-<div style='height:500px; width:700px;'>
+
+<table onmouseover="setHeight();" id="tolletable" style='height:50%;background-color: #00FF00;'><tr><td></td></tr></table>
+
+<table style='height:30px; width:50%; background-color:#FF0000;'>
+<tr>
+<td>
 <?php
 echo passthru("./test");
 ?>
+</td>
+</tr>
+</table>
 </div>
 </body>
 </html>