More language constants rewritten ({--LANGUAGE--} is for constants)
[mailer.git] / inc / modules / admin / what-guestedit.php
index 79bad064141795e2d70f7dd72fe9a739d79f0216..c2d46fab5b9b77eb53844481b7f6bd8fdae05ea1 100644 (file)
@@ -288,29 +288,31 @@ if ((isset($_POST['edit'])) && ($chk > 0) && (!IS_DEMO()))
 
        // Get number of menu entries
        $max = SQL_NUMROWS($result);
-       if ($max > 0)
-       {
+       if ($max > 0) {
                // Set sub value
                define('__SUB_VALUE', $SUB);
 
-               $SW = 2; $cnt = 0; $OUT = "";
-               while (list($id, $act, $wht, $title, $sort) = SQL_FETCHROW($result))
-               {
+               // Init variables
+               $SW = 2;
+               $cnt = 0;
+               $OUT = "";
+
+               while (list($id, $act, $wht, $title, $sort) = SQL_FETCHROW($result)) {
                        $cnt++;
                        if (($sort == 0) || (($sort == 1) && (!empty($SUB)))) {
                                // Is highest position
-                               $NAVI = "<a href=\"{!URL!}/modules.php?module=admin&amp;what=guestedit&amp;sub=".__SUB_VALUE."&amp;act=".$act."&amp;w=".$wht."&amp;tid=".($sort+1)."&amp;fid=".$sort."\">{!LOWER!}</a>";
+                               $NAVI = "<a href=\"{!URL!}/modules.php?module=admin&amp;what=guestedit&amp;sub={!__SUB_VALUE!}&amp;act=".$act."&amp;w=".$wht."&amp;tid=".($sort+1)."&amp;fid=".$sort."\">{--LOWER--}</a>";
                        } elseif ($cnt == $max) {
                                // Is lowest position
-                               $NAVI = "<a href=\"{!URL!}/modules.php?module=admin&amp;what=guestedit&amp;sub=".__SUB_VALUE."&amp;act=".$act."&amp;w=".$wht."&amp;tid=".($sort-1)."&amp;fid=".$sort."\">{!HIGHER!}</a>";
+                               $NAVI = "<a href=\"{!URL!}/modules.php?module=admin&amp;what=guestedit&amp;sub={!__SUB_VALUE!}&amp;act=".$act."&amp;w=".$wht."&amp;tid=".($sort-1)."&amp;fid=".$sort."\">{--HIGHER--}</a>";
                        } elseif ($sort > 0) {
                                // Anything else between highest and lowest
-                               $NAVI = "<a href=\"{!URL!}/modules.php?module=admin&amp;what=guestedit&amp;sub=".__SUB_VALUE."&amp;act=".$act."&amp;w=".$wht."&amp;tid=".($sort-1)."&amp;fid=".$sort."\">{!HIGHER!}</a>/<a href=\"{!URL!}/modules.php?module=admin&amp;what=guestedit&amp;sub=".__SUB_VALUE."&amp;act=".$act."&amp;w=".$wht."&amp;tid=".($sort+1)."&amp;fid=".$sort."\">{!LOWER!}</a>";
+                               $NAVI = "<a href=\"{!URL!}/modules.php?module=admin&amp;what=guestedit&amp;sub={!__SUB_VALUE!}&amp;act=".$act."&amp;w=".$wht."&amp;tid=".($sort-1)."&amp;fid=".$sort."\">{--HIGHER--}</a>/<a href=\"{!URL!}/modules.php?module=admin&amp;what=guestedit&amp;sub={!__SUB_VALUE!}&amp;act=".$act."&amp;w=".$wht."&amp;tid=".($sort+1)."&amp;fid=".$sort."\">{--LOWER--}</a>";
                        }
 
-                       if (empty($act)) $act = "&nbsp;";
+                       if (empty($act))   $act   = "&nbsp;";
                        if (empty($wht))   $wht   = "&nbsp;";
-                       if (empty($title))  $title  = "&nbsp;";
+                       if (empty($title)) $title = "&nbsp;";
                        $content = array(
                                'sw'     => $SW,
                                'id'     => $id,