URGENT: woocommerce error code when trying to add custom field after product
-
Hello, can you help me please, I am trying to add this code in functions.php but it is giving me the error, please could you help me solve it, I will be grateful, thank you.
add_filter( 'the_content', 'misha_add_something_description_tab' ); function misha_add_something_description_tab( $content ){ if( is_product() ) { // I recommend to always use this condition $content .= '<table class="vertical-menu"> <tbody> <tr> <td class="cabecera"><?php if( get_field('download') ): ?><strong><i class="icon-checkmark"></i>Download:</strong></td> <td class="detail"><strong><?php the_field('download'); ?><?php endif; ?></strong></td> </tr> <tr> <td class="cabecera"><?php if( get_field('color') ): ?><strong><i class="icon-checkmark"></i>Color:</strong></td> <td class="detail"><strong><?php the_field('color'); ?><?php endif; ?></strong></td> </tr> </tbody> </table>'; } return $content; };
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘URGENT: woocommerce error code when trying to add custom field after product’ is closed to new replies.