Commit a078f9bd336e45d6e6dfc023d128129c24ac5c33
1 parent
76a4a4b7
(#2807) don't display empty lines for empty links
git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@2488 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing
1 changed file
with
6 additions
and
3 deletions
lib/visualpatterns/PatternTableLinks.inc
| ... | ... | @@ -56,7 +56,7 @@ class PatternTableLinks { |
| 56 | 56 | global $default; |
| 57 | 57 | |
| 58 | 58 | $iArraySize = count($this->aLinks); |
| 59 | - $iArrayCount = 1; | |
| 59 | + $iArrayCount = 0; | |
| 60 | 60 | $sToRender = "<table border=0 width=\"100%\" cellspacing = \"0\">\n"; |
| 61 | 61 | |
| 62 | 62 | //build the table |
| ... | ... | @@ -77,8 +77,11 @@ class PatternTableLinks { |
| 77 | 77 | } |
| 78 | 78 | $iArrayCount++; |
| 79 | 79 | } |
| 80 | - $sToRender .= "<td cellspacing=\"20\" width=\"100%\">" . (strlen($sLink) > 0 ? $sLink : " ") . "</td>"; | |
| 81 | - $sToRender .= "</tr><tr></tr><tr/><tr/><tr/><tr><td></td>\n"; | |
| 80 | + | |
| 81 | + if (strlen($sLink) > 0) { | |
| 82 | + $sToRender .= "<td cellspacing=\"20\" width=\"100%\">$sLink</td>"; | |
| 83 | + } | |
| 84 | + $sToRender .= "</tr><tr></tr><tr/><tr/><tr/><tr><td></td>\n"; | |
| 82 | 85 | } |
| 83 | 86 | $sToRender .= "</tr>\n"; |
| 84 | 87 | } | ... | ... |