jquery

Translating jquery idiom to YUI

How can I translate the following jquery idiom to YUI? $("a").click(function(event){ alert("Saw a click!"); }); The above is supposed to add a custom on-click event to all anchor tags in the document. ...

How do I load an external http xml request with jquery?

How do I load an external http xml request with jquery? Below is a url when pasted into a web browser like firefox, an xml document is shown. This is for the CPanel XML API. http://hostingz.org:2086/xml-api/createacct?username=WeAreWatching&plan=hostingz%5FFH5&ip=n&cpmod=x3&password=changeme&contact email=contact.w...

Get top of current window position relative to the document body

Hello on and all. I am developing a model box jQuery plugin, and I need to know how to get some window properties. The box and its shader div fade over top of the page, and the shader div covers the complete body, not just the window (Important for pages that have horizontal scroll bars). When the model div fades in, it centers itself ...

Invalidating cached content, If-Modified Headers?

I'm having a peculiar problem: PHP SCRIPT: // checks If-Modified-Since header (if nothing has changed) // Sends HTTP/1.0 304 Not Modified // Sends Cache-control: public, must-revalidate // exits // if NO If-Modified-Since or something has changed // builds content // Sends Last-Modified: [DATE TIME] // Sends Cache-control: public, mus...

Safari / JQUery - Insert and Update Hidden Field On Page

In safari, Im trying to insert a Hidden field into the DOM then update its value as below. colHiddenFieldId = 'row_100000_0_NewValue' $("#" + colHiddenFieldId).val('TEST') However the value is never getting set, it looks Safari dosn't think the hidden field exists. I know it does because it works on every other browser known to man...

Why doesn't jQuery $(this).text() work inside a link?

Any ideas why this doesn't work? <a href="javascript:alert($(this).text())">Alert This Text Here</a> I am expecting it to alert "Alert This Text Here", but instead I get a jQuery error (G is undefined) What am I missing? ...

min-width and max-width with jQuery

How to emulate for ie6? ...

Removing a table row using jquery, fading and changing color slightly.

Hi, I have a button that when clicked, gets the row in the table that was clicked on. So I have: $("#someId").remove(); I want to highlight the row that is being deleted, and fade it out (it is being deleted). Is there a way to do this with jQuery? I tried: $("#someId").fadeOut("slow").remove() but tat didn't seem to show anythin...

What are valid / invalid names for HTML form tags in jQuery?

This flows from the error I ran into here jQuery $(’form’).serialize() returns only one element of a form serialized where having a form tag named "elements", like so: <form> <input name="elements"/> <input name="e2"/> </form> prevents you from accessing all the named elements of the form with jQuery's $('form').serialize() (i.e. you ...

jQuery tooltip not working as expected - REVISED

Hello all, Ok I fixed the original problem but I would like now is to add the title value back to the anchor tag of id="contact" from the id="contact-info" popup before I remove the popup The JS this.contactPreview = function() { jQuery("a.contact").click(function(e){ this.t = this.title; this.title = ""; var c...

Best jquery inline editor

I have been looking for a really good, well documented jquery plug-in that will let me edit values on click of another button. This plugin is the closest yet, However I am not sure how to get it to save, even in testing. Something really quick that returns the value. I am using this for my php script: function editprofile() { ...

How does jQuerys .animate method work (JavaScript)?

As the title says, how does it work? Looking through the source is a nightmare because it's all using complicated arrays, but I don't really see code which does anything. Any ideas? ...

Jquery count number of hidden elements within div

How can I count the number of items in div that are hidden? Thanks in advance ...

Download File Using jQuery

Hello all, How can I prompt a download for a user when they click a link. For example, instead of: <a href="uploads/file.doc">Download Here</a> I could use: <a href="#">Download Here</a> $('a').click... //Some jquery to download the file This way, Google does not index my HREF's and private files. Can this be done with jQuery...

jQuery tooltip popup re-insert title value on close - WORKING YEAH!!!

Hey all, This is part two of the question: On closing of the popup I need to re-insert the title="" value to the original value before the popup link was clicked. the popup uses the title='" value to display in the popup and removes it from the original tag so as to not display in the tooltip if someone hovers over the link. The JS t...

javascript to php question

<script type="text/javascript"> $(document).ready(function() { $("#uploadify").uploadify({ 'uploader' : 'scripts/uploadify.swf', 'script' : 'scripts/uploadify.php', 'buttonImg' : 'css/btn_browseFiles.png', 'rollover' : 'true', 'wmode' : 'transparent', 'height' : ...

jeditable edit all sections?

I am trying to figure out how to edit all the areas with a certain class with 1 edit button. This is my JS: I threw it into a function to be used over again. I have a surrounding div and inside of it are spans with classes of "details" How do I create 1 button "edit" and have them all trigger at one time? Trying to simulate the faceb...

Dynamically hiding table rows with jQuery

I am trying to alternate background colors of table rows, each section starting with the same color. I have achieved this with the following code: $(document).ready(function(){ $("tbody tr.row:nth-child(even)").css("background", "#efefef"); }); I also need to be able to limit the number of rows (5 for example) that are visible inside ...

How to I post a value through the XMLHTTPRequest Object?

I have a set of links dynamically generated in a table. Each of the rows has a unique "id" property on it's tag. The goal is to get XMLHTTPRequest to tell the page 'deletepost.php' which record to remove from an outside database. It changes a hidden input value to the value of the row (a number), and then submits that form <script...

jQuery and Table, grab every cell in the NTH column

Lets say I have your basic table layout (like below). How to I grab every NTH cell? I basically want to add a css class to the cells in column N. So if I wanted all cells in column 2, I want to have a jQuery obj that contain the following cells that are marked: <table> <tr class="trow"> <td></td> <td></td> <!-- incl...