/ Published in: PHP
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<?php function my_example() { return 'my example text'; // or echo } ?> <?php add_shortcode('mytest', 'my_example');?> Then add [mytest] to the post.