I am setting up custom fields in Wordpress in order to be able to enter an ASIN number from amazon and have it pass through the shortcode I have in the template file.
In my custom field I am using Name:asin and Value:(whatever ASIN # I want to put in)
Here is what I have currently in the template file:
<?php $asin = get_post_meta( $post->ID, 'asin', true); ?>
<?php echo $asin ?>
<?php echo do_shortcode( '[scrapeazon asin="B002P4SMHM" width="650" height="400" border="false" country="us")]' );?>
I am trying to put the variable $asin into the scrapeazon shortcode that I have, something like this:
<?php echo do_shortcode( '[scrapeazon asin="<?php echo $asin ?" width="650" height="400" border="false" country="us")]' );?>
But this is not working, any ideas?