• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login
Netgate Discussion Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Search
  • Register
  • Login

Corrupt interface groups - interfaces_groups_edit.php

Scheduled Pinned Locked Moved 2.3-RC Snapshot Feedback and Issues - ARCHIVED
3 Posts 3 Posters 832 Views
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Q
    quantumx
    last edited by Nov 12, 2015, 7:13 PM

    Creating / Editing Interface groups creates groups with invalid members (ie. Array, Array).

    Problem seems to be around line 129 of interfaces_groups_edit.php where $member is defined.  Array implode doesn't work properly as $members is multidimensional.

    I have refactored the original code in the for loop above as follows and removed line 129, which seems to correct the issue:

            if (isset($_POST['members'])) {
                    foreach ($_POST['members'] as $member )
                    {
                            if ($isfirst > 0)  
                                    $members .= " ";
                            $members .= $member[0];
                            $isfirst++;
                    }
            }
            else {
                    $members = "";
            }
    
    
    1 Reply Last reply Reply Quote 0
    • J
      jimp Rebel Alliance Developer Netgate
      last edited by Nov 12, 2015, 8:08 PM

      Yep that's definitely broken.

      https://redmine.pfsense.org/issues/5436

      Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

      Need help fast? Netgate Global Support!

      Do not Chat/PM for help!

      1 Reply Last reply Reply Quote 0
      • S
        Steve_B Netgate
        last edited by Nov 12, 2015, 9:48 PM

        File that one under: "Too clever by half" :)

        Thanks for the fix. merged/pushed to master.

        Als ik kan

        1 Reply Last reply Reply Quote 0
        3 out of 3
        • First post
          3/3
          Last post
        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.
          This community forum collects and processes your personal information.
          consent.not_received