Hi, I'm trying to append the following to a div but having issues due to multiple ' and ".
Here's what I want to append:
- <?php echo do_shortcode( '[add_to_cart id="35"]' ); ?>
Script i'm using:
- $('.rpt_features_0').append('<?php echo do_shortcode( '[add_to_cart id="35"]' ); ?>');
I know there's a way of escaping the quotes, just cannot figure it out... I've tried adding \:
- $('.rpt_features_0').append('<?php echo do_shortcode( \'[add_to_cart id="35"]\' ); ?>');
But doesn't work... what am I doing wrong?
Cheers