Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Country name not showing correctly in account_history_info.php?


shaytaan

Recommended Posts

It not a sql problem, becouse it shows correctly in checkout pages!

And if I copy the code from checkoutpages which is different, it shows it correctly in account_history_info.php, BUT not in HTML email invoice :(

 

This is from checkout pages

<?php echo tep_address_label($customer_id, $billto, true, ' ', '<br>'); ?>

 

And this is from account_history_info.php

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

 

What can be wrong?

 

Any help appreciated

?,???`???,?? God must love stupid people, he made so many ??,???`???,?

Link to comment
Share on other sites

Hi,

 

I spotted this problem recently with my HTML invoices (using fancier invoices & packingslips contrib).

 

Looking into the problem it is directly caused by a 'fix' in the latest milestone release that modifies the tep_address_format function in general.php

 

The fix for this fix is posted in http://www.oscommerce.com/forums/index.php?sho...mp;st=850

 

but this will not affect the more widespread issue that is also affecting account_history_info.php

 

The problem is caused because since this new milestone release tep_address_format is using $address['country']['title'] instead of $address['country']. the html invoice & account_history_info is using the order class to send the address info ($order->customer or $order->delivery). The order class populates country as the name of the country not as an array with a key as 'title'.

 

I think the best way round this at the moment is to remove the modifications to tep_address_format unless the bug that it was supposed to be fixing is a problem for you until a true bug fix is found.

 

Tom

Link to comment
Share on other sites

Hi,

 

I spotted this problem recently with my HTML invoices (using fancier invoices & packingslips contrib).

 

Looking into the problem it is directly caused by a 'fix' in the latest milestone release that modifies the tep_address_format function in general.php

 

The fix for this fix is posted in http://www.oscommerce.com/forums/index.php?sho...mp;st=850

 

but this will not affect the more widespread issue that is also affecting account_history_info.php

 

The problem is caused because since this new milestone release tep_address_format is using $address['country']['title'] instead of $address['country']. the html invoice & account_history_info is using the order class to send the address info ($order->customer or $order->delivery). The order class populates country as the name of the country not as an array with a key as 'title'.

 

I think the best way round this at the moment is to remove the modifications to tep_address_format unless the bug that it was supposed to be fixing is a problem for you until a true bug fix is found.

 

Tom

 

Thanks ALOT :thumbsup: it's fixed now... just removed the "title" couse I don't use paypal

?,???`???,?? God must love stupid people, he made so many ??,???`???,?

Link to comment
Share on other sites

  • 3 weeks later...

For those who do need the fix that was included in the latest release so cannot just remove the [title]...

 

I also had the problem where just a U was showing instead of United Kingdom and although this isn't a great way of fixing this, it worked for me.

 

I edited the country names in my database and just added a space before them... therefore when the address is called to display it shows the space (nothing) rather than just the initial.

 

Hope this helps anyone.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...