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)
-   -   [SOLVED] Trouble adding METEOR SLIDESHOW to template (http://forum.bytesforall.com/showthread.php?t=20490)

eddiefrankie Jun 12, 2013 12:11 AM

[SOLVED] Trouble adding METEOR SLIDESHOW to template
 
I'm trying to insert a slideshow to my index.php, so it looks like this"
Code:

<?php get_header(); ?>

<?php if ( function_exists( 'meteor_slideshow' ) ) { meteor_slideshow( "slides", "" ); } ?>

<div id="main" class="row">
       
                <div id="content" class="cf col9">
               
                <?php bfa_content_nav( 'multinav1' ); ?>
               
                <?php bfa_loop( 'postformat' ); ?>
               
                <?php bfa_content_nav( 'multinav2' ); ?>
               
        </div>
       
        <div id="widgetarea-one" class="col3">
                <?php dynamic_sidebar( 'Widget Area ONE' ); ?>
        </div>

</div>
       
<?php get_footer(); ?>

i can get it to work using the shortcode for a post, but somehow when i use the php, it doesn't work. does anyone have any experience with using the meteor slideshow in montezuma?

thanks so much.

CrouchingBruin Jun 12, 2013 02:47 AM

The virtual PHP files only allow a limited set of PHP code to be executed. You can view the allowable function calls by clicking on the gray Limited PHP Code in the upper right corner of the PHP options pages.

That being said, there is a way to get around it. You can create a widget area where you want your slideshow to appear, then drag a text widget into it, paste your PHP code into the text widget, and then install a plugin called Exec-PHP (HT to JuggleDad) so your PHP code will execute.

To create a widget area, insert a call to dynamic_sidebar with the name of your new widget area, for example:
<?php dynamic_sidebar( 'Widget Area Meteor' ); ?>
I would probably put a DIV around it with a unique ID so you could pretty it up in the CSS files later.
Save your options, then go to Appearances > Widgets and you should see your new widget area there (i.e., Widget Area Meteor), waiting for you to drag in a Text widget. Then just paste in your Meteor PHP code and you should be set.

eddiefrankie Jun 13, 2013 03:56 AM

thanks for looking into this.

you actually solved my problem in this post

Quote:

As far as the rotating images go, that's a plugin that is part of a class of plugins known as sliders or carousels. If you do a search on the Wordpress.org site for sliders, you should be able to find a lot. The one I'm using is called Weptile Image Slider. It's a nice simple plugin to use, but more importantly it is responsive (i.e., resizes according to the viewport size). The only tricky thing is that it is a widget plugin, meaning that you have to create a widget area to put the widget into. With Montezuma, that's very easy to do, because you can create a widget area in the header, footer, main body, wherever you want, and not just in a "side bar." I created a widget area in my header called Widget Area Header and just dragged the widget into it. One nice thing about using a widget plugin is that you don't have to worry about trying to insert a plugin's short code or PHP code into your virtual .PHP files, which won't work.
i used weptile instead and created a widget area like you described. much thanks. i'm learning so much new stuff.


All times are GMT -6. The time now is 12:01 PM.

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