JavaScript - Looking For Simple Ie6 Image Slider/rotator
I just need something that rotates/slides a few images when a page loads. I'd guess Jquery would work best? But it needs to work in all browsers, and I have read some horror stories about ones that don't. Any good recommendations?
Similar TutorialsOk, so I currently have a rotator on my site that rotates every 5 seconds. I'd like to change it to where anytime between 10pm and 7pm, it rotates as normal. But at 7pm I'd like it to stay on one specific image. At 8, it stays on another image. Then at 9, it stays on another image. Basically, I work at at TV station so at 7 I want the graphic to be the show that is on TV. The same at 8 and 9. Here's a link to the js file. http://tinyurl.com/3h5bz6p Hello, I have recently been working on a website which will have rotating background images. I have found a useful javascript code (i don't know who the author is) which rotates different background images neatly after x milliseconds. here is the code: ==== <script language="JavaScript1.2"> var bgimages=new Array() bgimages[0]="../gfx/bgs/bg1.jpg" bgimages[1]="../gfx/bgs/bg2.jpg" //preload images var pathToImg=new Array() for (i=0;i<bgimages.length;i++){ pathToImg[i]=new Image() pathToImg[i].src=bgimages[i] } var inc=-1 function bgSlide(){ if (inc<bgimages.length-1) inc++ else inc=0 document.body.background=pathToImg[inc].src } if (document.all||document.getElementById) window.onload=new Function('setInterval("bgSlide()",6000)') </script> ==== The script works, and the background images rotate. However, currently the rotation of the images have no effect. I would like to add the effect of the images blending into each other when they rotate. How would this be possible? Thanks a bunch! -Captainel I have added an image rotator to my website using Java Script. The box for the rotator shows up on the published site but not the pictures. When I click on the box it links to the pictures I have added, and I know they are rotating because it changes every time I click on it. Also, the code does not seem to be showing up when I view the source of the page. This is a link to my site: http://www.jenniferbrenn.com/Fashion/Home.html the problem is in the box beneath the name "Jenny" near the bottom of the page. This is the code I am using: [CODE] <script language="JavaScript"> // Copyright 1996, Infohiway, Inc. (http://www.infohiway.com) // Courtesy of SimplytheBest.net - http://simplythebest.net/scripts/ <!-- function adArray() { for (i=0; i*2<adArray.arguments.length; i++) { this[i] = new Object(); this[i].src = adArray.arguments[i*2]; this[i].href = adArray.arguments[i*2+1]; } this.length = i; } function getAdNum() { dat = new Date(); dat = (dat.getTime()+"").charAt(8); if (dat.length == 1) ad_num = dat%ads.length; else ad_num = 0; return ad_num; } var ads = new adArray( "images/banner_1.gif","http://web.me.com/jim.stevenson/Fashion/Media/bee_vogue.jpg", "images/banner_2.gif","http://www.superficialdiva.com/wp-content/uploads/2009/01/hana-soukupova-vogue-belleza-february-2009-magazine-cover.jpg", "images/banner_3.gif","http://bp3.blogger.com/_maRo3z-KVqA/R9IKSDQPIwI/AAAAAAAAB4g/ghZysBSq-9M/s400/Victoria-Beckham-Vogue.jpg"); var ad_num = getAdNum(); document.write('<CENTER><TABLE CELLPADDING=0 CELLSPACING=1 BORDER=0><TR><TD ' +'ALIGN=CENTER><FONT SIZE=2 FACE=Arial><B>Jenny ' +'</FONT></TD><TR></TR><TD><A HREF="'+ads[ad_num].href+'"><IMG SRC="'+ads[ad_num].src+'" ' +'WIDTH="240" HEIGHT="320" BORDER=0 name=js_ad></A></TD></TR></TABLE></CENTER>'); link_num = document.links.length-1; function rotateSponsor() { if (document.images) { ad_num = (ad_num+1)%ads.length; document.js_ad.src = ads[ad_num].src; document.links[link_num].href = ads[ad_num].href; setTimeout("rotateSponsor()",5000); } } setTimeout("rotateSponsor()",5000); // --> </script> [CODE] I am working on a site for someone, and they asked me to have a small link-bar that has small thumbnail pictures next to every link. He wants the picture next to each link to change weekly, and what I was thinking of was having a small directory of imgs, he will have 31 in total, and name them 1-31.png, and have something similar to this: var now = new Date(); var dd = now.getDate(); [code] if (dd==1) document.write('<img src="pic1.gif">') else if (dd==2) document.write('<img src="pic2.gif">') else if (dd==3) document.write('<img src="pic3.gif">') else if (dd==4) [code] but what I am looking for mostly is for the ability for it to loop back through, so that after the 31st week, it starts right back to the first. I have a banner ad with an image rotation embedded in a DIV. It works quite fine, but doesn't have required SEO info, ie: alt text. Here is the code that is working. Code: <div style="background-image: url(http://www.earthwindwater.com.au/banners/skiracersworld/banner-bg.png);height:148px;width:982px;border:0px;"> <div style="float:left;height:148px;border:0px;"> <a href="http://www.earthwindwater.com.au" target="_blank"><img border=0 align="absmiddle" alt="Earth Wind and Water Sports Action Cameras" src="http://www.earthwindwater.com.au/banners/skiracersworld/EWW-logo.png" /></a> </div> <div style="height:148px;border:0px;float:right;padding-right:415px; "> <a id="imageurl" target="_blank" ><img id="Rotating1" border="0"></img></a> <script language="JavaScript"> function RotateImages(Start) { var a = new Array("http://www.earthwindwater.com.au/banners/skiracersworld/Contour+.png","http://www.earthwindwater.com.au/banners/skiracersworld/LiquidImage.png","http://www.earthwindwater.com.au/banners/skiracersworld/ContourGPS.png", "http://www.earthwindwater.com.au/banners/skiracersworld/GoPro.png"); var c = new Array("http://www.earthwindwater.com.au/store/cameras/full-hd-cameras/contour", "http://www.earthwindwater.com.au/store/cameras/hd-cameras/impact-series-720p-mx-goggle-red", "http://www.earthwindwater.com.au/store/cameras/full-hd-cameras/contourgps", "http://www.earthwindwater.com.au/store/cameras/full-hd-cameras/gopro-hd-motorsports-hero"); var b = document.getElementById('Rotating1'); var d = document.getElementById('imageurl'); if(Start>=a.length) Start=0; b.src = a[Start]; d.href = c[Start]; window.setTimeout("RotateImages(" + (Start+1) + ")",5000); } RotateImages(0); </script> </div> </div> Now, I thought I would modify the code a little and include "Image Title" and "ALT Text" I am not much of a scripting genius, therefore my modifications don't work. Here is my modified code Code: <div style="background-image: url(http://www.earthwindwater.com.au/banners/skiracersworld/banner-bg.png);height:148px;width:982px;border:0px;"> <div style="float:left;height:148px;border:0px;"> <a href="http://www.earthwindwater.com.au" target="_blank"><img border=0 align="absmiddle" alt="Earth Wind and Water Sports Action Cameras" src="http://www.earthwindwater.com.au/banners/skiracersworld/EWW-logo.png" /></a> </div> <div style="height:148px;border:0px;float:right;padding-right:415px; "> <a id="imageurl" target="_blank" ><img id="Rotating1" id="imagealt" id="imagetitle" border="0"></img></a> <script language="JavaScript"> function RotateImages(Start) { var a = new Array("http://www.earthwindwater.com.au/banners/skiracersworld/Contour+.png","http://www.earthwindwater.com.au/banners/skiracersworld/LiquidImage.png","http://www.earthwindwater.com.au/banners/skiracersworld/ContourGPS.png", "http://www.earthwindwater.com.au/banners/skiracersworld/GoProHDHERO2.png"); var c = new Array("http://www.earthwindwater.com.au/store/cameras/full-hd-cameras/contour", "http://www.earthwindwater.com.au/store/cameras/full-hd-cameras/impact-series-hd-1080p-mx-video-goggle-white", "http://www.earthwindwater.com.au/store/cameras/full-hd-cameras/contourgps", "http://www.earthwindwater.com.au/store/cameras/full-hd-cameras/gopro-hd-hero2-motorsports-edition"); var e = new Array("Contour+", "Impact Series HD 1080p MX Video Goggle", "ContourGPS", "GoPro HD HERO2 Motorsport Edition"); var g = new Array("Contour+", "Impact Series HD 1080p MX Video Goggle", "ContourGPS", "GoPro HD HERO2 Motorsport Edition"); var b = document.getElementById('Rotating1'); var d = document.getElementById('imageurl'); var f = document.getElementById('imagealt'); var h = document.getElementById('imagetitle'); if(Start>=a.length) Start=0; b.src = a[Start]; d.href = c[Start]; f.alt = e[Start]; h.title = g[Start]; window.setTimeout("RotateImages(" + (Start+1) + ")",5000); } RotateImages(0); </script> </div> </div> Any ideas how I can get this to work Hi there, This forum was linked off of http://www.javascriptkit.com so I was hoping someone could lend me a hand. I like the image rotator script at http://www.javascriptkit.com/script/...tionshow.shtml as it is very easy to use. It currently pauses the image rotation on mouseover, but I would like to enable it to also pause onFocus and onBlur. My initial thoughts were to add a small "pause" form button under the image description that people could tab to with the keyboard, and perhaps capture the onBlur or onFocus event to initiate the pause. But the code is difficult to wrap my mind around. Any thoughts? Link to .js code: http://www.javascriptkit.com/script/...nsitionshow.js Hello! I've been fighting with a jQuery slider all day, and it's going nowhere because admittedly I have extremely limited jQuery knowledge. I am really hoping that someone here is better at this than I am and can tell me why I see a list of the items that should be in the slider stacked up on top of each other rather than seeing the actual slider. Here is the functions.php code. All CSS is in place, but I can copy/paste the stylesheet if necessary as well. If this isn't an appropriate forum for this, can you point me in the right direction? I don't even know which way is up anymore!!! Code: <?php /* HEADER SCRIPTS */ function headscript() { global $post; if (function_exists('is_products_page')){ if ( get_post_type() == 'wpsc-product' || is_products_page() ) return; } ?> <script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-3270175-9']); _gaq.push(['_trackPageview']); (function() { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); </script> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script> <script type="text/javascript"> $(document).ready(function() { //Default Action $(".tab_content").hide(); //Hide all content $("ul.tabs li:first").addClass("active").show(); //Activate first tab $(".tab_content:first").show(); //Show first tab content //On Click Event $("ul.tabs li").click(function() { $("ul.tabs li").removeClass("active"); //Remove any "active" class $(this).addClass("active"); //Add "active" class to selected tab $(".tab_content").hide(); //Hide all tab content var activeTab = $(this).find("a").attr("href"); //Find the rel attribute value to identify the active tab + content $(activeTab).fadeIn(); //Fade in the active content return false; }); }); </script> <script type="text/javascript" src="http://www.claritymind.com/js/easySlider1.7.js"></script> <script type="text/javascript"> $(document).ready(function(){ $("#slider2").easySlider({ auto: true, continuous: true, pause: 6000, speed: 800, nextId: "slider1next", prevId: "slider1prev" }); }); </script> <script type="text/javascript"> $(function () { $('a#testbutton').hover(function() { $(this).fadeTo("fast", 1); }, function() { $(this).fadeTo("fast", .85); }); }); </script> <script type="text/javascript"> $(document).ready(function(){ $("#slider1").easySlider({ numeric: true, auto: true, continuous: true, pause: 9000, speed: 700, }); }); </script> <?php } /* PAGE SPECIFIC CSS TWEAKS */ function home_head() { if (is_home() || is_front_page()) { ?> <style type="text/css"> .custom .headline_area {display:none;} </style> <style type="text/css"> .custom .servnav {display:none;} </style> <?php } } function nonhomepagecss(){ if (!is_home() && !is_front_page()) { ?> <style type="text/css"> .custom #sidebars{margin-top:15px;background:none;} body.custom {background-color:#f5f6f7;} .custom #content_area {background-color: #F5F6F7;} .custom .post_box{padding-top:30px;} .custom #content_box{ margin: 30px auto; width: 960px; border-radius: 5px; -moz-border-radius: 5px; -webkit-border-radius: 5px; background-color: white; box-shadow: 3px 3px 3px #CCC; -moz-box-shadow: 3px 3px 3px #CCC; -webkit-box-shadow: 3px 3px 3px #CCC; border-top: 1px solid #E8E8E8; border-left: 1px solid #E8E8E8; font-family: 'Lucida Grande', 'Lucida Grande Unicode', Helvetica, Verdana, sans-serif; padding-bottom: 30px; border-top-left-radius: 5px 5px; border-top-right-radius: 5px 5px; border-bottom-right-radius: 5px 5px; border-bottom-left-radius: 5px 5px; } </style> <?php } } function new_servicespage() { if (is_page('services') || is_page('30')) { ?> <style type="text/css"> .custom .topnav {display:none;} .custom .servnav {display:block;} </style> <div id="content"> <div class="post_box"> <div class="headline_area"> </div> Example text will go here. </div> </div> <div id="sidebars"><span class="newcallout1h4"> <table> <tr> <div style="vertical-align:top;"> <td width="275"><img src="http://cm.deviantwebdesign.com/wp-content/uploads/2012/03/VideoPlace.jpg" height="180" width="260"> </div> <td width="330"><div style="margin-left: 30px;"> <font color="#000000" font size="4">HEADLINE TEXT</font> <ul> <font color="#000000" font size="3"> <li>Bullet 1 - Example text goes here.</li> <li>Bullet 2. Ut enim ad minim veniam, quis nostrud exercitation.</li> <li>Bullet 3. Duis aute irure dolor in reprehenderit in voluptate velit esse.</li> </font> </ul> </div></td> <td width="275"><div style="margin-left: 30px;"> <script type="text/javascript" src="//moon-ray.com/v2.4/include/formEditor/genjs.php?html=true&uid=p2c6497f5&version=1"></script> </div></td> </tr> </table> </span> <?php thesis_build_sidebars(); ?> </div> <?php } } add_action('thesis_hook_custom_template', 'new_servicespage'); /* NAVIGATION MENU */ function navmenuarea(){ ?> <div class="topnav"> <div style="width:960px;margin-left:auto;margin-right:auto;"> <div style="float:left;"> <a href="http://claritymind.com/"><img alt="clrity-logo" src="http://www.claritymind.com/wp-content/uploads/2011/03/logosmall2.jpg" style="position:relative;left:0px;" /></a> </div> <div style="float:right;padding-top:11px;"> <ul id="navlist"> <li><a href="http://claritymind.com/services">Services</a></li> <li><a href="http://claritymind.com/next-step">Next Steps</a></li> <li><a href="http://claritymind.com/about">About</a></li> <li><a href="http://claritymind.com/free-articles">Free Stuff</a></li> <li><a href="http://claritymind.com/clients">Clients</a></li> <li><a href="http://claritymind.com/events">Events</a></li> <li><a style="color:#BCFC3D;" href="http://claritymind.com/products">Store</a></li> </ul> </div> </div> </div> <?php } /* FEATURED AREA */ function lowermenu(){ if (is_page()) { ?> <div class="clear"></div> <div style="width:100%;height:5px;"></div> <div class="pagecentered"> <div class="newcallout1"> </div> </div> <div style="width:100%;height:15px;"></div> <?php } } /* REGISTER SIDEBARS FOR CUSTOM SIDEBARS */ if (function_exists('register_sidebar')) { $sidebars = array(1,2, 3, 4, 5, 6, 7, 8, 9, 10); foreach($sidebars as $number) { register_sidebar(array( 'name' => 'Side ' . $number, 'id' => 'side-' . $number, 'before_widget' => '', 'after_widget' => '', 'before_title' => '<h3>', 'after_title' => '</h3>' )); } } function sidebartabs(){ if (function_exists('is_products_page')){ if ( get_post_type() == 'wpsc-product' || is_products_page() ) return; } ?> <div style="width:100%;height:25px;"></div> <div class="tabcontainer"> <ul class="tabs"> <li><a href="#tab1">Popular</a></li> <li><a href="#tab2">Latest</a></li> <li><a href="#tab3">Topics</a></li> <li><a href="#tab4">Links</a></li> </ul> <div class="tab_container"> <div id="tab1" class="tab_content" style="padding-right:0px;"> <a href="http://www.claritymind.com/next-step/" style="border:0;padding:0;margin:0;"><img src="http://www.claritymind.com/wp-content/uploads/2012/01/Master-Your-Mindset.png" alt="Change Your Mindset with Clarity Mind Coaching" style="border:0;padding:0;margin:0;" /></a> <div class="clear"></div> </div> <div id="tab2" class="tab_content"> <?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Side 6') ) : ?> <?php endif; ?> </div> <div id="tab3" class="tab_content"> <?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Side 7') ) : ?> <?php endif; ?> <div class="clear"></div> </div> <div id="tab4" class="tab_content"> <?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Side 8') ) : ?> <?php endif; ?> </div> </div> </div> <div class="clear"></div> <?php } add_action('thesis_hook_before_sidebars', 'sidebartabs'); function home_pagecustom() { if (is_home() || is_page(4217)) { ?> <div style="height:0px;width:0px;position:relative;left:294px;z-index:999;"> <div style="width:356px;height:1px;background:#efefef;"></div> <div style="width:356px;padding-top:2px;"><span class="nqheading">Featured from the Blog</span></div> </div> <div id="slider1"> <ul> <?php query_posts($query_string . '&cat=-3,-8&posts_per_page=5'); ?> <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?> <li> <div class="post"> <div style="width:279px;margin-right:15px;float:left;"> <?php $post_image = thesis_post_image_info('image'); echo $post_image['output']; ?> </div> <div style="width:356px;float:right;padding-top:20px;"> <div style=height:300px;overflow:hidden;"> <!-- Display the Title as a link to the Post's permalink. --> <h2><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <div class="entry"> <?php the_excerpt(); ?> </div> </div> <div style="width:356px;height:2px;"></div> <span class="readstory"><a href="<?php the_permalink() ?>" rel="bookmark" title="Continue Reading <?php the_title_attribute(); ?>">Continue Reading Post →</a> </div> <div class="clear"></div> </div> <!-- closes the first div box --> </li> <?php endwhile; else: ?> <p>Sorry, no posts matched your criteria.</p> <?php endif; ?> </ul> </div><!-- close slider1 --> <?php wp_reset_query(); ?> <div style="width:650px;margin-top:10px;"> <div class="one_third"> <div style="width:100%;height:1px;background:#efefef;"></div> <div style="width:100%;padding-top:2px;"><span class="nqheading">Lifestyle Design</span></div> <div style="width:199px;height:10px;"></div> <?php query_posts($query_string . '&cat=37&posts_per_page=3'); ?> <?php if (have_posts()) : ?> <?php $count = 0; ?> <?php while (have_posts()) : the_post(); ?> <?php $count++; ?> <?php if ($count <= 1) : ?> <?php $post_image = thesis_post_image_info('thumb');echo $post_image['output']; ?> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <span class="teaserexcerpt"><?php the_excerpt(); ?></span> <?php else : ?> <div style="width:199px;height:1px;border-top:1px dotted #cecece;margin-top:5px;"></div> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <?php endif; ?> <?php endwhile; ?> <?php else : ?> <?php endif; ?> <?php wp_reset_query(); ?> </div> <div class="one_third"> <div style="width:100%;height:1px;background:#efefef;"></div> <div style="width:100%;padding-top:2px;"><span class="nqheading">Love & Relationships</span></div> <div style="width:199px;height:10px;"></div> <?php query_posts($query_string . '&cat=39&posts_per_page=3'); ?> <?php if (have_posts()) : ?> <?php $count = 0; ?> <?php while (have_posts()) : the_post(); ?> <?php $count++; ?> <?php if ($count <= 1) : ?> <?php $post_image = thesis_post_image_info('thumb');echo $post_image['output']; ?> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <span class="teaserexcerpt"><?php the_excerpt(); ?></span> <?php else : ?> <div style="width:199px;height:1px;border-top:1px dotted #cecece;margin-top:5px;"></div> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <?php endif; ?> <?php endwhile; ?> <?php else : ?> <?php endif; ?> <?php wp_reset_query(); ?> </div> <div class="one_third last"> <div style="width:100%;height:1px;background:#efefef;"></div> <div style="width:100%;padding-top:2px;"><span class="nqheading">Personal Growth</span></div> <div style="width:199px;height:10px;"></div> <?php query_posts($query_string . '&cat=226&posts_per_page=3'); ?> <?php if (have_posts()) : ?> <?php $count = 0; ?> <?php while (have_posts()) : the_post(); ?> <?php $count++; ?> <?php if ($count <= 1) : ?> <?php $post_image = thesis_post_image_info('thumb');echo $post_image['output']; ?> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <span class="teaserexcerpt"><?php the_excerpt(); ?></span> <?php else : ?> <div style="width:199px;height:1px;border-top:1px dotted #cecece;margin-top:5px;"></div> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <?php endif; ?> <?php endwhile; ?> <?php else : ?> <?php endif; ?> <?php wp_reset_query(); ?> </div> <div class="clear"></div> </div> <div class="newcallout"> <h4 class="newcallouth4"><a href="http://www.claritymind.com/soul-affirmation-music-for-better-outcomes/">Browse Affirmation Music for Sale!</a></h4> </div> <div style="width:650px;margin-top:30px;"> <div class="one_third"> <div style="width:100%;height:1px;background:#efefef;"></div> <div style="width:100%;padding-top:2px;"><span class="nqheading">Awareness</span></div> <div style="width:199px;height:10px;"></div> <?php query_posts($query_string . '&cat=15&posts_per_page=3'); ?> <?php if (have_posts()) : ?> <?php $count = 0; ?> <?php while (have_posts()) : the_post(); ?> <?php $count++; ?> <?php if ($count <= 1) : ?> <?php $post_image = thesis_post_image_info('thumb');echo $post_image['output']; ?> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <span class="teaserexcerpt"><?php the_excerpt(); ?></span> <?php else : ?> <div style="width:199px;height:1px;border-top:1px dotted #cecece;margin-top:5px;"></div> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <?php endif; ?> <?php endwhile; ?> <?php else : ?> <?php endif; ?> <?php wp_reset_query(); ?> </div> <div class="one_third"> <div style="width:100%;height:1px;background:#efefef;"></div> <div style="width:100%;padding-top:2px;"><span class="nqheading">Meditation</span></div> <div style="width:199px;height:10px;"></div> <?php query_posts($query_string . '&cat=40&posts_per_page=3'); ?> <?php if (have_posts()) : ?> <?php $count = 0; ?> <?php while (have_posts()) : the_post(); ?> <?php $count++; ?> <?php if ($count <= 1) : ?> <?php $post_image = thesis_post_image_info('thumb');echo $post_image['output']; ?> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <span class="teaserexcerpt"><?php the_excerpt(); ?></span> <?php else : ?> <div style="width:199px;height:1px;border-top:1px dotted #cecece;margin-top:5px;"></div> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <?php endif; ?> <?php endwhile; ?> <?php else : ?> <?php endif; ?> <?php wp_reset_query(); ?> </div> <div class="one_third last"> <div style="width:100%;height:1px;background:#efefef;"></div> <div style="width:100%;padding-top:2px;"><span class="nqheading">Spirituality</span></div> <div style="width:199px;height:10px;"></div> <?php query_posts($query_string . '&cat=61&posts_per_page=3'); ?> <?php if (have_posts()) : ?> <?php $count = 0; ?> <?php while (have_posts()) : the_post(); ?> <?php $count++; ?> <?php if ($count <= 1) : ?> <?php $post_image = thesis_post_image_info('thumb');echo $post_image['output']; ?> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <span class="teaserexcerpt"><?php the_excerpt(); ?></span> <?php else : ?> <div style="width:199px;height:1px;border-top:1px dotted #cecece;margin-top:5px;"></div> <h2 class="teasertitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <?php endif; ?> <?php endwhile; ?> <?php else : ?> <?php endif; ?> <?php wp_reset_query(); ?> </div> <div class="clear"></div> <br /><br /><br /><br /> </div> <?php } } add_action('thesis_hook_before_content', 'home_pagecustom'); /* CUSTOM FOOTER */ function newfooter(){ ?> <div style="width:100%;height:80px;"></div> <div style="width:100%;background:#000000;" class="footernew1"> <div style="width:100%;height:0px;position:relative;top:-132px;z-index:-1;"> <div style="background:url(http://www.claritymind.com/wp-content/uploads/2011/03/mountainback2.jpg) bottom repeat-x;height:132px;width:100%;"></div> </div> <div class="pagecentered" style="padding-top:15px;"> <div class="one_third"> <img src="http://www.claritymind.com/wp-content/uploads/2011/03/certification1.jpg" alt="certification" /> <div style="width:100%;height:3px;border-bottom:1px dotted #444;"></div> <br /> <img src="http://www.claritymind.com/wp-content/uploads/2011/03/logosmall2.jpg" alt="Clarity Mind Logo" /><br /> 20 Ravenscroft Drive Asheville, NC 28801<br /> 404-NOW-MIND (404-669-6463)<br /> Skype: KenLad1 </div> <div class="one_third"> <?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Side 9') ) : ?> <?php endif; ?> </div> <div class="one_third last"> <?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('Side 10') ) : ?> <?php endif; ?> </div> <div class="clear"></div> <div style="height:20px;width:100%;"></div> <span style="font-size:10px;color:#fff;">Copyright © Clarity Mind, LLC. All Rights Reserved. Reproduction without permission prohibited.</span> </div> </div> <?php } function format_gridview_desc($description){ if (strlen($description) > 175) $description = substr ( $description , 0 , 175 )."..."; echo $description; } /* create new side bar for music player - this will only be displayed on the product page */ register_sidebar(array( 'name'=> 'Music Player', 'id' => 'music_player', 'before_widget' => '', 'after_widget' => '', 'before_title' => '<h3>', 'after_title' => '</h3>', )); Hi, i would like to explain my situation, basically, i am trying to create a slider with thumbnails. The slider is complete, works very well. The only problem is that the captions are just not appearing properly. I had a situation where the captions did work but they had to be coming in from the slideOut functions but what i want is for it to be displayed when the person hovers over the image. This is what it looks like at the moment... This is when the caption is coming from the top. i would like to implement Code: http://web.enavu.com/demos/caption/ or this Code: http://www.sohtanaka.com/web-design/examples/image-hover/ Doesnt matter which one into my slider when an image is hovered over (not the thumbnail) the actual image, then the caption covers the whole image displaying whatever text... Coding: (HTML) Code: <div class="main_view"> <div class="window"> <div class="image_reel"> <a href="#"> <img style="height:534px;" src="http://i55.tinypic.com/.png" alt="" /> </a> <a href="<?php echo get_permalink(253); ?>"> <img src="http://i51.tinypic.com/.jpg" alt="" /> </a> <a href="<?php echo get_permalink(256); ?>"> <img src="http://i52.tinypic.com/.png" alt="" /> </a> <a href="<?php echo get_permalink(258); ?>"> <img src="http://i53.tinypic.com/.png" alt="" /> </a> <a href="<?php echo get_permalink(271); ?>"> <img src="http://i53.tinypic.com/.png" alt="" /> </a> </div> <div class="descriptions"> <!--welcome page--> <div class="desc"> <strong style="font-size:30px;">Welcome to City Water</strong> <div class="clear"></div><br/> <div id="sliderdescription">WHATEVER WHATEVER</div> </div> <!--Services page--> <div class="desc"> <?php $post_id = 253; $queried_post = get_post($post_id); ?> <strong style="font-size:30px;"><?php echo $queried_post->post_title; ?></strong> <div class="clear"></div><br/> <div id="sliderdescription"><?php echo $queried_post->post_content; ?></div> </div> <div class="desc"> <!--Products page--> <?php $post_id = 256; $queried_post = get_post($post_id); ?> <strong style="font-size:30px;"><?php echo $queried_post->post_title; ?></strong><div class="clear"></div> <br/><div id="sliderdescription"><?php echo $queried_post->post_content; ?></div> </div> <div class="desc"> <!--Information page--> <?php $post_id = 258; $queried_post = get_post($post_id); ?> <strong style="font-size:30px;"><?php echo $queried_post->post_title; ?></strong><div class="clear"></div> <br/><div id="sliderdescription"><?php echo $queried_post->post_content; ?></div> </div> <div class="desc"> <!--Accounts page--> <?php $post_id = 271; $queried_post = get_post($post_id); ?> <strong style="font-size:30px;"><?php echo $queried_post->post_title; ?></strong><div class="clear"></div> <br/><div id="sliderdescription"><?php echo $queried_post->post_content; ?></div> </div> </div> </div> <div id="hrline"></div> <div class="paging"> <ul class="thumb"> <li><a href="#" rel="1"><img src="http://i55.tinypic.com/.png" class="thumbnails"/></a></li> <li><a href="#" rel="2"><img src="http://i56.tinypic.com/.jpg" class="thumbnails"/></a></li> <li><a href="#" rel="3"><img src="http://i51.tinypic.com/.png" class="thumbnails"/></a></li> <li><a href="#" rel="4"><img src="http://i52.tinypic.com/.png" class="thumbnails"/></a></li> <li><a href="#" rel="5"><img src="http://i52.tinypic.com/.png" class="thumbnails"/></a></li> </ul> </div> </div> CSS Code: /*--Main Container--*/ .main_view { float : left; height :488px; margin-bottom :1px; margin-top :-40px; position :relative; } /*--Window/Masking Styles--*/ .window img{ height :492px; width : 974px; } .window { /*--Hides anything outside of the set width/height--*/ border :3px solid #D7D7D5; color : #B4B4B4; font-size : 12px; font-weight : bold; height :488px; overflow : hidden; position : relative; width : 974px; } .image_reel { left : 0; position : absolute; top : 0; } .image_reel img { float : left; } .image_reel ul li { display : inline; } #image_reel .caption { background-color :#000; bottom :0; color :#ffffff; height :100px; position :absolute; width :100%; z-index :600; } #image_reel .caption .content { } #image_reel .caption .content h3 { color :#1DCCEF; margin :0; padding :0; } /*--Paging Styles--*/ .paging { /*--Assures the paging stays on the top layer--*/ /*--Hidden by default, will be later shown with jQuery--*/ bottom : -25px; display : none; line-height : 40px; position : absolute; right : -70px; text-align : center; z-index : 100; } .desc { display: none; position: absolute; top: 0; left: 0; z-index: 101; margin-top:275px; color: white; font-size: 2em; padding: 7px; } JAVASCRIPT Code: $(document).ready(function() { //Set Default State of each portfolio piece $(".paging").show(); $(".paging a:first").addClass("active"); //Get size of images, how many there are, then determin the size of the image reel. var imageWidth = $(".window").width(); var imageSum = $(".image_reel img").size(); var imageReelWidth = imageWidth * imageSum; //Adjust the image reel to its new size $(".image_reel").css({'width' : imageReelWidth}); //Paging + Slider Function rotate = function(){ var triggerID = $active.attr("rel") - 1; //Get number of times to slide var image_reelPosition = triggerID * imageWidth; //Determines the distance the image reel needs to slide hideComment(); $(".paging a").removeClass('active'); //Remove all active class $active.addClass('active'); //Add active class (the $active is declared in the rotateSwitch function) //Slider Animation $(".image_reel").animate({ left: -image_reelPosition }, 500 ); showComment(); }; //Rotation + Timing Event rotateSwitch = function(){ play = setInterval(function(){ //Set timer - this will repeat itself every 3 seconds $active = $('.paging a.active').next(); if ( $active.length === 0) { //If paging reaches the end... $active = $('.paging a:first'); //go back to first } rotate(); //Trigger the paging and slider function }, 7000); //Timer speed in milliseconds (3 seconds) }; rotateSwitch(); //Run function on launch //On Hover $(".image_reel a").hover(function() { clearInterval(play); //Stop the rotation play = null; }, function() { rotateSwitch(); //Resume rotation }); showComment = function(){ // slide toggle effect set to slow you can set it to fast too. $(".desc").eq( $('.paging a.active').attr("rel") - 1 ).show(700); return true; }; showComment(); // Show Comment initially hideComment = function(){ $(".desc").stop(true,true).slideUp(500).hide(); }; //hide comment if you click on it $(".desc").click(function(){ hideComment(); }); //On Click $(".paging a").click(function() { $active = $(this); //Activate the clicked paging //Reset Timer clearInterval(play); //Stop the rotation rotate(); //Trigger rotation immediately rotateSwitch(); // Resume rotation return false; //Prevent browser jump to link anchor }); }); Hello, My site has an image gallery with a row of pictures at the bottom. When I load up the page it should show image 1 in the main gallery window, but instead it's showing image in position #10 (the one to the left of #1). You can see what I'm talking about here. When you load the page it's showing the White House, but it should be showing the Green House (position #1 in slider). The White House can't be seen in the slider since it's in position #10, but shows up first int the main window. Is this a javascript issue or what? All JS files can be found here Can anybody help me debug this?? I'm going nuts Thank you Hey What do I need to do, for this to work both ways without all the bugs? http://kaspernordkvist.dk/slider/ Thanks I followed this tutorial to create a clickable image slideshow with javascript on a site's homepage. However, it appears that the javascript:slidelink() is still running beyond the intended area as some of my content below the container is now underlined as if it were a link, when it should not be. I can tell that the script is the issue because when hovering over the content it shows "javascript:slidelink()" but will not go to anything when clicked. Here is the code I'm using, which is placed in a Wordpress theme container: Code: <html> <head> <script type="text/javascript"> <!-- //preload images var image1=new Image() image1.src="image1.png" var image2=new Image() image2.src="image2.png" var image3=new Image() image3.src="image3.png" var image4=new Image() image4.src="image4.png" var image5=new Image() image5.src="image5.png" var image6=new Image() image6.src="image6.png" //--> </script> </head> <body> <a href="javascript:slidelink()"> <img src="image1.png" name="slide" width="100" /> <script type="text/javascript"> <!-- var step=1 var whichimage=1 function slideit(){ if (!document.images) return document.images.slide.src=eval("image"+step+".src") whichimage=step if (step<3) step++ else step=1 setTimeout("slideit()",1800) } slideit() function slidelink(){ if (whichimage==1) window.location="link1.htm" else if (whichimage==2) window.location="link2.htm" else if (whichimage==3) window.location="link3.htm" else if (whichimage==4) window.location="link4.htm" else if (whichimage==5) window.location="link5.htm" else if (whichimage==6) window.location="link6.htm" } //--> </script> </body> </html> Can anyone spot what might be causing the issue? Thanks in advance! Zoom Slider - A Javascript Slideshow I've been looking for some tutorials on how to make a zoom image slider like the one I posted as a link. Does anyone have any examples that I can use to help me. Thanks!
Hello, I'm trying to find an image slider and gallery script that will let me do this: http://www.7dma.com/clients/poncecol...er_gallery.jpg When clicked, the bottom product thumbnails change the large product image. Smaller, right-side thumbnails let you change different color versions of the large product image. Also, the text to the left and right will be updated in a CMS (I mention this just FYI). If you know how to accomplish this and what script(s) to use, I'll forever be in your debt. Thank you for taking the time to read this post. I have a drop down menu and an image slider that both use javascript code to function. The image slider appears right below the menu but when the actual menu drops down, the drop down part of the menu goes behind the image slider. How do I make it so that the menu drops above the image slider and not behind it? Hi, I ve recently come across the Advanced jQuery background image slideshow by Marco Folio. I have implemented it fine but when it goes to load an image I get a black screen for a second or two. I have about 15 images and reading around I found out that it has to do with the loading of images and that it would be better adding an image preloader to it. I have tried several pre loaders and have got the to work on their own, but not with this slider. This is the script.js Code: var slideshowSpeed = 6000; // Variable to store the images we need to set as background // which also includes some text and url's. var photos = [ { "title" : "", "image" : "1.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "2.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "3.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "4.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "5.jpg", "url" : "#", "firstline" : "", "secondline" : "" },{ "title" : "", "image" : "6.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "7.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "8.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "9.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "10.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "11.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "12.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "13.jpg", "url" : "#", "firstline" : "", "secondline" : "" }, { "title" : "", "image" : "14.jpg", "url" : "#", "firstline" : "", "secondline" : "" } ]; $(document).ready(function() { // Backwards navigation $("#back").click(function() { stopAnimation(); navigate("back"); }); // Forward navigation $("#next").click(function() { stopAnimation(); navigate("next"); }); var interval; $("#control").toggle(function(){ stopAnimation(); }, function() { // Change the background image to "pause" $(this).css({ "background-image" : "url(images/btn_pause.png)" }); // Show the next image navigate("next"); // Start playing the animation interval = setInterval(function() { navigate("next"); }, slideshowSpeed); }); var activeContainer = 1; var currentImg = 0; var animating = false; var navigate = function(direction) { // Check if no animation is running. If it is, prevent the action if(animating) { return; } // Check which current image we need to show if(direction == "next") { currentImg++; if(currentImg == photos.length + 1) { currentImg = 1; } } else { currentImg--; if(currentImg == 0) { currentImg = photos.length; } } // Check which container we need to use var currentContainer = activeContainer; if(activeContainer == 1) { activeContainer = 2; } else { activeContainer = 1; } showImage(photos[currentImg - 1], currentContainer, activeContainer); }; var currentZindex = -400; var showImage = function(photoObject, currentContainer, activeContainer) { animating = true; // Make sure the new container is always on the background currentZindex--; // Set the background image of the new active container $("#headerimg" + activeContainer).css({ "background-image" : "url(images/" + photoObject.image + ")", "display" : "block", "z-index" : currentZindex }); // Hide the header text $("#headertxt").css({"display" : "none"}); // Set the new header text $("#firstline").html(photoObject.firstline); $("#secondline") .attr("href", photoObject.url) .html(photoObject.secondline); $("#pictureduri") .attr("href", photoObject.url) .html(photoObject.title); // Fade out the current container // and display the header text when animation is complete $("#headerimg" + currentContainer).fadeOut(function() { setTimeout(function() { $("#headertxt").css({"display" : "block"}); animating = false; }, 500); }); }; var stopAnimation = function() { // Change the background image to "play" $("#control").css({ "background-image" : "url(images/btn_play.png)" }); // Clear the interval clearInterval(interval); }; // We should statically set the first image navigate("next"); // Start playing the animation interval = setInterval(function() { navigate("next"); }, slideshowSpeed); }); and this is the part of the html where it is added: Code: <div id="header_top"> <div id="headerimgs"> <div id="headerimg1" class="headerimg"></div> <div id="headerimg2" class="headerimg"></div> </div> </div> I would like to load 2 images on page load and then while it is displaying the 2 images to download to the browser cache the rest. Could you point me in the right direction. Thanks I am using a JQuery Slider function in one of my forms that has the folowing code: Code: <script> $(function() { $( "#slider" ).slider({ value:100, min: 0, max: 100, step: 1, slide: function( event, ui ) { $( "#amount" ).val( ui.value + "% Clear" ); } }); $( "#amount" ).val( $( "#slider" ).slider( "value" ) + "% Clear" ); }); </script> And the form looks like: Code: <form method=POST etc...> <div id="slider"></div> <span><input type="text" id="amount" name="Percentage" style="border:0; color:#f6931f; font-weight:bold;" /></span> </form> Now, in the php, I have an error system set up, so that if one of the items in the form are left blank etc., an error will generate without posting the form. However, I am using <?php echo ?> in the form to repopulate the fields that were entered, so user does not have to fill them again. However, the slider always resets back to 100%... How can I fix this so that if the form does not POST, the slider will keep the value that the user set it at. Is this possible, I am having trouble figuring it out. Thanks! I'm working on a website. Basic layout is up at http://adamnerland.com/onestudent/ The layout looks perfect and the image slider I'm using works in every browser I've tested except for IE 7.0 and earlier. I'm not a JavaScript programmer, so I'm not really sure how to debug this. Is it due to conflicts with my dropdown menu JavaScript? Anyone have any ideas? Something similar to the navigation menu on http://www.gamewearteamsports.com/. You hover over a link and a box appears below that spreads the width of the menu itself. Friend of mine told me it was using actionscript but I have no idea how to create a drop down box (not menu). Any ideas? My friend told me Dreamweaver has the ability t create a drop down box but I have no idea. Also does anyone know how to create an image slider similar to the one on that site? A slider that fades from one image to the next with the navigation arrows on the left and right side and the dots on top left? I have used an excellent template which uses JS to display background images. However while this works locally it doesn't when published. The site structure is sound and I notice this happens with the source files I downloaded also so it's nothing I have done in my build which could have caused this. This is the link to my site, everything is fine except the background image not showing. http://www.khawkinsdesign.com Any ideas, as I say fine locally, not fine when published? HI friends., i am having a problem with using image slider script and pretty photo in one page. i have hosting website at two diffrent places. it is working fine here...http://codersonline.co.cc/sgreens-de...hp?option=unit but giving problem at http://www.savitrygreens.com/DeMo/index.php?option=unit really frustrated... don't know how to use noconflict method please help.. |