jquery

How to get the text before $el with jQuery?

<cite> text here... <a id="target_element"></a> </cite> How to get the text before #target_element? ...

copy textfield value from one tabs to another tabs

hi all..i'm using jquery tabs.. i'm use tabs-1 as input form and tabs-2 as show input data... i want after submit..all value inside textfield which have been type at tabs-1 can copy into textfield at tabs-2... where part that i must modify?at form or at process page?what's code that can make it works? <script type="text/javascript"> ...

MVC and show/hinde panels?

Hi, I am using strong typed views in my MVC and have now manage to show all the editors for my register form as I like. The problem is that I have a radiogroup containing 4 radiobotton, When selecting a radiobutton I neet to hide some of the editors that are bound to the strong typed propertie fields. I could create a javascript funct...

Moving items between list-box using jQuery

<head> <script language="javascript" type="text/javascript" src="http://code.jquery.com/jquery-1.4.1.min.js"&gt;&lt;/script&gt; <script language="javascript" type="text/javascript"> $(function() { $("#MoveRight,#MoveLeft").click(function(event) { var id = $(event.target).attr("id"); var selectFrom = id...

Dot syntax variable onto array

Hi, I have an array of buttons that when clicked on, opens or closes content on my site. I need to be able to track which one is open so that when I click on that button again, I will know whether or not to close the content. Here's my array: var imageOptions = ['.corporateNeeds', '.marketResearch', '.corpStrategic', '.employeeTrainin...

jQuery Toggle function

Hi I have this code: $(document).ready(function () { $(".LeftColumn").hide(); $(".SidebarToggle").toggle(function () { $(this).addClass("active"); $(this).text("Hide Sidebar"); $(this).attr("title", "Hide Sidebar"); $(".LeftColumn").fadeIn("fast"); return false;...

What is faster, rendering gradient through css or load an image directly?

The reason for my question is because I like the new CSS3 styling techniques, but i'm not quite sure if it's worth it! (sub-question; anybody that knows if it's possible to use jQuery to apply a vignetting effect to a page?) Thanks guys ...

multiple class selection targeting distinct children

try the following: add two divs to a page with the same class name. add two elements within each div: for argument's sake paragraphs. make the text color of the first paragraph of each div red. why can't i figure out how to do this relatively simple task without having to use id's? ...

jquery display an alert after each 50 seconds, how to ?

anybody knows an easy way to display an alert after each 50 seconds in jquery (infinite loop) ...

Jquery: dealing with a json response?

I am having trouble parsing the response from my app. Here is the call with my best guess at how to deal with the json coming back... $.ajax({ url: 'houses.json', method: 'GET', datatype: 'json', success: function(data){ $.each(data, function(h){ $(h).each(function(){ console.log(h....

jQuery Tabbed Area

I have this code for a Tabbed area, but when a user clicks a tab the content snaps out and the new content fades in. I want to be able to have the content fade out and in. Also the tabs themselves fade between the active and inactive state but I don't have any code for it is this default behaviour kicking in? $(function () { var tab...

How to: jQuery post to ashx file to force download of result?

Hi, I have an ashx handler which takes the 'html' property from the request, then returns that back to whatever called it. I also have the Content-Disposition set as attachment. Calling the page directly works as expected, forcing a download with a save as dialog. What I'm stuck on is this: I need to do this from javascript (jQuery...

Jquery Bouncing Images Hover

How to bouncing images using jQuery when we hover the images? ...

Problem with FancyBox

I installed a pop-up slideshow gallery using FancyBox /example), which lets you add a caption under the pop-up image, using the title tag. Unfortunately, when you hover over the thumbnail, the title tag shows up with all the styled code in it, which looks pretty bad. Is there a way to disable the title hover, without disabling the actu...

Disable input field when checkbox toggled (JQuery)

I have a list of checkboxes and with every checkbox, there is an input field. If I check the checkbox, the inputfield has to be disabled. Example: Checkbox 1 - Input 1 Checkbox 2 - Input 2 Checkbox 3 - Input 3 The real code: <table id="food" width="580px"> <tr> <th colspan="5">Eten</th> ...

jquery dragging object fast problem

If I drag an object very slow, it does exactly what I want it to do. However, if I do it a bit faster or very fast, it does not work as expected. You can see both results: the expected, while dragging slow and the flawless, when dragging fast. I am just a jquery beginner, if you see any other stupid parts of the JS code, please let me kn...

how to access a class through id using jquery?

I have an html as follows: <fieldset id="question1"> <legend class='legend'>...</legend> ... <input type="text" name="label_no1" id="label_no1" autocomplete="off"> </fieldset> On the java script, I'm cloning the fieldset, yet I want to access its element to change ids, and some of the text. I tried this and it did not work: $(...

Autocomplete causes jQuery hover to fade out (Demo included)

Demo: http://www.christianbullock.com/so-demo/ (I know it's a bit rusty). Screenshot: http://i46.tinypic.com/2rh7fgn.png Hover over the blue rectangle to reveal the login panel. It works exactly how I'd like it to, with the exception that if you double-click one of the input forms to reveal the previously-entered usernames, by hovering...

Creating a JQueryscript for GM - Trouble by rewriting the JS code

Hello all, after trying to solve the problem without and with help I'm still stuck. My aim was writing a GM-script with JS. Someone told me to use jQuery because of its simplicity. Well, I started learning JS last week and my head is full of information. What I need is hint/start/beginning/whatever telling me how to rewrite the script ...

Reading a portion of the ajax html response

Hi there, My ajax (jquery) response (html) gives me a whole junk of html source code since it fetches the enrite page. The response is somewhat like below: <htmlhead/headbodydiv id="content"/div/body/htmldiv id='content'></div>? if yes, how? 2) if #1 is not possible, how could I extract just the content from the <div id='content...