uhlv Posted April 18, 2007 Share Posted April 18, 2007 i have this script in mywebsite <?php foreach ($myCheckout->order_array as $val => $val) { ?> <?php echo $val['product_id']; ?> <?php } // end foreach loop ?> on php4 it's working fine but i make update to php5 and it dosn't work can u help ? Link to comment https://forums.phpfreaks.com/topic/47610-foreach/ Share on other sites More sharing options...
per1os Posted April 18, 2007 Share Posted April 18, 2007 <?php foreach ($myCheckout->order_array as $val) { echo $val['product_id']; } // end foreach loop ?> If you set $val => $val that does not do anything. It was probably a bug in php 4 which is why it worked. Why the heck are you doing all the <?php ?> crap? Link to comment https://forums.phpfreaks.com/topic/47610-foreach/#findComment-232449 Share on other sites More sharing options...
uhlv Posted April 18, 2007 Author Share Posted April 18, 2007 even this dosn't work Link to comment https://forums.phpfreaks.com/topic/47610-foreach/#findComment-232456 Share on other sites More sharing options...
per1os Posted April 18, 2007 Share Posted April 18, 2007 No more help from me until you can learn how to use the [ code ] tags. Link to comment https://forums.phpfreaks.com/topic/47610-foreach/#findComment-232458 Share on other sites More sharing options...
uhlv Posted April 18, 2007 Author Share Posted April 18, 2007 sorry but it was like u said <?php foreach ($myCheckout->order_array as $val) { ?> :'( Link to comment https://forums.phpfreaks.com/topic/47610-foreach/#findComment-232461 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.