I'm trying to make a filter in functions.php
of my website in Wordpress, to show some information on the customer's invoice:
echo get_post_meta($order_id,'bairro',true) . get_post_meta($order_id,'billing_complemento',true);
I've tried the following, it's retrieving the information all together, I wanted to divide it into lines. I tried it this way:
<tr class=“bairro”>
<td><b>Bairro: </b> R$ <?php echo get_post_meta($order_id,'bairro',true) ?></td>
</tr>
<tr class=“billing_complemento”>
<td><b>Complemento: </b> <?php echo get_post_meta($order_id,'billing_complemento',true) ?></td>
</tr>
<?php
but it’s giving a fatal error on the site, I believe it’s just some kind of closure. Someone to save me there?
question from:
https://stackoverflow.com/questions/65643989/fatal-error-when-try-add-snippets-code-on-functions-php-wordpress 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…