Hi John,
I get this error when using your code:
Warning: Invalid argument supplied for foreach() in ... on line 83
I used the name of my field: book_type where you used checkbox_field.
Does it matter that it is a field used on a custom taxonomy? Not on a post.