title: Add custom css class to WooCommerce checkout fields
body: <p>I would like to be able to add a custom CSS class to my WooCommerce checkout fields. I'm using twitter Bootstrap and I would like to be able to use their .form-control class.</p>
  
  <p>I looked in the woocommerce templates folder in <code>form-billing.php</code> but I'm not sure where to add the <code>.form-control</code> class to each text field.</p>
  
  <p>Here is the code for <code>form-billing.php</code></p>
  
  <pre><code>&lt;?php
  /**
   * Checkout billing information form
   *
   * @author      WooThemes
   * @package     WooCommerce/Templates
   * @version     2.1.2
   */
  
   if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
   ?&gt;
   &lt;div class="woocommerce-billing-fields"&gt;
  &lt;?php if ( WC()-&gt;cart-&gt;ship_to_billing_address_only() &amp;&amp; WC()-&gt;cart-&gt;needs_shipping() ) : ?&gt;
  
      &lt;h3&gt;&lt;?php _e( 'Billing &amp;amp; Shipping', 'woocommerce' ); ?&gt;&lt;/h3&gt;
  
  &lt;?php else : ?&gt;
  
      &lt;h3&gt;&lt;?php _e( 'Billing Details', 'woocommerce' ); ?&gt;&lt;/h3&gt;
  
  &lt;?php endif; ?&gt;
  
  &lt;?php do_action( 'woocommerce_before_checkout_billing_form', $checkout ); ?&gt;
  
  &lt;?php foreach ( $checkout-&gt;checkout_fields['billing'] as $key =&gt; $field ) : ?&gt;
  
      &lt;?php woocommerce_form_field( $key, $field, $checkout-&gt;get_value( $key ) ); ?&gt;
  
  &lt;?php endforeach; ?&gt;
  
  &lt;?php do_action('woocommerce_after_checkout_billing_form', $checkout ); ?&gt;
  
  &lt;?php if ( ! is_user_logged_in() &amp;&amp; $checkout-&gt;enable_signup ) : ?&gt;
  
      &lt;?php if ( $checkout-&gt;enable_guest_checkout ) : ?&gt;
  
          &lt;p class="form-row form-row-wide create-account"&gt;
              &lt;input class="input-checkbox" id="createaccount" &lt;?php checked( ( true === $checkout-&gt;get_value( 'createaccount' ) || ( true === apply_filters( 'woocommerce_create_account_default_checked', false ) ) ), true) ?&gt; type="checkbox" name="createaccount" value="1" /&gt; &lt;label for="createaccount" class="checkbox"&gt;&lt;?php _e( 'Create an account?', 'woocommerce' ); ?&gt;&lt;/label&gt;
          &lt;/p&gt;
  
      &lt;?php endif; ?&gt;
  
      &lt;?php do_action( 'woocommerce_before_checkout_registration_form', $checkout ); ?&gt;
  
      &lt;?php if ( ! empty( $checkout-&gt;checkout_fields['account'] ) ) : ?&gt;
  
          &lt;div class="create-account"&gt;
  
              &lt;p&gt;&lt;?php _e( 'Create an account by entering the information below. If you are a returning customer please login at the top of the page.', 'woocommerce' ); ?&gt;&lt;/p&gt;
  
              &lt;?php foreach ( $checkout-&gt;checkout_fields['account'] as $key =&gt; $field ) : ?&gt;
  
                  &lt;?php woocommerce_form_field( $key, $field, $checkout-&gt;get_value( $key ) ); ?&gt;
  
              &lt;?php endforeach; ?&gt;
  
              &lt;div class="clear"&gt;&lt;/div&gt;
  
          &lt;/div&gt;
  
      &lt;?php endif; ?&gt;
  
      &lt;?php do_action( 'woocommerce_after_checkout_registration_form', $checkout ); ?&gt;
  
  &lt;?php endif; ?&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Do I need to to look in another template file?</p>
  
  <p>Thanks</p>