Hello,
I have an array that is housing multiline values as seen below.
I want to be able to go through the array and identify the menu options, these are designated by the numbers, “1 Enter/update accounts for recon” etc…
$array[0] MENUNAMEABC Account Recon 1 Enter/update accounts for recon 2 Enter/update issued checks 3 Enter/update paid checks 5 Add paid checks from file 10 Add issued AP checks from 11 Add deposit trans from 13 Post reconciled transactions 14 Purge paid checks in acct recon 20 Paid check exception listing 21 Paid check transaction listing 22 Outstanding checks register 24 Statement for acct recon by ck # 25 Acct recon statement by status 26 Account recon account listing User Name Allowed Options FEDCAB User - Derp Derpman 1,2,3,5,10,11,13,14,20,21,22,24,25,26 ABCDEF User- Fake Name 1,2,3,5,10,11,13,14,20,21,22,24,25,26 ABCXYZ User - Tom Brooks 1,2,3,5,10,11,13,14,20,21,22,24,25,26
Is there a way to go line by line in an array item?
foreach($line in $array[0]) { #regex or something to find each menu }
Any help would be greatly appreciated!