Hey guys,
Thanks for the information. I have been receiving orders over the past 3-4 days where the delivery address has been blank. This just started on a very stable install where no modifications have been made in months. It seems to occur on about half of our orders and to date I cannot find anything in common among the orders with errors (such as payment type, etc.).
I found I could use phpMyAdmin to manually enter the data, but that data still did not display in my Zencart Admin panel.
I tried everything to fix it. First I did a restore on the website from backup files saved prior to when the problem began. It was a partial restore of just the admin and includes files. That did not fix it.
Then I contacted my webhost to see if there had been any patches/updates/upgrades to MySql and PHP that might have been incompatible with the ZenCart code (v3.8.1a). The host reported no changes for quite some time.
At this point I was completely at a loss as to what was going on until I read this thread. For whatever reason the address data wasn't stored in the first place, the "delivery_address_format_id" was set as "0" ("2" would be correct for my store.) After manually changing that to "2" my order details in admin began to show the addresses that I manually entered.
I completed a FULL RESTORE of the files tonight and hopefully that will get the new orders to save all the data. If not, at least I know to start looking for where the address_format_ids and the delivery name and address are processed. You saved me a bunch of time as I'm sure the format id's would have been the last thing for me to check.