jquery

jQuery and drop in table

I have the folowing code. When the table is empty in need to append to ti but if there's rows I need to insertBefore the row on which I drop. But the drop is only detected on the TABLE, the trace only show table evne if I drop on a tr $("#mytable TABLE, #mytable TABLE").droppable({ drop: function(event, ui) { v...

jQuery slider as a timeline

I have just finished incorporating a jQuery accordian with a jQuery Slider. I.e. 3 pictures are displayed. The user can either use PREV or NEXT buttons to view the next/prev 3 images. They can also navigate through all the images with the slider. The next step is to make this slider look like a timeline. The left hand side needs to sta...

JavaScript - how to ignore minor dragging events?

Hi, I have a draggable image within a div. I can click on the image to bring up a pop-up menu, which works fine. Quite often when I click on the image I drag it by about 1-5 pixels, therefore on click event doesn't get fired up, instead, a dragstart event gets fired up, so the pop-up menu doesn't appear on the screen. Is there a way to...

jQuery: Check to see if table row containing certain values exists already

Hi All, I have a jQuery script that appends a row to a table. In short, the user can select a value from a drop down menu, then enter in 'x' amount of months and hid 'add' which appends the row to the table, for example the following row is appended by the user: <tr> <td>Some Value</td <td>2</td> </tr> Now, if the user performs ...

Jump browser window down to a DOM Element

OK, I'm sure I'm justing having a brain-fart after 2 weeks Honeymoon in Tuscany... by brains clear, and I'm googled out looking for keywords and how to do it, even scanned down the JQuery Valdate.js looking for the bit that does it... What I want to do is this; but don't know where to start. if ($("#errorMessage").exists()){ // Jump b...

window resizing problem

I have been working on a plugin of wordpress, in which i save the last reading position, the width and height of the browser at the time of closing the browser, I save the width and height with jquery height=$(window).height(); width=$(window).width(); and save the values in database so that when the page is loaded next time, the values ...

Get anchor ids and convert to a JavaScript array

How can I use jQuery to obtain all the ids of the anchors within a specific div and convert them to a array for passing over a load/get method? The HTML will be in the following format: <div id="a div id"> <div style="some styling"> <span><a href="" id="the_id_1"/></span> <span><a href="" id="the_id_2"/></span> <sp...

How do I get the jQuery-UI version?

This should be an easy question, but how do I detect the jQuery-UI version? This is for a Greasemonkey script and the (current) target page appears to be running jQuery-UI, 1.5.2. But, different target pages may run different versions. console.log ($.ui); did not show anything useful/obvious for version detection. ...

JQuery select checkboxes with the same value

Is there a way in JQuery to check checkboxes based on their value. e.g. if I have 3 checkboxes with the value 'test' is there any way I can check them all based just on the fact that they have the value 'test' ...

Jquery multiple dialog box

Hi i m using the code below, HTML: This is the dialog box which will open on onlick.but i want different dialog boxes to be opened on different onclicks. JS: /// Dialog //// $('#dialog').dialog({ modal: true , autoOpen: false, width: 300, buttons: { "Ok": function() { $(this).dialog("close"); }, "Cancel": ...

How to get only one element

For example I have a function that has one argument, it can be DOM element ID or className. How can I select only first element wrapped with jQuery? $(value).get(0) and $(value)[0] returns just the plain DOM element, not a jQuery wrapped element. ...

jQuery, CSS: Two divs, how can I make them "show"next to each other?

Hi, my client has asked me to make exactly what's happening in this jsFiddle example. All I need is to make them appear next to each other. As you see when one is fired it displays in the correct place, but when the other is fired, it pushes the other down. How can I ensure they always show next to each other? Note: This is VERY si...

Encrypt user password with jquery and decrypt it with C#

Hello every body, I don't want to use SSL to encrypt signup and signin forms for a website i'm building. I dont have money to pay for a certificate. I need to use enryption with jquery and decryption with C# in my asp.net website. Does someone have an example and how is it secure to adopt this method? ...

How does FaceBook manage to have popups that accept postbacks?

Hello guys, I wonder why all jQuery popups plugins don't accept postback. But if you see FaceBook see all friends popup, you can do next & previous. And if you remark, there is a postback (I think) when you click next or previous. Can someone give me a link or explain how they do that? I have remarked too, that you can right click (o...

how to return xml data document constructed on the webservice to clientside ajax jquery call

I have a webmethod which is trying to construct xml data document and return to clientside but i am not able to guess whether the error is on clientside call or webservice return method.please can anyone help to sortout this logic [WebMethod] [ScriptMethod(ResponseFormat = ResponseFormat.Xml)] public XmlDataDocument GetList(stri...

How to parse the returned object from "success" callback method in JQuery using AJAX

Hi all, I have this stadard code for receiving a class from a web service: function getStuff() { var callParams = "{'param1':'" + "oren" + "'}" $.ajax({ type: "POST", url: "http://192.168.5.223:8989/TolunaAPI.asmx/GetDummyType", data: callParams, contentType: "application/json; charset=utf-8", dataType: "json", succ...

jquery calculation getting size of calculations...

I used the Jquery calculation plugin successfully to perform two calculations on both subtotals and a grand total much like the last example on the demo page: http://www.pengoworks.com/workshop/jquery/calculation/calculation.plugin.htm However I'd like to also get a total count of the number of beds that are selected but can't seem to ...

How can i get the unselected items from dropdown using jQuery?

How can i get the unselected items from dropdown using jQuery ...

check box stops my Jquery script

I my login form if I dont check remember me check box in php script it gives <b>Notice</b>: Undefined index: autologin in error. in my .php file I have $check_autologin = $_POST['autologin']; And I am checking is user checked it if($check_autologin == 1) { $password_hash = $encrypted_mypassword; setcookie ($cookie_na...

How do I trigger a click when hovering over a element for 2 seconds, using JQuery?

Hi All, How do I trigger this inline functiononClick="showMenu('mnu_searches', event, 0, this) using JQuery...if I hover over a.menu-arrow ? I need to trigger a click after the user has been hovering over the element for 2 seconds? Any help would be greatly appreciated, Thanks ...