mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-27 07:44:35 +02:00
2011-07-20 Dario Rodriguez <dario.rodriguez@artica.es>
* godmode/setup/links.php: Fixed a wrong code to work with an empty array. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4598 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
5f67d43bb9
commit
bef39bfd4e
@ -1,3 +1,7 @@
|
|||||||
|
2011-07-20 Dario Rodriguez <dario.rodriguez@artica.es>
|
||||||
|
|
||||||
|
* godmode/setup/links.php: Fixed a wrong code to work with an empty array.
|
||||||
|
|
||||||
2011-07-20 Sergio Martin <sergio.martin@artica.es>
|
2011-07-20 Sergio Martin <sergio.martin@artica.es>
|
||||||
|
|
||||||
* include/styles/dialog.css: Fixed wrong path in the
|
* include/styles/dialog.css: Fixed wrong path in the
|
||||||
|
@ -116,29 +116,35 @@ if ((isset($_GET["form_add"])) or (isset($_GET["form_edit"]))){
|
|||||||
echo '</form></td></tr></table>';
|
echo '</form></td></tr></table>';
|
||||||
}
|
}
|
||||||
else { // Main list view for Links editor
|
else { // Main list view for Links editor
|
||||||
echo "<table cellpadding='4' cellspacing='4' class='databox' style='width:98%'>";
|
|
||||||
echo "<th width='180px'>".__('Link name')."</th>";
|
|
||||||
echo "<th width='80px'>".__('Delete')."</th>";
|
|
||||||
|
|
||||||
$rows = db_get_all_rows_in_table('tlink', 'name');
|
$rows = db_get_all_rows_in_table('tlink', 'name');
|
||||||
if ($rows === false) {
|
if ($rows === false) {
|
||||||
$rows = array();
|
$rows = array();
|
||||||
}
|
}
|
||||||
|
|
||||||
$color=1;
|
if (empty($rows)) {
|
||||||
foreach ($rows as $row) {
|
echo "<h3 class='error'>".__("There isn't links")."</h3>";
|
||||||
if ($color == 1){
|
} else {
|
||||||
$tdcolor = "datos";
|
echo "<table cellpadding='4' cellspacing='4' class='databox' style='width:98%'>";
|
||||||
$color = 0;
|
echo "<th width='180px'>".__('Link name')."</th>";
|
||||||
|
echo "<th width='80px'>".__('Delete')."</th>";
|
||||||
|
|
||||||
|
$color=1;
|
||||||
|
foreach ($rows as $row) {
|
||||||
|
if ($color == 1){
|
||||||
|
$tdcolor = "datos";
|
||||||
|
$color = 0;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$tdcolor = "datos2";
|
||||||
|
$color = 1;
|
||||||
|
}
|
||||||
|
echo "<tr><td class='$tdcolor'><b><a href='index.php?sec=gsetup&sec2=godmode/setup/links&form_edit=1&id_link=".$row["id_link"]."'>".$row["name"]."</a></b></td>";
|
||||||
|
echo '<td class="'.$tdcolor.'" align="center"><a href="index.php?sec=gsetup&sec2=godmode/setup/links&id_link='.$row["id_link"].'&borrar='.$row["id_link"].'" onClick="if (!confirm(\' '.__('Are you sure?').'\')) return false;">' . html_print_image("images/cross.png", true) . '</a></td></tr>';
|
||||||
}
|
}
|
||||||
else {
|
echo "</table>";
|
||||||
$tdcolor = "datos2";
|
|
||||||
$color = 1;
|
|
||||||
}
|
|
||||||
echo "<tr><td class='$tdcolor'><b><a href='index.php?sec=gsetup&sec2=godmode/setup/links&form_edit=1&id_link=".$row["id_link"]."'>".$row["name"]."</a></b></td>";
|
|
||||||
echo '<td class="'.$tdcolor.'" align="center"><a href="index.php?sec=gsetup&sec2=godmode/setup/links&id_link='.$row["id_link"].'&borrar='.$row["id_link"].'" onClick="if (!confirm(\' '.__('Are you sure?').'\')) return false;">' . html_print_image("images/cross.png", true) . '</a></td></tr>';
|
|
||||||
}
|
}
|
||||||
echo "</table>";
|
|
||||||
echo "<table width='98%'>";
|
echo "<table width='98%'>";
|
||||||
echo "<tr><td align='right'>";
|
echo "<tr><td align='right'>";
|
||||||
echo "<form method='post' action='index.php?sec=gsetup&sec2=godmode/setup/links&form_add=1'>";
|
echo "<form method='post' action='index.php?sec=gsetup&sec2=godmode/setup/links&form_add=1'>";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user