Last active
November 14, 2017 23:50
-
-
Save SirDarcanos/53f642f0fa780019e3eb to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'woocommerce_product_tabs', 'woo_edit_tabs' ); | |
function woo_edit_tabs( $tabs ) { | |
// Adds the new tab | |
$tabs['enquiry_form'] = array( | |
'title' => __( 'Ask a question', 'woocommerce' ), | |
'priority' => 50, | |
'callback' => 'woo_enquiry_form' | |
); | |
return $tabs; | |
} | |
function woo_enquiry_form() { | |
echo '<h2>' . __( 'Do you have a question?', 'woocommerce' ) . '</h2>'; | |
echo '<p>' . __( 'Drop us a line by compiling the form below. We will be more than happy to reply to any of your questions!', 'woocommerce' ) . '</p>'; | |
echo do_shortcode( '[your_form_shortcode_here]' ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment