PHP & HTML in widget?
-
Hi
I have a pretty standard bit of code that’s not displaying properly, regardless if I use the “PHP” or the “HTML” option in the widgget.<?php if( get_field('datasheet') ): ?> <p><i class="fa fa-file" aria-hidden="true"></i> <a href="<?php the_field('datasheet'); ?>" target="_blank">Data Sheet</a></p> <?php endif; ?>
Can you combine the html and the php in one widget?
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘PHP & HTML in widget?’ is closed to new replies.