azunoman Posted October 13, 2008 Share Posted October 13, 2008 using form buttons and drop downs I collect information for a group of accessories. From this information I can then from subsequentr processing display the group and accessory descriptions prices etc...all works great.... In this same code where I retrieve the group code record and the associated groups accessory information I would like to store the original price as the price could change after a customer order. So what I would simply like to do is be able to add to say ['OXYG'][0] other information....I thought of just creating a new array as I build my display from this array but if I could just add...well maybe it's greener to recycle the current array. also I was just planing on serializing the array and filing it into a 'blob?' for later recall....thanks in advance for review and comments.... An example of my array: (data is by group with 1 or more accid's) [OXYG] => Array ( [0] => 53 ) [PELV] => Array ( [0] => 55 ) [MISC] => Array ( [0] => 57 [1] => 62 [2] => 48 [3] => 33 [4] => 45 [5] => 2 [6] => 63 [7] => 1 [8] => 46 Link to comment https://forums.phpfreaks.com/topic/128279-add-elements-to-my-array/ Share on other sites More sharing options...
Barand Posted October 13, 2008 Share Posted October 13, 2008 Example Add 42 to the MISC subarray $myarray['OXYG']['MISC'][] = 42; Link to comment https://forums.phpfreaks.com/topic/128279-add-elements-to-my-array/#findComment-664506 Share on other sites More sharing options...
azunoman Posted October 13, 2008 Author Share Posted October 13, 2008 I somehow want to end up with something like this: [MISC] => Array ( [0] => 57 =>['ListPrice']['IncIND']['StdIND'] etc....for each accessory ID [1] => 62 [2] => 48 [3] => 33 [4] => 45 [5] => 2 [6] => 63 [7] => 1 [8] => 46 Link to comment https://forums.phpfreaks.com/topic/128279-add-elements-to-my-array/#findComment-664526 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.