jquery

Get image slider to auto play

Hi. I am trying to get my own image slider to auto play with an interval of 4000 milliseconds. I've tried using setTimeOut but I cannot seem to get it to work. I would appreciate it if someone could help me out. Here is example of the slider: http://www.matthewruddy.com/slider-intervalissue/ Any ideas how I can get it to auto play? He...

jQuery namespace does not bubble which custom event

HTML: <div class="parent"> <div class="child1" > </div> <div class="child2"> </div> </div> <a class="btn1">customClick.btn1</a> <a class="btn2">customClick.btn2</a> JavaScript: jQuery('div.child1') .bind('customClick.btn1', function () { alert('child1 reacted to customClick.btn1'); }); jQuery('div...

jQuery ordering list items up and down not with drag and drop

Hi, I want a user to be able to reorder a list on a click event. I have set up a very basic jsFiddle here: http://jsfiddle.net/8vWXZ/2/ So in this example i would like to move the clicked li item and its contents to the position above in the DOM. I suppose strictly speaking it is being moved down in the index of li items. This is g...

jquery child selector without parent

I was looking at some code from a tutorial for creating a carousel menu and noticed parent child selectors without the parent. Never seen this before, and confused to what it is actually doing. See following code: var $wrapper = $('> div', this).css('overflow', 'hidden'), $slider = $wrapper.find('> ul'), $items...

jQuery Tooltip only works for first row of table

The jQuery tooltip works great for the first row of data in my table. After that, I only get the old school windows default tooltip in both IE and FF. Here is the HTML that builds table data: foreach ($displayData as $row) { echo '<tr bgcolor="' . $bgcolor[$a] . '">'; echo '<td><span id="fancy" title="Course Description: - '.$row[...

On mouseover change auto to false

I have this code and i want the mouseover to change the variable auto from true to false. if ($featuredArea.length) { $featuredArea.et_switcher({ useArrows: true <?php if (get_option($shortname.'_slider_auto') == 'on') { ?>, auto: true, autoSpeed: <?php echo(get_option($shortname.'_slider_autospeed')); ?>...

How to dynamically filter content using checkboxes? - jQuery

Hey all, I am trying to dynamically filter out content using checkboxes and jquery. Being new to jquery, I'm not sure on how to do this properly, so if any can help that would be great. I have got this code: <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.1/jquery.min.js"&gt;&lt;/script&gt; <script...

Using jQuery UI Tabs. How would I make one of the tabs link to a URL rather than load a tab panel?

I am using jQuery UI tabs to create a vertical tab section of a page, and want the last vertical tab to link out to a URL rather than load a tab panel. Any suggestions for the best way to do this? I can stick another element besides an LI into the list, but would rather have the last li just behave differently. Thanks for any help. ...

Changing project requirements - should client pay

Not sure where to put this but a site filled with working programmers is a good bet. I built a website for a client, that included (on the home page) a fancy jQuery image slider with controls. This was specified in the original project scope. I also implemented a simple jQuery slider on one of the inner pages. Now that the site is up f...

Best way to achieve jQuery scroll effect

I am having problems implementing the following jQuery effect to my navigation. There will be the following image on the top of the screen: When the user clicks on this, the following menu should scroll out: my HTML is as follows: <div class="left_corner"><img src="images/homepage_menu_lft.gif" alt="corner" /></div> <div class="...

jQuery, SVG: How to animate an attribute value (not style property)?

Hi, I need to animate an attribute of an SVG element, which has no CSS counterpart - <circle cx="..." /> How can I achieve that? Or, I can use an alternative, e.g. if I could animate <g/> using CSS's top or similar. Any experience? Thanks, Ondra Note this is not a duplicate of http://stackoverflow.com/questions/911357/how-can-i-anim...

Pass parameter from view to controller via jquery in MVC 2

I need to pass a url string from the view to the controller, a url that is retrieved via jquery. I tried just using the id parameter in the default routing, but that didn't work. It didn't accept a url string. Calling the Controller through jquery works fine, like this: $('#result').load('Home/Files/' + url); This calls the correct a...

How do I create a RedCloth live preview using jQuery?

I've had problems with many of the WYSIWYG gems/plugins for Rails, so I'm building one myself using the RedCloth gem. I want users to see a live preview of their HTML-formatted text as they're filling out a form, but don't know how to do that using jQuery and RedCloth. Here's what I tried in application.js: $('#comment').keyup(function(...

Flot mousehover algorithm to detect purely based on x location?

Using jQuery's flot, there's a way to allow items to be selected by hovering over them. In the options, grid[mouseActiveRadius] may be set to a number to indicate the desired length of the radius of the selection circle. For instance, if you set it to 10, then any mouse hover event will highlight the closest point in a 10 pixel radius c...

jQuery adding multiple text boxes

Hi all, I wonder if anyone could help me. I have a web page where there are some text boxes (dynamic amount, could be 3, could be 30) and each one a user can enter a number and I have a total count at the bottom. At present I have this: $('input.qty').change(function() { // Get the current total value var total = $('#total'); // Upda...

Display result of POST or GET to external site within JQuery dialog

Hi, I'm trying to POST to an external website, and display the results in a JQuery UI Dialog on my site. Is that possible? I've tried a bunch of permutations, for example (with GET): $("#view").click(function() { var url = this.href; var dialog_pop = $('<div></div>'); dialog_pop.load(url).dialog(); return false; }); This seems to work...

Learning JQuery: noob question about button click

I am learning jquery and I am having difficulty to run the following extremely simple code. My HTML looks like: <html> <head> <title>JQUERY</title> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.0/jquery.min.js"&gt;&lt;/script&gt; <script type="text/javascript" src="script.js"></script>...

Convert five lines of Mootools to jQuery

Can someone please help me out with this? I'm using jquery-1.4.2. http://jsfiddle.net/Ymkpb/ Thank you so much! Edit - Adding the original so this is more useful later: $$('.clickables').each(function(clickable) { var list = clickable.getElements('li'); list.addEvent('click', function() { var link = this.getElement('...

"javascript:void(0);" vs "return false" vs "preventDefault()"

Hi guys, When I want some link to not do anything but only respond to javascript actions what's the best way to avoid the link scrolling to the top edge of the page ? I know several ways of doing it, they all seem to work fine : <a href="javascript:void(0)">Hello</a> or <a id="hello" href="#">Hello</a> <script type="text/javascript>...

Find out how long an Ajax request took to complete

What is a good way to find out how long a particular $.ajax() request took? I would like to get this information and then display it on the page somewhere. ANSWER??:::: I'm new to javascript, this is the best that I could come up with if you don't want to inline the "success" function (because it will be a much bigger function) Is ...