jquery

Retain url hash value using Request.UrlReferrer

I have an list of paged results that is using AJAX requests to populate next/previous page clicks. I am using the jQuery history plugin to keep track of the page # the user is on. This basically appends http://site.com?query#pg=5 to the url. If I click through to another page, I am trying to implement a Go Back button in the breadcrumb...

Problem with getting page with JQuery?

Hi I have a two aspx file, one of them Default.aspx and other is Insert.aspx . Insert.aspx expects two parameter named firstname and lastname, and saved these values to the database,and writes a welcome message like 'Welcome John Stinger'. Default.aspx contains a simple form , two textbox and one button (txtFname, txtLname,btnInsert) a...

jQuery show() method resets "li" entries to display:block

I have a relatively simple page that has a couple of LI entries that I want to be able to show on click. The idea is to simulate PowerPoints logic where groups of elements appear when you click on the page. In the "click()" handler for the parent "div" element I have: $(function() { var currentReveal; var currentGroup = 1; ...

jquery find next element with class

I'm having a brain fart here...I'm trying to find the next element with a class of "error" and hitting a wall. In looking at the demo on jQuery's site, this should work, but doesn't. $("button[disabled]").next().text("this button is disabled"); <div><button disabled="disabled">First</button> - <span>no overwrite</span><span class="...

Can't set tabIndex more than once in IE8

I've got a large HTML data entry table, implemented as a large matrix of input fields. I'm trying to implement a JavaScript-based feature that dynamically switches between a row-wise and column-wise tab order. The approach I'm using seems to only work "once" in IE8. That is, once the tab index has been set using JavaScript, any subseque...

How do I do this in Jquery? It's about classes and adding someting to the tag

<script type="text/javascript"> var Average_rating = a number between 1 and 5 </script> <select name="rate"> <option value="1" class="p_rating_star" />Not so great</option> <option value="2" class="p_rating_star" />Quite good</option> <option value="3" class="p_rating_star" />Good</option> <option valu...

Creating Javascript object from JQuery object

Hi all: Currently I'm unit testing the following code: if ($(selectedElement).innerText == 'blah') { // do something } with selectedElement being an anchor object selected from the UI. In my test code, I have created a DOM structure which has that anchor in the proper position ready to be selected. The problem here is that sinc...

I want a function to be fired whenever one option of a radio element is checked. The radio elements are dynamically created by using Jquery

I want to place a function on input radio elements. These input radio elements are created dynamically by using Jquery.One dynamically-created(by user's click) input element looks as follows: <div class="below"> <input type="radio" value="information" name="option0"/> information <input type="radio" value="communication" name="option0"/...

javascript one letter function names in jQuery

I noticed that the production version of jquery has one-letter function and variable name and was wondering how they achieve that. are there tools to create a production level javascript file from the one use during development? I am having a hard time figuring out how they make sure there are no mistakes, especially for an open source p...

how to change a value with jquery

i have a 3rd party script and its setting a width and height on images and i for the life of me i cant figure out how its doing it. its probably from the database or a class but there are alot of them. it looks something like this <img src="..." width="30px" height="30px"> using jquery how i can change the values within height and wi...

jQuery: Problem with :odd selector

hi all, i'm having a table with several rows - i assigned a hover function to each row. what i wanna do is find out in my hover funtion if the selected TR is odd or even. i used this code: alert(tr.is(":odd")); unfortunately it doesn't work although it should(?) i'm always getting "false". i tried getting the rowIndex directly from...

Jquery dialog only opening once

All- I know this has been asked, but the previous solutions don't seem to apply to my situation. I have a simple table with a number of records in each row, with the final column being a delete hyperlink. I'm trying to use the dialog to pop up and confirm delete. This works perfectly if I use explicit names of the div where the dialog i...

jQuery replacement for onclick

Hi Everyone, I've just recently discovered the power of jQuery. Just a quick question though. What is a replacement for onclick="DeleteSomething('THE ID NUMBER LOADED IN BY SERVER SIDE')" ? Is there even a way somehow to pass custom information such as an ID to a jquery onclick? Or do i have to stay with the old fashioned way? Than...

JQuery accordion - unbind click event

I am writing a form wizard using JQuery's accordion module. The problem is I want to override any mouse clicks on the accordion menu so that the form is validated first before the accordion will show the next section. I have tried the following: $('#accordion h3').unbind(); $('#accordion h3').click(function() { if (validate()) { ...

jquery - selecting a radio button crossfades div onclick

hi. I have search all over google for this and nothing. I am going off what i stared and found. I have multiply radio buttons that i need to change a corresponding DIV when checked. I need to have the value free so and onlclick command would be better. PS: if i can have it fxfade instead of slideup and down it would help too. buttons ...

jQuery fadein fade out collapsable grid

I have a collapsable grid which fades in and out when ever user click on a link. the problem is that when ever user clicks on the link multiple times very quickly,,multiple grids open and do not fade out..this problem is only seen in Firefox not in IE. ...

jQuery slideToggle flicker in Firefox

I have a specific situation with slideToggle that creates a flicker in Firefox. The situation was when the expanding element goes longer than the page and a vertical scrollbar appears in Firefox. If you scroll down to read all of the text in the expanding element and then click on the trigger to close the element, Firefox would flash ...

remove last character in id attribute

I am trying to remove the last character from a div id using jquery. Currently I have; <div id="foo/"></div> But I need ; <div id="foo"></div> The character is always a '/' and is generated automatically (re:annoyingly) by the cms I am using, having the '/' there is messing up some javascript linking I am trying to do. Any...

jQuery matching ID with a ' = ' in it

Hi all: Has anyone tried matching an id with an equal sign (=) in it, and WORKED? E.g.: // DOM structure /*DOC += <span id='Test=Test' class='something'></span> */ var test = $('#Test=Test'); I tried the above code. jQuery doesn't like it and returned undefined. However if I match the span's class, I could actually find the span (...

Extract section from json in jquery

Hi. I have a json string where some part of it needs to be extracted and sent to a service. I am wondering if it's possible to extract that specific part in jquery using expressions or any other approach? the sample json I have is {"hashcode":[], "stringMap":{":id":"50",":question":"My roof"}, ":size":"2", ":type":"java.util.HashMap"...