All shortcodes not working on custom theme

So I finally found a solution!!! After many weeks of searching and trying different solutions, it was just a matter of removing “get_” from a reference of “the_content” in my page.php I changed this

<?php
                    function sup($text){

                        $true = preg_replace('#(\d+)(st|th|nd|rd)#', '$1<sup class="super">$2</sup>', $text);
                        return $true;

                    }
                echo sup(get_the_content()); ?>

To this

<?php
                    function sup($text){

                        $true = preg_replace('#(\d+)(st|th|nd|rd)#', '$1<sup class="super">$2</sup>', $text);
                        return $true;

                    }
                echo sup(the_content()); ?>

So far I have had no issues, and all the shortcodes are now working.
Thanks to all the others for their input, without it I wouldn’t have known where and what to look for.

Leave a Comment