Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

Trouble with Array


Recommended Posts

Hi guys


I'm having a problem with arrays.


Under one file, the array works perfectly. Under another, the array doesn't output anything


thing is, both pages use the same line of code to call the array.


<?php echo tep_address_format($order->billing['format_id'], $order->billing, 1, ' ', '<br>'); ?>


the only difference I can see that would be causing this is where the class is pulled in


The page thats works uses


 require(DIR_WS_CLASSES . 'order.php');
 $order = new order;


The page that doesn't work uses


  require(DIR_WS_CLASSES . 'order.php');
 $order = new order($HTTP_GET_VARS['order_id']);


If I change the second one to be the same as the first, the following error message appears


Warning: htmlspecialchars() expects parameter 1 to be string, array given in /files/home2/lairdking/products/includes/functions/general.php on line 42


I'm so confused here :(

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...