Mercurial > hg > mgallery
comparison mgallery.php @ 20:12916fcdb8b8
Improve the non-tabled mode.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Mon, 14 Sep 2015 12:59:54 +0300 |
parents | 59075f5e7a62 |
children | 7f5209a6f7e0 |
comparison
equal
deleted
inserted
replaced
19:59075f5e7a62 | 20:12916fcdb8b8 |
---|---|
136 | 136 |
137 $rowLimit = mgGetSetting("album_row_limit"); | 137 $rowLimit = mgGetSetting("album_row_limit"); |
138 $n = 0; | 138 $n = 0; |
139 | 139 |
140 if ($galUseTables) | 140 if ($galUseTables) |
141 echo "<table class=\"".$class."\">\n"; | 141 echo "<table class=\"galleryTable ".$class."\">\n"; |
142 else | |
143 echo "<div class=\"galleryTable ".$class."\">\n"; | |
142 | 144 |
143 for ($index = $start; $index < $end; $index++) | 145 for ($index = $start; $index < $end; $index++) |
144 { | 146 { |
145 $filename = &$galIndex[$index]; | 147 $filename = &$galIndex[$index]; |
146 $data = &$galEntries[$filename]; | 148 $data = &$galEntries[$filename]; |
147 | 149 |
148 if ($galUseTables && $n == 0) echo " <tr>\n"; | 150 if ($galUseTables && $n == 0) echo " <tr>\n"; |
149 | 151 |
150 if ($galUseTables) | 152 if ($galUseTables) |
151 echo " <td id=\"cd".$data["base"]."\">\n"; | 153 echo " <td class=\"galleryEntry\" id=\"cd".$data["base"]."\">\n"; |
152 else | 154 else |
153 echo " <div class=\"albumEntry\">\n"; | 155 echo " <div class=\"galleryEntry\">\n"; |
154 | 156 |
155 if ($data["type"] == 0) | 157 if ($data["type"] == 0) |
156 { | 158 { |
157 echo | 159 echo |
158 "<div class=\"imageBox\"><a href=\"".mgGetURL($galPath, $filename)."\">". | 160 "<div class=\"imageBox\"><a href=\"".mgGetURL($galPath, $filename)."\">". |
206 echo " <td></td>\n"; | 208 echo " <td></td>\n"; |
207 echo " </tr>\n"; | 209 echo " </tr>\n"; |
208 } | 210 } |
209 echo "</table>\n"; | 211 echo "</table>\n"; |
210 } | 212 } |
213 else | |
214 echo "</div>\n"; | |
215 | |
211 return $index; | 216 return $index; |
212 } | 217 } |
213 | 218 |
214 | 219 |
215 function mgTimeStr($str) | 220 function mgTimeStr($str) |