Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Montezuma Theme (http://forum.bytesforall.com/forumdisplay.php?f=53)
-   -   Can't output shortcode when customizinf footer.php (http://forum.bytesforall.com/showthread.php?t=20404)

UTAN_dev May 28, 2013 09:05 AM

Can't output shortcode when customizinf footer.php
 
I installed the Sponsors Carousel plugin and am having trouble getting the carousel to appear on my site. Using the UI, I added the following to Montezuma's footer.php:
HTML Code:

<!-- debug --><pre>
<?php echo sponsors_carousel(); ?>
</pre><!-- debug -->

<div id="footer-bg">
etc…

My changes do appear — a dotted area indicates the <pre> block and, if I add "Hello world" inside the <pre> area, it appears on the page. My problem:
PHP Code:

<?php echo sponsors_carousel(); ?>

outputs nothing.

I tried replacing the PHP with the plugin's shortcode equivalent:
PHP Code:

<?php echo do_shortcode ('[sponsors_carousel]'); ?>

And nothing showed up. I tried another plugin to ensure the problem didn't lie with Sponsors Carousel:
PHP Code:

<?php echo do_shortcode ('[table id=3 /]'); ?>

This leads me to think the issue is related to the theme. What's going on?

Thanks!

juggledad May 28, 2013 10:43 AM

are you editing the virtual or physical footer.php?

UTAN_dev May 28, 2013 11:36 AM

I'm editing via the UI at Montezuma Options. That's the virtual, right?

juggledad May 28, 2013 06:24 PM

Yes, but you are limited in the php you can use -see the tab in the upper right 'Limited PHP Code'

UTAN_dev May 29, 2013 08:23 AM

Juggledad, thanks for coming through yet again. I got all the answers I needed under the "Limited PHP Code" tab and I like the direction in which I'm being guided — putting my changes in a physical file in a child theme. Thanks!


All times are GMT -6. The time now is 08:03 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.