jquery

show spinner only after 50ms

I have a page where a lot of ajax action is taking place. I show a spinner to indicate the request is being processed. Some of those requests long time and some of them are quick. When the response comes quickly then those spinners are more of a nuisance than an aid. This is what I wanted. Display the spinner only if it has been more t...

jQuery load giving me more than I need

I am sending the following variable to the jQiery load method, expecting only the hashtagged div in return, instead I am getting the whole site url: http://localhost/createstudios/videos/?vimeo=15741581#sidebar function: function mf_ajax_load_new_content(url, div){ //$('#ajax_loader').clone().prependTo('#main-content-a...

why is my button losing focus?

This is what I want to happen.. When a user hits 'enter' a 'SearchForItems()' should trigger. What is happening is another control, with 'other button', on the page gets focus returned to it anytime any other element is tabbed out of or after onkeyup. I am having to force focus on the 'Search button' on page load, but after that any ti...

how can i load <script>'s into an iframe?

I've got the logic working to append into my iframe from the parent this works: $('#iframe').load(function() { $(this).contents().find('#target').append('this text has been inserted into the iframe by jquery'); }); this doesn't $('#iframe').load(function() { $(this).contents().find('body').append('<script type="text/javascri...

MOVs break Colorbox in Chrome - how to fix?

http://bit.ly/cwF2cs user: temp pass: jumms887 Click on the thumbnail at upper right right above "Gotti Split Verdict." A MOV files is linked up to that and it breaks Colorbox in Chrome. It works in Firefox and Safari. When I replace it with a PNG or even a link to YouTube, it works. Any idea why MOVs break Colorbox in Chrome? ...

Jquery Image slider with sliding button backgrounds - close but no cigar

Hey folks, new to stackoverflow. I was pounding my brain yesterday regarding an image slider I am working on. Still learning jquery and cant quite figure out what I am missing or where to add the functionality i want: http://www.stuartthom.com/slider/Slider.html What I would like to be able to do is have each of the thumbnails be a di...

Ajax, response body is empty

Hi all!!! I try to get data from server http://someserver12345.com If i download it for example with C# DownloadString or open it in browser it returns body with data and from FireBug's log Content-Length is equal to data's size. So all results are ok; For example response data can be json documents and by opening in browser each time s...

jQuery: Add ui-close button to resizable/draggable ?

How can I add a close button to a draggable/resizable div? I understand that I am essentially describing a dialog, but I have to be able to take advantage of a few of the properties of resizable/draggable (such as containment) that are not a part of dialog. Any ideas? ...

jqGrid - supply no data message in the grid?

If there was no data returned from our search currently we use the loadComplete callback to print out a message to the user to indicate that there is no data. Is there a way to configure jqGrid to print out a "no data" message within the grid? Currently we print it out in a div above the grid but would like it to be within the actual gr...

PHP/jQuery populate content of squares randomly

Here is the scenario I am having problems with: I have a Wordpress page with 25 squares(divs!) on the page. I want to randomly populate the squares with: - either a thumbnail from a random post - or a background shade of red ( this shade of red may vary) Constraints: - I have the PHP code to populate the squares with a random posts t...

Does jquery property .css( propertyName ) not breaking the rule of separation of concerns?

Does .css( propertyName ) not breaking the rule of separation of concerns? As a rule of separation of concern , we keep content, style and behaviour in different layer. but when we add styles using behaviour (http://api.jquery.com/css/), does it not breaking the rules of concern. ...

How to make a "hybrid" HTML drop-down list that can work as a text box as well?

For my website, I need to have a way for users to enter their cities. I'd like to use 2 drop-down list for that: a "State" and a "City" drop-down lists. The choices in the "City" list would depend on what "State' has been selected. However, there bound to be cases where a user's "City" is not in the drop-down list. To handle those case...

jQuery - Trouble With Index Numbering Tag Elements

I'm building a jQuery plugin that works with multiple unordered lists. I want to be able to give each li tag in each list an index-numbered class name, starting over with 1 in each list, like so: <ul class="ui-tabs-panel"> <li class="col-1">column 1</li> <li class="col-2">column 2</li> <li class="col-3">column 3</li> </ul> <...

jquery selector issue

I have a div which in jquery's document ready I append - using $("#div id").append('html text') syntax - with 10 or so more div child elements. once this is done I try to check the content of the child divs via alert($(".classname")); and it comes back with: function(a){if(c.isFunction(a))return this.each(function(b){var d=c(this);d.te...

PHP Include() whole subdirectory with jQuery navigation bar

Hi, I have a subdirectory folder called /lefnav It contains this files: background.jpg demo.html heading_bg.jpg jquery.js navigation.jpg sliding_effect.js styles.css tab_bg.jpg Thumbs.db Thumbs.db/encryptable It actually contains al the elements of this tutorial: http://net.tutsplus.com/tutorials/javascript-ajax/how-to-create-a-moo...

Document.ready function causing a form to submit 10 times

I'm using jQuery Stars Rating plugin ( http://www.fyneworks.com/jquery/star-rating/ ). I'm having difficulty displaying an existing rating using the plugin's API. Everything works unless there is an existing rating in the database. If there is one, the following block of code will execute, and a 10 new ratings (that's as many inputs I ...

jQuery UI dialog box - positioning

This may be due to my ignorance but when using jQuery UI dialog boxes, how do I ensure that the dialog box moves in relation to the way the browser gets scrolled horizontally and vertically. We have an application that has a lot of horizontal text boxes on it and to see them all, a user would have to scroll horizontally. If no scrollin...

EXTRACTING data from a particular url and populating a dictionary in iPhone

Hi everyone, I am a newbie to iPhone app development. I would like to know the procedure to extract data from a particular website which itself populates the webpage's content using a jquery. I would like to extract this data and display it in my own format. Here is the url: source webpage Kindly let me know if there exists any fram...

I want that when the mouse is over one option in my dropdownlist, the background color of the option value on my second mask must be changed

I have 2 dialog mask on my window. On the fist one I have a drop-down list with different option values. On the second I have a div table. I want that when the mouse is over one option in my drop-down list, the background color of the option value on my second mask must be changed and when I leave the background color be restored to ...

jQuery "Cannot read property 'defaultView' of undefined" error

I am using jQuery to post a form field to a PHP file that simply returns 1/0 depending on whether it worked or not... Extract of the code: $.ajax({ url: "ajax/save_text.php", //Relative?!? //PHP Script type: "POST", //Use post data: 'test=' + $(this).val(), datatype: 'text', //Pass value cache: fa...