Quantcast
Channel: WordPress.org Forums » All Topics
Viewing all articles
Browse latest Browse all 82367

Using in PHP Shortcode not working

$
0
0

Replies: 0

I have a weird issue with this plugin not working via do_shortcode and I wonder if you can help.

I have the ISBN as part of ACF, and I am calling that in PHP – I echo it and it displays the correct ISBN, but when I insert it as a variable inside the do_shortcode, it fails to display. Any ideas why that is? Other plugins using this method work fine, just not Good Reviews 🙁


<?php
$isbn_number = the_field('isbn');
echo $isbn_number;
echo do_shortcode('[goodreviews buyinfo="off" bookinfo="on" author="large" cover="large" grbackground="000" grtext="fff" height="500" width="500" border="off" isbn="' . $isbn_number . '"]');
?>

Thanks!


Viewing all articles
Browse latest Browse all 82367

Trending Articles