itachi77 Posted July 7, 2010 Share Posted July 7, 2010 Hi, seem to be having trouble with mergeblocks with livedocx in php. I understand that for merge blocks a multi associative array is needed such as : $billConnections = array( array( 'con_productid' => 1A, 'con_quantity' => '10', 'subtotal' => '£10', ), array( 'con_productid' => '1B', 'con_quantity' => '20', 'subtotal' => '£30', ), ); This does print two rows on the document, however i am struggling to understand how to transfer SESSION variables into those 3 fields. I have tried: $array1=unserialize($_SESSION['product']); while(list($vs,$ks)=each($array1)) $billconnections=array( array('con_productid'=> $ks)); But this only seems to print one row not for all the product id's stored in the session variable. I know session array itself is an associative array but i'm getting confused with how to specify the different fields with it. Any help appreciated, thanks Link to comment https://forums.phpfreaks.com/topic/207044-livedocx-mergeblocks-and-session-variables/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.