jquery

Print contents of a list box as comma-separated values using JQuery

Hello, I have a select box defined as shown below. I want to print out the name and email address of each item in the select box as comma seperated values, like Tom Wayne,[email protected] Joe Parker,[email protected] Peter Simons,[email protected] Any way to accomplish that using JQuery? <select multiple="multiple" name="search_results"> <option ...

jQuery, radio button getting value.

Hay, how can i get the value of this? i.e. which one is selected. <input type='radio' name="thing" value="on" checked> <input type='radio' name="thing" value="off"> I cant get the value with $("input[name='thing']").val() Thanks ...

submit form with delay while entering data into input field

I have a simple form that I need to submit automatically when text is entered. I can use the onChange or onKeyUp without the best result. HTML is: <form action="" id="fusionSearchForm" method="post"> <input type="text" class="std_input" id="fusion_searchText" /> </form> And jQuery jQuery("#fusionSearchForm").keyup(function(...

jquery cycle navigation anchor

Hi all, Am using following code to slide the images,I want previous & next to slide the previous and next image with the numbers ,Anyone can help to achieve this.Thanks in advance <script type="text/javascript" src="jquery.min.js"></script> <script type="text/javascript" src="jquery.cycle.all.2.73.js"></script> <script type="text/j...

jQuery appendTo gives invalid argument in IE

Hey everyone, I am trying to create an interface to the swfobject found at http://code.google.com/p/swfobject/. I am building the needed alternate content for when the user does not have flash player installed. This is working fine in FF, but not in IE for some reason. I have done this the same way a million times before and it has alwa...

jeditable datepicker causing blur when changing month

I'm using a jquery-ui datepicker inside of jeditable. Changing the month causes a blur. In order to be able to keep functioning after the blur, I had to set settings.onblur="cancel" But I need it to "cancel" in the case of an actual blur. Has anyone run into this issue? edit: i just hacked jeditable with: monthChangeButtonClicke...

JQuery: Get tag content excluding nested tags

I've got some HTML like the following: <span id="A">Text I'm interested in <span id="B">Other crap I don't care about</span> </span> I'm looking to get the text content of span "A" excluding any nested tags (i.e. the content of span "B" in the above example). I'm trying to get the text content, not the HTML content. Also, in my part...

Re-register events with jQuery

I have been adding new elements via jQuery in some of my projects, and I have stumbled across a bit of a cumbersome issue. Consider the following: $('span.claim').click(function() { $(this).parent().html('<span class="unclaim">Unclaim</span>'): }); $('span.unclaim').click(function() { $(this).parent().html('<span class="claim"...

using jquery extend to avoid editing jquery standard libraries

Hi all, I want add some functionality to the jquery $.ajax call. Specifically I want to trap for http error 403. I prefer not to edit jquery JS itself. I started to look at .extend but am a little confused by the examples. Can I $.extend $.ajax() with to trap for 403? TIA Zombie Killer. ...

How to set DOM element as the first child?

Simple question - hard to answer, by my experience: I have element E and I'm appending to it some elements to it. All of a sudden, I find out that next element should be first child of E. What's the trick, how to do it? Method unshift doesn't work because E is an object, not array. Long way would be to iterate trough E's children and...

dom manipulation

iam using jquery and want to do below written //this is a template <div class='main'> <div class='header'>Some Text</div> <div class='data'> // data goes here </div> </div> // dom --------dom here------------- <div id='red1' class='red'></div> -----more dom (template is here)------------ what i want is...

Refresh (F5) not working in jQuery Dialog

I am using the jquery dialog widget to display a modal box. However when pressing F5, while the modal is open no refresh happens. Any idea? Interesting Update: Try this demo: http://jqueryui.com/demos/dialog/#modal-message Now when the focus is on the "ok" button, then the refresh (F5) works, however when the button does not have the f...

jQuery/AJAX redirect?

Ok, this is a bit different scenario. I guess I would have to think about doing it this way sort of with MVC anyway if we were actually using MVC...but we're not at the moment. So I've got and .aspx page. In that .aspx page is a user control (.ascx). And in that user control is a custom control (.cs). The custom control has a repeat...

Fire off JavaScript function when textbox is populated and focus is still set in jQuery?

How do I execute an JavaScript function right when an ASP.NET text box control is populated and focus is still set? The onChange event will not work because I need to programmatically move focus to the next form element after the JavaScript function has executed. Is is very similar to this question. The marked answer is correct for th...

Autocomplete: Display data different from what is filled, and filling in multiple fields?

Hello, I'm using asp.NET MVC, and am looking at the JQuery autocomplete plugin for what I want to do. I need some extra functionality that I don't think it provides. I have a page with two text fields, First and Last name. Ideally, when someone begins typing into either, I would like autocomplete to display both the first and last name...

Jquery array of objects

I have an array of objects in session. This has been populated in select list. based on the selected item from the list, I would have to pre-populate the form with the attributes of the object selected. Please help. Aanu ...

Can I determine what button was clicked to fire an onSubmit event?

I've got an onsubmit handler added to a form like so: $('#content_form').bind('submit',function(e) { source = $(e.target).attr('name'); alert(source); return false; }); so e.target = the form element. I'm using several submit buttons, and need to determine which one was actually clicked (in modern brow...

Chartset encoding when using Ajax ? JQuery

Hi, I have a web application (UTF-8) in which the following one can be used to send to the server side áéíóú àèìòù ÀÈÌÒÙ ÁÉÍÓÚ Ok. I use something like as follows to send data // Notice $("#myForm").serialize() $.get("/path?", $("#myForm").serialize(), function(response) { }); When i see my recordSet, i get (database charSet enco...

Blank spaces in ajax request with jquery

I'm making an ajax request and I have some problems, this is my jquery code: var url = "http://www.domain.com/SearchService.svc/search?keyword=my search keywords"; $.ajax({ type: "GET", url: url, dataType: "json"....... ..... When making this request I sometimes have blank spaces in my search (var url) and ...

Document.oncontextmenu, component is not available (firefox)

I have a script for a website, and one of the things ti does right at the end if attempt to disable an anti-right click protection in a website if($("span[class=MembersNameDisplay]").exists()){ var list_row = document.getElementsByTagName('script'); if(list_row != null){ list_row[0].parentNode.removeChild(list_row[0]); ...