Jquery in IE, fully messed up
After a long debugging, I found that the class .nivoSlider was not having a definite height, so I gave a height height:288px !important; and woila, it worked,
After a long debugging, I found that the class .nivoSlider was not having a definite height, so I gave a height height:288px !important; and woila, it worked,
I use the jQuery cycle on the home page of http://getwellgabby.org/. You can inspect the elements to see what’s going on with CSS here. For the PHP, I wrote a custom home page template as part of a child theme based on TwentyTen. There are two loops in the page: One that gets the static … Read more
I figured it out!! I added this piece of jQuery: <script type=”text/javascript”> <!– $(function() { jQuery(“.photos a”).hover(function() { var offset = $(this).offset(); var id_post = $(this).attr(“id”); jQuery(“.hover”).find(“span[id=”+id_post+”]”).css(“left”, (offset.left-312)+”px”); jQuery(“.hover”).find(“span[id=”+id_post+”]”).show(); }, function() { jQuery(“.hover”).find(“span”).hide(); }) }); //–> </script> and added an additional loop: <div class=”hover”> <?php query_posts( ‘category_name=photos&posts_per_page=-1’ ); ?> <?php if ( have_posts() ) : … Read more
You want get_posts not query_posts. Only use the latter if you need to modify the main query. Something like this (in whatever template file you want): <ul class=”slider”> <?php global $post; $args = array( ‘numberposts’ => 5, ‘order’=> ‘ASC’, ‘orderby’ => ‘title’ ); $myposts = get_posts( $args ); foreach( $myposts as $post ) : setup_postdata($post); … Read more
I had to load WordPress in order to use the wpdb function. How silly :p. To do so: $parse_uri = explode( ‘wp-content’, $_SERVER[‘SCRIPT_FILENAME’] ); require_once( $parse_uri[0] . ‘wp-load.php’ ); And then finally: global $wpdb;
Your main issue is that you’re loop logic is incorrect You’re doing: Foreach post iterate over each box type and print out the current post as that box So if you define 5 boxes, then for post 1 you’ll have 5 copies of that post, then another 5 for post 2, then another 5 for … Read more
I spotted out the answer for this. Here is the culprit the culprit: the jquery.animate-enhanced.js file that had been added since version 3.1.2 is creating the issue. Comment out this line : wp_register_script(‘jquery_animate_enhanced’, content_url().’/plugins/wp-supersized/js/jquery.animate-enhanced.min.js’,array(‘jquery’),self::supersized_jquery_animate_enhanced_version) probably on line 55 in this file: wp-content/plugins/wp-supersized/includes/WPSupersized.php This is working for me now.
Use $(“.sidebar li.parent-item”).hover(function () { $(this).find(“ul.children”).slideToggle(“slow”); });
I added the Javascript file with the following code. So if anyone is looking for this solution should use the below code in functions. I don’t know who was so jobless to vote this question down but I am trying to fix my mistake of posting question here on stackexchange by answering my own question. … Read more
See this question for an answer. You can do also var $ = jQuery.noConflict() before your script.