Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Warnings in the Billing Address! What the Heck! Please Help!


curtis_george1

Recommended Posts

I get the following warning several times where the billing address is supposed to be. I am not sure what happened.

 

Warning: htmlspecialchars() expects parameter 1 to be string, array given in /home/mlynch5/public_html/default/includes/functions/general.php on line 46

 

Thanks,

 

Curtis :-"

Link to comment
Share on other sites

open your catalog/includes/functions/general.php locate this code.

 

$country = tep_output_string_protected($address['country']);

 

replace it with:

 

if( is_array($address['country']) ) {
	$country = tep_output_string_protected($address['country']['title']);
  } else {
	$country = tep_output_string_protected($address['country']);
  }

Link to comment
Share on other sites

Thanks enigma1,

 

I tried it but I get the same warning where the billing address should be on the confirmation page.

 

Curtis

 

open your catalog/includes/functions/general.php locate this code.

 

$country = tep_output_string_protected($address['country']);

 

replace it with:

 

if( is_array($address['country']) ) {
	$country = tep_output_string_protected($address['country']['title']);
  } else {
	$country = tep_output_string_protected($address['country']);
  }

Link to comment
Share on other sites

Hello,

Have you solved the problem? I'm having the same problem and I'm at the point where I'm going to have try to patch this somehow because I've done way too much work on the store to start over. I think I know how to patch it but it's not going to be quick or fun and I'd rather fix the current code then ptch it with my "special" php. In the event that you haven't solved this I'll provide the ptach if you like.

 

Thanks enigma1,

 

I tried it but I get the same warning where the billing address should be on the confirmation page.

 

Curtis

Link to comment
Share on other sites

Thanks enigma1,

 

I tried it but I get the same warning where the billing address should be on the confirmation page.

 

Curtis

 

The next thing to do is to check the database. But first does this problem happens if you create a new account and go through a regular checkout?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...