I have a 2D array such as the below:
Array (
[0] => Array (
[asin] => B004HFS6Z0
[title] => Kindle, Wi-Fi, Graphite, 6" Display with New E Ink Pearl Technology - includes Special Offers & Sponsored Screensavers
[price] => 114.00
[map] => 125.00
[email] => [email protected] )
[1] => Array (
[asin] => B004CYX17O
[title] => Rizzy Home Apple 10-Piece Comforter Set, King
[price] => 502.80
[map] => 520.00
[email] => [email protected] ) )
What I want to do with it is export it into 2 csv files (could be more) based on the email field and then email the csv file as an attachment to the email address in the field. There would be multiples with the email address that I would want to all be in the same csv file but when the email is different I would want that in a seperate csv file.
Is this possible? I am not sure where to begin with this but would really like some suggestions! Thanks in advance!