Jump to content

TicTacTheTech

New Members
  • Posts

    1
  • Joined

  • Last visited

Posts posted by TicTacTheTech

  1. I'm having troubling with trying to create a function to spit out a single array with the following array. I can write it in a away that looks through the arrays manually. 

    the results i am trying to generate is that each item in generated array.

    Array to convert

    array(
        "account" => array(
            "login",
            "register",
            "logout",
            "edit",
        ),
        "p" => array( 
            "report",
        ),
        "array1.0" => array( 
            "array2.0" => array(
                "array3.0",
                "array3.1
            ),
            "array2.1",
        ),

    generating the array will look like this

     

    Array ( 
    [0] => account 
    [1] => account/login 
    [2] => account/register 
    [3] => account/logout 
    [4] => account/edit 
    [5] => p 
    [6] => p/report 
    [7] => array1.0 
    [8] => array1.0/array2.0
    [9] => array1.0/array2.0/array3.0
    [10] => array1.0/array2.0/array3.1
    [11] => array1.0/array2.1
    
    )

    The idea is that id generates a single array with combined labels and arrays inside, etc. I just can't figure out how to create a script that will create this array even If I add a new value or array. 

     

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.