Hi Jerseygirl
You could create a snippet that does the following:
<?php include('/path/to/your/file.php'); ?>
Then place the shortcode into your post or page where you want to include it.
Hey Mr. Fraser! I wanted to piggyback on this question with a similar one. I’m trying to include a block of code. I wanted to make it an include because I’m probably going to be using it in various places. My problem is figuring out what to put for the ‘/path/to/your/file.php’
I’m new to wordpress and the way it handles file pathing is still new to me. I have a php file named newsCalWidget.php and it’s in my root theme folder. so…
wp-content/themese/StemWP/newsCalWidget.php
any help here would be fantastic!! Thanks