Search Results

Search found 7 results on 1 pages for 'bxslider'.

Page 1/1 | 1 

  • Colorbox with bxslider not working

    - by Bill K
    Hello I am trying to use bxslider with colorbox. My implementation of bxslider is like an example listed here. The difference is that I want only the pagers to be shown. Also when the user clicks one pager I want colorbox to open and have next and previous buttons. The problem is that I cant group the images with colorbox and next and previous button is not shown! The following code uses the rel option but with this way colorbox doesnt event start. What I have tried till now is: HTML <div class="slider_mini" style="position:relative;bottom:0px;"> <div id="bx-pager"> <a data-slide-index="0" href="image.jpg" class="imgz"><img style="width:130px;height:104px;" src="image.jpg"/></a> <a data-slide-index="1" href="image2.jpg" class="imgz"><img style="width:130px;height:104px;" src="image2.jpg"/></a> <a data-slide-index="2" href="image3.jpg" class="imgz"><img style="width:130px;height:104px;" src="image3.jpg"/></a> </div> </div> SCRIPT <script type="text/javascript"> $(document).ready(function(){ $('.imgz').colorbox({rel:'imgz'}); $('.bxslider.two').bxSlider({ pagerCustom: '#bx-pager' }); $('#bx-pager').bxSlider({ slideWidth: 130, minSlides: 2, maxSlides: 3, moveSlides: 1, slideMargin: 10 }); }); </script> Not working Fiddle. Feedback: The problem was in live website that I was calling colorbox before bxslider. I put the call after bxslider's and it works. Thank you.

    Read the article

  • bxSlider-4 text slide pass into the next slide

    - by Martialp
    I use http://bxslider.com/ to slide some content, just simple text. But it seem to have a problem with the text, not the image. I post a simple live exemple : http://jsfiddle.net/Sbt75/324/ As you can see on the exemple, we see the previous text from the previous slide on the left of the active slide. <div class="row"> <div class="large-6 columns"> <ul class="bxslider"> <li><p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Accusantium, obcaecati, laudantium, blanditiis, adipisci quod eaque porro sapiente eligendi dicta voluptates voluptatum sunt aperiam totam modi quis vitae maxime! Dolor, possimus.</p></li> <li>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Odit, recusandae, delectus amet ipsa voluptate tempora architecto ad blanditiis officia perspiciatis nesciunt at ducimus quas nihil fuga. Qui optio minima accusamus?</li> <li><p class="right"> il etait une fois un grand mechant loupqui s'appelet jean et qui aimer courir dans l'herbe avec une grande harpe pour jouer dvant les enfants Lorem ipsum dolor sit amet, consectetur adipisicing elit. Odit, recusandae, delectus amet ipsa voluptate tempora architecto ad blanditiis officia perspiciatis nesciunt at ducimus quas nihil fuga. Qui optio minima accusamus? </p> </li> </ul> </div> </div> $(document).ready(function(){ $('.bxslider').bxSlider({ auto: false, autoControls: false, nextSelector: '#slider-next', prevSelector: '#slider-prev', nextText: 'Onward ?', prevText: '? Go back' }); });

    Read the article

  • bxslider and sproutvideo on iPad: video is just a black box when returning to slide [on hold]

    - by hm.
    I use sproutvideo inside of bxslider. I teste it well on chrome and firefox. On the iPad I have the following issue: I have the video in the forst screen and it loads fine, the slider stops when the video is running and when i switch to another slide and come back the video is still running. On the iPad, the video starts also, but when I go to anoter slide and back, the video disappears and I only see a black box. Any ideas what can be wrong?

    Read the article

  • jQuery slider to load content one at a time

    - by Barrett
    I have a slider that load all of my content at once. Into a div. Like so: external page.php $get_users = mysql_query("SELECT * FROM user WHERE id!='$user_id'"); while ($rows = mysql_fetch_assoc($get_users)) { $id = $rows['id']; $firstname = $rows['firstname']; $display_info .= ' <div class="f_outer" id="' . $id . '"> <div class="f_name likeu">' . $firstname . '</div> </div>'; } echo $display_info; I call this page from my find.php page using bxslider Here is my find.php page below. <script type="text/javascript"> $(function() { var slider = $("#slider1").bxSlider(); $("#slider-like").live('click', function() { slider.goToNextSlide(); return false; }); }); </script> <div id="slider-like>Yes</div> <div id="slider1"> <?PHP include ("external.php"); ?> </div> So what I get is all of my .f_outer div on the find.php page. I have hundreds of user and they will all be loaded at once. I would like to only load one slide at a time. So when I click #slider-like it load one of my dive from my external page.

    Read the article

  • Intro Bar like stack overflow

    - by Dasa
    I have a simple top bar using jquery like the one on stackoverflow, but i want it to only appear on the first time a person visits the website. below is the HTML followed by the "bxSlider.js" file <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script> <script type="text/javascript" src="bxSlider.js"></script> <title>topbar</title> <style type="text/css" media="screen"> #message { font-family:Arial,Helvetica,sans-serif; position:fixed; top:0px; left:0px; width:100%; z-index:105; text-align:center; color:white; padding:2px 0px 2px 0px; background-color:#8E1609; } #example1 { text-align: center; width: 80%; } .close-notify { white-space: nowrap; float:right; margin-right:10px; color:#fff; text-decoration:none; padding-left:3px; padding-right:3px } .close-notify a { color: #fff; } h4, p { margin:0px; padding:0px; } </style> </head> <body> <DIV ID='message' style="display: none;"> <DIV ID="example1"> <DIV CLASS="item"> <h4>Head 1</h4> <p>Text 1</p> </div><!-- end item --> <DIV CLASS="item"> <h4>Head 2</h4> <p>Text 2</p> </div><!-- end item --> </div><!-- end example1 --> <a href="#" CLASS="close-notify" onclick="closeNotice()">X</a> </div> <script type="text/javascript"> $(document).ready(function() { $("#message").fadeIn("slow"); $('#example1').bxSlider({ mode: 'slide', speed: 250, wrapper_CLASS: 'example1_container' }); }); function closeNotice() { $("#message").fadeOut("slow"); } </script> </body> </html> /** * * * bxSlider: Content slider / fade / ticker using the jQuery javascript library. * * Author: Steven Wanderski * Email: [email protected] * URL: http://bxslider.com * * **/ jQuery.fn.bxSlider = function(options){ ///////////////////////////////////////////////////////////////////////////////////////////////////////////// // Declare variables and functions ///////////////////////////////////////////////////////////////////////////////////////////////////////////// var defaults = { mode: 'slide', speed: 500, auto: false, auto_direction: 'left', pause: 2500, controls: true, prev_text: 'prev', next_text: 'next', width: $(this).children().width(), prev_img: '', next_img: '', ticker_direction: 'left', wrapper_class: 'container' }; options = $.extend(defaults, options); if(options.mode == 'ticker'){ options.auto = true; } var $this = $(this); var $parent_width = options.width; var current = 0; var is_working = false; var child_count = $this.children().size(); var i = 0; var j = 0; var k = 0; function animate_next(){ is_working = true; $this.animate({'left':'-' + $parent_width * 2 + 'px'}, options.speed, function(){ $this.css({'left':'-' + $parent_width + 'px'}).children(':first').appendTo($this); is_working = false; }); } function animate_prev(){ is_working = true; $this.animate({'left': 0}, options.speed, function(){ $this.css({'left':'-' + $parent_width + 'px'}).children(':last').insertBefore($this.children(':first')); is_working = false; }); } function fade(direction){ if(direction == 'next'){ var last_before_switch = child_count - 1; var start_over = 0; var incr = k + 1; }else if(direction == 'prev'){ var last_before_switch = 0; var start_over = child_count -1; var incr = k - 1; } is_working = true; if(k == last_before_switch){ $this.children().eq(k).fadeTo(options.speed, 0); $this.children().eq(start_over).fadeTo(options.speed, 1, function(){ is_working = false; k = start_over; }); }else{ $this.children().eq(k).fadeTo(options.speed, 0); $this.children().eq(incr).fadeTo(options.speed, 1, function(){ is_working = false; k = incr; }); } } function add_controls(){ ///////////////////////////////////////////////////////////////////////////////////////////////////////////// // Check if user selected images to use for next / prev ///////////////////////////////////////////////////////////////////////////////////////////////////////////// if(options.prev_img != '' || options.next_img != ''){ $this.parent().append('<a class="slider_prev" href=""><img src="' + options.prev_img + '" alt=""/></a><a class="slider_next" href=""><img src="' + options.next_img + '" alt="" /></a>'); }else{ $this.parent().append('<a class="slider_prev" href="">' + options.prev_text + '</a><a class="slider_next" href="">' + options.next_text + '</a>'); } $this.parent().find('.slider_prev').css({'float':'left', 'outline':'0', 'color':'yellow'}); $this.parent().find('.slider_next').css({'float':'right', 'outline':'0', 'color':'yellow'}); ///////////////////////////////////////////////////////////////////////////////////////////////////////////// // Accomodate padding-top for controls when elements are absolutely positioned (only in fade mode) ///////////////////////////////////////////////////////////////////////////////////////////////////////////// if(options.mode == 'fade'){ $this.parent().find('.slider_prev').css({'paddingTop' : $this.children().height()}) $this.parent().find('.slider_next').css({'paddingTop' : $this.children().height()}) } ///////////////////////////////////////////////////////////////////////////////////////////////////////////// // Actions when user clicks next / prev buttons ///////////////////////////////////////////////////////////////////////////////////////////////////////////// $this.parent().find('.slider_next').click(function(){ if(!is_working){ if(options.mode == 'slide'){ animate_next(); if(options.auto){ clearInterval($.t); $.t = setInterval(function(){animate_next();}, options.pause); } }else if(options.mode == 'fade'){ fade('next'); if(options.auto){ clearInterval($.t); $.t = setInterval(function(){fade('next');}, options.pause); } } } return false; }); $this.parent().find('.slider_prev').click(function(){ if(!is_working){ if(options.mode == 'slide'){ animate_prev(); if(options.auto){ clearInterval($.t); $.t = setInterval(function(){animate_prev();}, options.pause); } }else if(options.mode == 'fade'){ fade('prev'); if(options.auto){ clearInterval($.t); $.t = setInterval(function(){fade('prev');}, options.pause); } } } return false; }); } function ticker() { if(options.ticker_direction == 'left'){ $this.animate({'left':'-' + $parent_width * 2 + 'px'}, options.speed, 'linear', function(){ $this.css({'left':'-' + $parent_width + 'px'}).children(':first').appendTo($this); ticker(); }); }else if(options.ticker_direction == 'right'){ $this.animate({'left': 0}, options.speed, 'linear', function(){ $this.css({'left':'-' + $parent_width + 'px'}).children(':last').insertBefore($this.children(':first')); ticker(); }); } } ///////////////////////////////////////////////////////////////////////////////////////////////////////////// // Create content wrapper and set CSS ///////////////////////////////////////////////////////////////////////////////////////////////////////////// $this.wrap('<div class="' + options.wrapper_class + '"></div>'); //console.log($this.parent().css('paddingTop')); if(options.mode == 'slide' || options.mode == 'ticker'){ $this.parent().css({ 'overflow' : 'hidden', 'position' : 'relative', 'margin' : '0 auto', 'width' : options.width + 'px' }); $this.css({ 'width' : '999999px', 'position' : 'relative', 'left' : '-' + $parent_width + 'px' }); $this.children().css({ 'float' : 'left', 'width' : $parent_width }); $this.children(':last').insertBefore($this.children(':first')); }else if(options.mode == 'fade'){ $this.parent().css({ 'overflow' : 'hidden', 'position' : 'relative', 'width' : options.width + 'px' //'height' : $this.children().height() }); if(!options.controls){ $this.parent().css({'height' : $this.children().height()}); } $this.children().css({ 'position' : 'absolute', 'width' : $parent_width, 'listStyle' : 'none', 'opacity' : 0 }); $this.children(':first').css({ 'opacity' : 1 }); } ///////////////////////////////////////////////////////////////////////////////////////////////////////////// // Check if user selected "auto" ///////////////////////////////////////////////////////////////////////////////////////////////////////////// if(!options.auto){ add_controls(); }else{ if(options.mode == 'ticker'){ ticker(); }else{ ///////////////////////////////////////////////////////////////////////////////////////////////////////////// // Set a timed interval ///////////////////////////////////////////////////////////////////////////////////////////////////////////// if(options.mode == 'slide'){ if(options.auto_direction == 'left'){ $.t = setInterval(function(){animate_next();}, options.pause); }else if(options.auto_direction == 'right'){ $.t = setInterval(function(){animate_prev();}, options.pause); } }else if(options.mode == 'fade'){ if(options.auto_direction == 'left'){ $.t = setInterval(function(){fade('next');}, options.pause); }else if(options.auto_direction == 'right'){ $.t = setInterval(function(){fade('prev');}, options.pause); } } if(options.controls){ add_controls(); } } } }

    Read the article

  • Wordpress Template HTML CSS Layout Confusion

    - by Jess McKenzie
    I am having huge confusion with a template that I have purchased and I am trying to modify to handle a widget contact form. I am getting close with this but I have now muddled up the CSS or I have a feeling every page has a different CSS structure. The General Layout: What I Manage To Get: HTML View Source: <div id="innerright"> <div id="home" class="page"> <div id="homeslides"> <div class="welcomeslide"> <h1 class="large">Welcome</h1> </div> </div><!-- end home slides --> </div><!-- end page --> <div id="portfolio" class="page"> <div class="verticalline"> <div class="scrollprevnext"></div> </div> <div class="pageheader"> <h3><span>P</span>ortfolio</h3> </div><!--end pageheader --> <div id="portfolioscroller" class="scrollerenabledpage"> <div class="content"> <h5>Recent Work</h5> <ul class="thumb"> <li><a rel="precision_gallery" href="" title=""><img alt="" src="" /></a></li> </ul> </div> </div><!--end v scroll inner--> </div><!-- end page --> <div id="contact" class="page"> <div class="verticalline"> <div class="scrollprevnext"></div> </div> <div class="pageheader"> <h3><span>C</span>ontact</h3> </div><!--end pageheader --> <div id="contactscroller"> <h5>Get In Touch</h5> <div id="contactform">content</div> </div><!--end v scroll inner--> </div><!-- end page --> </div><!--end innerright--> CSS: CSS index.php: <!DOCTYPE HTML> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title><?php bloginfo('name'); ?></title> <link rel="stylesheet" type="text/css" href="<?php echo get_template_directory_uri(); ?>/style.css" /> <link rel="stylesheet" type="text/css" href="<?php echo get_template_directory_uri(); ?>/fancybox/jquery.fancybox-1.3.4.css" media="screen" /> <?php // jquery will be included by wp_head function as well as scripts and styles by third party plugins wp_head(); ?> <script type="text/javascript" src="<?php echo get_template_directory_uri(); ?>/js/plugins.js"></script> <script type="text/javascript" src="<?php echo get_template_directory_uri(); ?>/js/script.js"></script> <script type="text/javascript" src="<?php echo get_template_directory_uri(); ?>/fancybox/jquery.fancybox-1.3.4.pack.js"></script> <?php // background image if one has been set via options if (function_exists('get_option_tree')) { $background_image = get_option_tree('precision_background_image'); //$background_image = ''; $background_color = get_option_tree('precision_background_color'); if ($background_color != '') { echo '<style>body { background-color:'.$background_color.'; }</style>'; } } ?> <script type="text/javascript"> jQuery(document).ready(function($) { $('.page').each(function(index, element) { $(this).css('left', index * 500); }); <?php // if background is set via the OptionTree then load it first if ($background_image != '') { ?> $.vegas({ src:'<?php echo $background_image; ?>', fade:1000, complete:function() { $("#wrapper").fadeIn(1000); $("#bgpanel").fadeIn(1000); $('#mainslide').crossSlide( { speed: 15, fade: 1 }, [ <?php echo $slides; ?> ] ) $('#homeslides').bxSlider({ mode: 'fade', auto: true, controls:false, speed:1000, pause:5000 }); } }); <?php } else { // if no background has been set then fade-in the page ?> $("#wrapper").fadeIn(1000); $("#bgpanel").fadeIn(1000); $('#mainslide').crossSlide( { speed: 15, fade: 1 }, [ //ENTER YOUR MAIN SLIDESHOW IMAGES HERE\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ <?php echo $slides; ?> ] ) $('#homeslides').bxSlider({ mode: 'fade', auto: true, controls:false, speed:1000, pause:5000 }); <?php } ?> //BX SLIDER INNER PAGE SCROLLERS//////////////////////// $('.scrollerenabledpage').each(function(index, element) { $('#' + $(this).attr('id')).bxSlider({ mode: 'vertical', easing: 'easeInOutQuint', auto: false, controls: true, prevImage:'<?php echo get_template_directory_uri(); ?>/images/up.png', nextImage:'<?php echo get_template_directory_uri(); ?>/images/down.png', infiniteLoop: false, hideControlOnEnd: true, pager: true, pagerType:'short', pagerShortSeparator:'of', speed:800, }); }); //END BX SLIDER INNER PAGE SCROLLERS///////////////// $('#submit').click(function(e) { e.preventDefault(); $('form').submit(); }); // contact form $('form').submit(function(e) { $('#main').append('<img src="<?php echo get_template_directory_uri(); ?>/images/loader.gif" class="loaderIcon" alt="Loading..." />'); $.post("<?php bloginfo('wpurl'); ?>/wp-admin/admin-ajax.php", {action:'precision_contact_form_handler', uname:$('input#uname').val(), uemail:$('input#uemail').val(), ucomments:$('textarea#ucomments').val()}, function(data) { $('#main img.loaderIcon').fadeOut(1000); if (data.status == "success") { $('#response').html("Forum has been successfully submitted."); } else { if (data.response != '') { $('#response').html(data.response); } else { $('#response').html("An error occurred while submitting the form. Please try again."); } } }, "json"); return false; }); }); //hides contact form labels when a field gets focus function initOverLabels () { if (!document.getElementById) return; var labels, id, field; labels = document.getElementsByTagName('label'); for (var i = 0; i < labels.length; i++) { if (labels[i].className == 'overlabel') { id = labels[i].htmlFor || labels[i].getAttribute('for'); if (!id || !(field = document.getElementById(id))) { continue; } labels[i].className = 'overlabel-apply'; if (field.value !== '') { hideLabel(field.getAttribute('id'), true); } field.onfocus = function () { hideLabel(this.getAttribute('id'), true); }; field.onblur = function () { if (this.value === '') { hideLabel(this.getAttribute('id'), false); } }; labels[i].onclick = function () { var id, field; id = this.getAttribute('for'); if (id && (field = document.getElementById(id))) { field.focus(); } }; } } }; function hideLabel(field_id, hide) { var field_for; var labels = document.getElementsByTagName('label'); for (var i = 0; i < labels.length; i++) { field_for = labels[i].htmlFor || labels[i].getAttribute('for'); if (field_for == field_id) { labels[i].style.textIndent = (hide) ? '-1000px' : '0px'; return true; } } } window.onload = function () { setTimeout(initOverLabels, 50); }; </script> <?php if (function_exists('get_option_tree')) { $precision_font_family_1 = get_option_tree('precision_font_family_1'); ?> <link href='http://fonts.googleapis.com/css?family=<?php echo $precision_font_family_1; ?>' rel='stylesheet' type='text/css'> <?php } ?> <style> h1, h2 { font-family:<?php echo $precision_font_family_1; ?>; } </style> </head> <body> <div id="wrapper"> <div id="innerleft"> <div id="header"> <?php if (function_exists('get_option_tree')) { $site_logo = get_option_tree('precision_site_logo'); ?> <a href="/" title="<?php bloginfo('name');?>"><img src="<?php echo $site_logo; ?>" alt="<?php bloginfo('name');?>" /></a> <?php } ?> </div><!--end header--> <?php if (function_exists('get_option_tree')) { $precision_slideshow_image = get_option_tree('precision_slideshow_image'); } ?> <ul id="nav"><!--Navigation--> <?php //instead of using wp_nav_menu, we use wp_get_nav_menu_items so that we can store the data in array and re-use it again //wp_nav_menu(array('theme_location' => 'precision-main-menu', 'container' => 'false')); $slt_menuItems = wp_get_nav_menu_items( "precision-main-menu" ); $menusItems = array(); foreach ($slt_menuItems as $slt_menuItem) { $page_title = $slt_menuItem->title; $menuItem = new stdClass; $menuItem->title = $page_title; $menuItem->page_id = $slt_menuItem->object_id; $menusItems[] = $menuItem; ?> <li id="<?php echo strtolower($page_title); ?>nav"><a href="#<?php echo strtolower($page_title); ?>"><?php echo $page_title; ?></a></li> <?php } ?> </ul> <div id="socialMedia"> <ul class="social"> <?php if (function_exists('get_option_tree')) { $twitter_link = get_option_tree('precision_twitter_link'); $facebook_link = get_option_tree('precision_facebook_link'); $gplus_link = get_option_tree('precision_gplus_link'); $delicious_link = get_option_tree('precision_delicious_link'); $flickr_link = get_option_tree('precision_flickr_link'); $vimeo_link = get_option_tree('precision_vimeo_link'); $youtube_link = get_option_tree('precision_youtube_link'); $linkedin_link = get_option_tree('precision_linkedin_link'); ?> <!-- start linkedin icon --> <?php if($linkedin_link != ''){ ?> <li><a href="<?php echo $linkedin_link;?>" title="Follow <?php bloginfo('name'); ?> on Linkedin"><img src="<?php echo get_template_directory_uri();?>/images/social-icons/linkedin.png" width="49" height="64" alt="<?php bloginfo('name'); ?> Linkedin"/></a><li> <?php } ?> <!-- end linkedin icon --> <!--start twitter icon--> <?php if ($twitter_link != '') { ?> <li><a href="<?php echo $twitter_link; ?>" title="Follow <?php bloginfo('name'); ?> on Twitter"><img src="<?php echo get_template_directory_uri(); ?>/images/social-icons/twitter.png" width="49" height="64" alt="<?php bloginfo('name'); ?> Twitter" /></a></li> <?php } ?> <!--end twitter icon--> <!--start facebook icon--> <?php if ($facebook_link != '') { ?> <li><a href="<?php echo $facebook_link; ?>" title="Follow <?php bloginfo('name'); ?> on Facebook"><img src="<?php echo get_template_directory_uri(); ?>/images/social-icons/facebook.png" width="49" height="64" alt="<?php bloginfo('name'); ?> Facebook" /></a></li> <?php } ?> <!--end facebook icon--> <!--start google plus icon--> <?php if ($gplus_link != '') { ?> <li><a href="<?php echo $gplus_link; ?>"><img src="<?php echo get_template_directory_uri(); ?>/images/social-icons/google_plus.png" width="16" height="16" alt="google+" /></a></li> <?php } ?> <!--end google plus icon--> <!--start delicious icon--> <?php if ($delicious_link != '') { ?> <li><a href="<?php echo $delicious_link; ?>"><img src="<?php echo get_template_directory_uri(); ?>/images/social-icons/delicious.png" width="16" height="16" alt="delicious" /></a></li> <?php } ?> <!--end delicious icon--> <!--start flickr icon--> <?php if ($flickr_link != '') { ?> <li><a href="<?php echo $flickr_link; ?>"><img src="<?php echo get_template_directory_uri(); ?>/images/social-icons/flickr.png" width="16" height="16" alt="flickr" /></a></li> <?php } ?> <!--end flickr icon--> <!--start vimeo icon--> <?php if ($vimeo_link != '') { ?> <li><a href="<?php echo $vimeo_link; ?>"><img src="<?php echo get_template_directory_uri(); ?>/images/social-icons/vimeo.png" width="16" height="16" alt="vimeo" /></a></li> <?php } ?> <!--end vimeo icon--> <!--start youtube icon--> <?php if ($youtube_link != '') { ?> <li><a href="<?php echo $youtube_link; ?>"><img src="<?php echo get_template_directory_uri(); ?>/images/social-icons/youtube.png" width="16" height="16" alt="youtube" /></a></li> <?php } ?> <!--end youtube icon--> <?php } ?> </ul> </div> </div><!--end innerleft--> <div id="innerright"> <?php if (function_exists('get_option_tree')) { $precision_home_page_option = get_option_tree('precision_home_page'); $precision_home_page = strtolower(get_the_title($precision_home_page_option)); if ($precision_home_page == '') { $precision_home_page = 'home'; } $precision_contact_page_option = get_option_tree('precision_contact_page'); $precision_contact_page = strtolower(get_the_title($precision_contact_page_option)); if ($precision_contact_page == '') { $precision_contact_page = 'contact'; } } foreach ($menusItems as $menuItem) { ?> <div id="<?php echo strtolower($menuItem->title); ?>" class="page"> <?php if (strtolower($menuItem->title) == $precision_home_page) { ?> <div id="homeslides"> <?php $page_data = get_page($menuItem->page_id); $content = apply_filters('the_content', $page_data->post_content); echo $content; ?> </div><!-- end home slides --> <?php } else { ?> <div class="verticalline"> <div class="scrollprevnext"></div> </div> <div class="pageheader"> <h3><span><?php echo substr($menuItem->title, 0, 1); ?></span><?php echo substr($menuItem->title, 1); ?></h3> </div><!--end pageheader --> <?php $classes = ''; if (strtolower($menuItem->title) == $precision_contact_page) { ?> <div id="<?php echo strtolower($menuItem->title); ?>scroller"> <?php $page_data = get_page($menuItem->page_id); $content = apply_filters('the_content', $page_data->post_content); echo $content; ?> </div><!--end v scroll inner--> <?php } else { $classes = 'scrollerenabledpage'; ?> <div id="<?php echo strtolower($menuItem->title); ?>scroller" class="<?php echo $classes; ?>"> <?php $page_data = get_page($menuItem->page_id); $content = apply_filters('the_content', $page_data->post_content); echo $content; ?> </div><!--end v scroll inner--> <?php } } ?> </div><!-- end page --> <?php } ?> </div><!--end innerright--> <div id="footer"> <p>&copy; <a href="/"><?php bloginfo('name');?></a> | <?php echo date('Y');?></p> </div> </div><!--end wrapper--> </div> <!--Live Preview--> </body> </html>

    Read the article

  • jQuery carousel in a div with display:none

    - by Fred Kafka
    I have to use on my site a jQuery responsive carousel with 4 displayed items that slide one at a time, etc etc. The point is: this carousel is placed in a div with display:none and it appears clicking on a button with a slideToggle script (jQuery). Well, when the div appears the carousel is not displayed. Nothing! Notice that if I remove the display:none the carousel shows perfectly. I've tried a bunch of carousel plugin (bxslider, caroufredsel, elastislide, flexslider) and this issue happens for all of them. And then... I'm going crazy!! Excuse meSorry friends, here is the code: HTML (here is the case of FlexSlider but the code is similar for the other plugins) <div id="hiddenDiv"> <div id="hiddenDivInner"> <div class="flexslider"> <ul class="slides"> <li>...</li> <li>...</li> <li>...</li> </ul> </div> </div> </div> CSS #hiddenDiv{ display:none; padding-bottom:10px; background: url("../img/xxx.gif") repeat left bottom #FFFFFF; } SCRIPT (copy-paste from the site. This script is between $(document).ready together with other scripts. Alredy tried to remove the load function) $(window).load(function() { $('.flexslider').flexslider({ animation: "slide", animationLoop: false, itemWidth: 300, itemMargin: 5, minItems: 1, maxItems: 4 }); }); $("#trigger").click(function () { $("#hiddenDiv").slideToggle(400, "easeInOutExpo"); }); I remind you that with this code and no display:none every carousels work, also if I slide up and then down the div using the slideToggle button (#trigger).

    Read the article

1