]> git.mxchange.org Git - mailer.git/blobdiff - inc/modules/admin/what-guest_add.php
Some rewrites, TODOs handled:
[mailer.git] / inc / modules / admin / what-guest_add.php
index 650e4ed6677ec9916dc60a1276d8df187d864f9b..a9ceac643ff5db55742ab3750be738801c974e06 100644 (file)
@@ -46,10 +46,10 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
 ADD_DESCR('admin', __FILE__);
 
 // Check if the admin has entered title and what-php file name...
-if (((!REQUEST_ISSET_POST(('title'))) || (!REQUEST_ISSET_POST(('menu')))) && (isFormSent())) {
+if (((!REQUEST_ISSET_POST('title')) || (!REQUEST_ISSET_POST(('menu')))) && (isFormSent())) {
        // Abort adding the menu entry
        REQUEST_UNSET_POST('ok');
-}
+} // END - if
 
 if (!isFormSent()) {
        // Create arrays
@@ -59,6 +59,7 @@ if (!isFormSent()) {
        $result = SQL_QUERY("SELECT action, title, sort FROM `{!_MYSQL_PREFIX!}_guest_menu` WHERE (`what`='' OR `what` IS NULL) ORDER BY `sort`", __FILE__, __LINE__);
        if (SQL_NUMROWS($result) > 0) {
                // Read menu structure
+               // @TODO Cant this be rewritten?
                while ($content = SQL_FETCHARRAY($result)) {
                        // Menu actions
                        $menus[] = $content['action'];
@@ -68,7 +69,7 @@ if (!isFormSent()) {
 
                        // Below this menu point should the new be added so we simply increase the sort value by 1 :-)
                        $below[] = $content['sort'] + 1;
-               }
+               } // END - while
 
                // Free memory
                SQL_FREERESULT($result);