Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Calling entry_state from database


monkeybidz13

Recommended Posts

I am trying to call entry_state from table "address_book" and get all infromation back except for entry_state. I know it is NULL and was wondering if anyone can help me redefine this code to call entry_state.

 

Here is the code I am using for my custom page:

$sql = tep_db_query("SELECT entry_street_address, entry_city, entry_state, entry_postcode from " . TABLE_ADDRESS_BOOK . " WHERE customers_id = '" . (int)$customer_id . "'");
 $account2 = tep_db_fetch_array($sql);

 

When I echo all these on a page, I get nothing for entry_state.

 

Any ideas?

 

Thanks in advance!

Link to comment
Share on other sites

You get nothing for entry_state perhaps because there is nothing in the database for entry_state. Please go to Admin => "Customer Details" and verify if "state" is set to true.

Open source n'est pas un échange à sens unique ... La plupart du temps un simple merci ou quelques mots d'encouragement suffisent...

Link to comment
Share on other sites

You get nothing for entry_state perhaps because there is nothing in the database for entry_state. Please go to Admin => "Customer Details" and verify if "state" is set to true.

 

What I was trying to do, was get each table individualy to echo a table, but I ended up just using the query from address_book.php to get the entire name and address after all and just reformated my custom page. I would have preferred to grab each table idividually.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...