jquery

Trying to keep slid div open with SlideDown/Up

I'm building a menu control that consists of a header area and a content area that contains the links. I'm hiding the content area initially and then calling SlideDown when I hover over the header and SlideUp when you leave the header. My problem is I want to keep the content area open if you are over it, as well. <div id="header">H...

Div ID fade code

Hi, I'm a newbie on jQuery. Can somebody help me with my 2days problem. I just in need of a sample code for a fading effect, slideshow. Here's the style. This will be 3 Divs with same class The first div, will show for 6secs then fades out for 2secs before the first fades out the second div will fade in for 2secs this again will sho...

Is there a jQuery version of Scriptaculous?

Scriptaculous is built on Prototype. Is there an effects library similar to Scriptaculous, but built on jQuery? There are many questions discussing jQuery and Scriptaculous, but none that directly address this question. Thanks. ...

NodeJS won't return data to jQuery.getJSON

I've set up NodeJS and it's returning data when I browse to the URL: http://184.106.206.235 However, when I try to call that URL using $.getJSON, the callback shows "null" for the "data" variable and "success" for the "textStatus" variable. I imagine this could be a cross-domain thing, but I'm surprised that the textStatus says "succe...

jquery click() event runs repeatedly

Hi, I have a jQuery question: I have an "ADD" button that adds text to the database via AJAX call ($.post()...). The problem is, items are getting repeatedly added. For example: After page loads: User clicks "ADD" button: the first time, it adds an item. a seconds time, it adds an item and then adds it again (total 2 items) a thrid t...

How do I access POST parameters in actions.class.php in symfony 1.4?

I'm still fairly new to symfony, so my apologies if this is a stupid question. I'm using symfony 1.4 with Doctrine. My colleague wrote a JavaScript to make a report from our client side widget to our server: $j.post(serverpath, {widget_id:widget_id, user_id:user_id, object_id:object_id, action_type:action_type, text_value:stuff_to_repor...

In Ruby on Rails, how to make HTML as partials in one file and Javascript in another file to be included last?

A lot of time, in a partial, the HTML (or ERB or HAML) as well as the Javascript is in one file, so when the main file includes these partials, the HTML will be intermixed with Javascript code. However, it is said that for fast page content display, all Javascropt code should be placed at the end of the HTML file. In this case, is ther...

jQuery - remove function attached to div

I'm running into a problem with jQuery, so I think I've figured out a workaround, but need help. I currently attach a cycle() slideshow to my div like this: function startSlideshow() { $('#slideshow').cycle({ some parameters }); } When I pause and restart this slideshow, it exhibits weird behavior, due to bugs in the cycle plugin...

Problem with UI Layout plugin in combination with Tokenizing autocomplete plugin, MVC .NET application

Hello, i have problem with jquery layout plugin in combination with Tokenizing autocomplete plugin. When i click on close bar on one of panes inside which sits input text box with tokenizing autocomplete plugin, div close. But, when reope i can find 2 input text boxes with tokenizing plugin. Anyone have solution for this? Need to preve...

How to add a progressive IDs to elements with jquery?

Hi All, Using jquery I want to add an id to a series of divs, but of course the ids need to be always different, so I thought to have a progressive number like id="1", id="2", id="3" etc. here's my markup: content <div class="box"> <p> content </p> ...

Jquery/javascript detect and capture page refresh events?

I have an AJAXed page, but I also offer a query string to the user so that he/she may type in the query string to the url to see the same page again. (Think google maps and its "share link" feature). When the AJAX request occurs I update the query string presented to the user, but the actual URL does not change. The problem is, if a us...

Simple question regarding doing action on checkbox click in jquery

I must have looked at 10-15 tutorials on this already but just cannot get this to work, so in my .js I have: jQuery('#sports : checkbox').click(function() { alert('it works'); }); and in my .html doc I have: <input type="checkbox" name="sports" /> It just won't work, no matter what I try and I have tried every variation I c...

Why doesn't this DIV drop down in the right spot?

Okay, here is the problem. I have an unordered list with a bunch of items. For each item, there is a corresponding DIV that will drop down when the item is hovered over. The sample can be found here. Now, it works fine unless you scroll down the page a bit and then try to hover over the item. Then it slides down further up the page tha...

Isn't jquery-fx.js already part of jquery.js?

I saw in a project that jquery-fx.js is being linked, but isn't it for show(), hide(), animate() etc, so jquery.js already has them? ...

Is it possible to add ScrollTo to my accordion FAQ page?

I'm using this accordion script for a simple FAQ page. http://www.dynamicdrive.com/dynamicindex17/ddaccordion.htm I tried adding http://mix26.com/demo/local_scroll/index.html the ScrollTo so when a question is opened, it scrolls down to it automatically for a better user experience. Can someone please help me? ...

Adding input field to PHP emailer only if it exists, how?

I have a form with inputs for 'name' and 'email'. And another for 'data-1'. The user can click on add button and jQuery will dynamically add a input for 'data-2', 'data-3' etc..as needed. The form is posted to a PHP emailer script which validates fields and places data into a template for mailing. How can i add inputs 'data-2', 'data-3...

possible reasons chained effects would break a toggle in jquery?

My below toggle() breaks when I uncomment the line $('.comments').slideUp('slow'); in the effects chain on the first half of the toggle. When I copy this code and the associated CSS and HTML into their own page everything works fine, as to identical pieces of code on the same page that toggle other elements. I get no errors or anything...

How to clean PHP session on page unload?

Hello. I would like to know if calling via AJAX or jQuery or whatever the server side, can I clean a session var?? Nowdays I have a FB application that runs with PHP and it's behaviour depends on a PHP session vars, and I would like to clean that session vars on the HTML event unload in the case that the user returns before the lifetim...

Using jQuery, remove extra HTML markup after closing HTML tag

My CMS is adding extra HTML markup after the closing HTML tag. I would like remove it using jQuery and am unable to find a selector that can select the closing HTML tag. Here is example markup: <html> <head> [...] </head> <body> [...] </body> </html> <span></span><span></span><span></span><div></div><div></div> Here is my feeble...

Trouble with email validation using jQuery validation in WebKit

Hi, I'm running into a strange issue in WebKit browsers, where the "email" field on my form won't trigger validation by the jQuery validation plugin (using the built-in email method). Works in FF and IE, but Safari and Chrome don't seem to like it. I've put together a sample page here with just the form and scripts for debugging: htt...