nathanrobjohn
Forum Replies Created
Viewing 5 replies - 1 through 5 (of 5 total)
-
Forum: Your WordPress
In reply to: Please review my siteThanks will take a look into that, haven’t really had time to go over the site yet. Just about to start work on another site for Cardiff developers.
Forum: Fixing WordPress
In reply to: Flex slider integrationThanks guys! got it working by enqueue them didn’t know it was necessary now.
final code it anyone needs it.
<?php wp_enqueue_script('flex_header'); ?>
<script type="text/javascript" charset="utf-8"> $(window).load(function() { $('.flexslider').flexslider({ directionNav: "true" }); }); </script>
function flex_header() { //wp_enqueue_script('jquery'); wp_register_script( 'add-flex-js', get_template_directory_uri() . '/jquery.flexslider.js', array('jquery'),'',true ); wp_register_script( 'add-flex-custom-js', get_template_directory_uri() . '/jquery.flexslider-min.js', '', null,'' ); wp_register_style( 'add-flex-css', get_template_directory_uri() . '/flexslider.css','','', 'screen' ); wp_enqueue_script( 'add-flex-js' ); wp_enqueue_script( 'add-flex-custom-js' ); wp_enqueue_style( 'add-flex-css' ); } add_action( 'wp_enqueue_scripts', 'flex_header' );
<div class="flexslider"> <ul class="slides"> <?php query_posts(array('post_type'=>'Slider', 'category_name' => 'Residential')); if(have_posts()) : while(have_posts()) : the_post(); ?> <li> <?php the_post_thumbnail(); ?> <p class="flex-caption"><?php the_title(); ?></p> </li> <?php endwhile; endif; wp_reset_query(); ?> </ul> </div>
Thank you so much for your help.
Forum: Fixing WordPress
In reply to: Flex slider integrationi will be enqueueing them but i want to make sure it works properly first is that ok?
Forum: Fixing WordPress
In reply to: Flex slider integrationSorry im getting one error
Uncaught TypeError: Object [object Object] has no method ‘flexslider’ localhost/:49
(anonymous function) localhost/:49
x.event.dispatch jquery.min.js:5
v.handleForum: Fixing WordPress
In reply to: Flex slider integrationYes i am and no their is no errors showing i am using googles
Viewing 5 replies - 1 through 5 (of 5 total)