View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002553 | phplist application | Configuration | public | 08-02-05 04:25 | 12-02-09 13:54 |
Reporter | DamienMcKenna | ||||
Priority | immediate | Severity | tweak | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Product Version | 2.9.3 | ||||
Target Version | Fixed in Version | 2.9.5 | |||
Summary | 0002553: admin/spageedit.php: Clean up attributes list | ||||
Description | The attributes list should be a regular column-based table rather than one table per attribute. | ||||
Tags | No tags attached. | ||||
|
Change lines 167 onwards from: while ($row = Sql_Fetch_Array($req)) { if (is_array($attributedata[$row["id"]])) { $checked[$row["id"]] = "checked"; $bgcol = '#F7E7C2'; $value = $attributedata[$row["id"]]; } else { $value = $row; $bgcol = '#ffffff'; } ?> <table border=1 width=100% bgcolor="<?php echo $bgcol?>"> <tr><td colspan=2 width=150>Attribute:<?php echo $row["id"] ?></td><td colspan=2>Check this box to use this attribute in the page <input type="checkbox" name="attr_use[<? echo $row["id"] ?>]" value="1" <?=$checked[$row["id"]]?>></td></tr> <tr><td colspan=2>Name: </td><td colspan=2><h2><?php echo htmlspecialchars(stripslashes($row["name"])) ?></h2></td></tr> <tr><td colspan=2>Type: </td><td colspan=2><h2><?php echo $row["type"]?></h2></td></tr> <tr><td colspan=2>Default Value: </td><td colspan=2><input type=text name="attr_default[<?php echo $row["id"]?>]" value="<? echo htmlspecialchars(stripslashes($value["default_value"])) ?>" size=40></td></tr> <tr><td>Order of Listing: </td><td><input type=text name="attr_listorder[<?php echo $row["id"]?>]" value="<? echo $value["listorder"] ?>" size=5></td> <td>Is this attribute required?: </td><td><input type=checkbox name="attr_required[<?php echo $row["id"]?>]" value="1" <? echo $value["required"] ? "checked": "" ?>></td></tr> </table><hr> <?php } to: print "<table border=\"1\" width=\"100%\">\n"; print " <tr>\n"; print " <th>use?</th>\n"; print " <th>name</th>\n"; print " <th>type</th>\n"; print " <th>default</th>\n"; print " <th>required</th>\n"; print " <th>order</th>\n"; print " </tr>\n"; while ($row = Sql_Fetch_Array($req)) { if (is_array($attributedata[$row["id"]])) { $checked[$row["id"]] = "checked"; $bgcol = '#F7E7C2'; $value = $attributedata[$row["id"]]; } else { $value = $row; $bgcol = '#ffffff'; } ?> <tr bgcolor="<?php echo $bgcol; ?>"> <td><input type="checkbox" name="attr_use[<? echo $row["id"]; ?>]" value="1" <? echo $checked[$row["id"]]; ?> /></td> <td><?php echo htmlspecialchars(stripslashes($row["name"])); ?></td> <td><?php echo $row["type"]; ?></td> <td><input type="text" name="attr_default[<?php echo $row["id"]; ?>]" value="<? echo htmlspecialchars(stripslashes($value["default_value"])) ?>" size="15" /></td> <td><input type="checkbox" name="attr_required[<?php echo $row["id"]; ?>]" value="1" <? echo $value["required"] ? "checked": ""; ?> /></td> <td><input type="text" name="attr_listorder[<?php echo $row["id"]; ?>]" value="<? echo $value["listorder"]; ?>" size="5" /></td> </tr> <?php } print "</table>\n"; |
|
Waiting for insertion of code into CVS. |
|
Made this part of 2.9.5, because with the translation stuff going in, it's not a simple cut-n-paste anymore. |