Hide a Prepopulated email textfield I am trying to prepopulate the following fields on a commerce add-to-cart form and then hide the email field:


Recipient name: (textfield) = field_recipient_name
Recipient email: (email field) = field_recipient_email


So far i have been able to pre-populate these fields using views, panels, and prepopulate modules. My challenge is this:

If the email field is already prepopulated with a value, hide this field from the user who intends to buy a gift for the recipient, otherwise the field should be exposed so that user can manually enter the email of the gift recipient. Thanks
Perhaps you can use the Conditional Fields module to check whether the field has a value (sort of a 'not empty' check). 

Conditional Fields is described as follows:

Conditional Fields allows you to manage sets of dependencies between fields. When a field is “dependent”, it will only be available for editing and displayed if the state of the “dependee” field matches the right condition.