We recently had to do some work for a client where they were only allowed to ship to certain states due to alcohol license shipping restrictions. Our needs were pretty simple and we didn’t want unnecessary overhead to affect performance, so we rolled our own solution with a custom module.

This example is a very simple case, where users can purchase from anywhere, but only ship within California. To accomplish this, we used Drupal hook_form_alter to modify a form element only on the shipping panel:

 'California'
    );
}
?>

Leave a Reply