jquery

Background ad on website

Hi, I'm currently making a website where the owners want background ads (a ad as background on the whole site). It is quite easy to make in css: body { background-image: url('ad.jpg'); repeat, color..... } But, they want it to be a link. It is a little bit harder so I need some help with that. I have tried with something like...

How to call a function using 2 elements (by class) in EACH row of a table?

My approximate HTML: <div id='ComputerID'></div> <table id='gridComputerApps'> <tr> <td><div class='licenseOutput'/></td> <td><div class='AppName'>IE6</div></td> <td><div class='licenseOutput'/></td> <td><div class='AppName'>Firefox</div></td> <td><div class='licenseOutput'/></td> <td><div class='AppName'>SuperApp #2</div></td> <...

tinyMCE instance using ajax works only once

I have to initialize tinymce from the ajax-requested script get.edit.php. get.edit.php contains <textarea id="tinymce" rows="8" cols="80" style="width:100%"></textarea> <script type="text/javascript"> $("#tinymce").tinymce({ /* lot of tinymce data */ }); </script> and loads data into <div id="calldata"> in the main sc...

Fade working on FF but not on IE

This is my site: http://noamsm.co.il It should fade-in some text when the search box gets focus. and fade-out on blur. But it isn't working. You can view source; I put the jquery code in the page. ...

Help: Loop for dynamic <option> getting it from an array.

Hi, I need a help in my code, I cant figure out how to loop values from array and putting them a list/menu. I need to loop the array the roomType and combine it with the rate so it would look some thing like this (e.g. Single Room (980.00)) the values of roomType and rate would be dynamic for every option. please see my code and let me...

jQuery Variables as Key in Key:Pair CSS attributes

Is it possible to take something like: $("div").css({ "top": var1, "height": var2, etc. }); And turn it into: var dir = "top"; var length = "height"; $("div").css({ dir: var1, length: var2, etc. }); So far, the only way I can get it to work is by repeatedly declaring the lines separately, such as: $("div...

using jquery for Calculate total images in <id>

i have one DIV and inside div i have some imaes for example <img src= etc i want to calculate total Number of Images in that DIV also i want to save these images ID into mysql using PHP... Thanks ...

Why doesn't my code append to the string within the loop?

I'm using jQuery, building a table through a loop. I thought the best way of doing this would be to create an array then do $(blah).html(table); var settings_table = '<open the table>'; $.each(settings, function(i, val){ var settings_table = settings_table+'<put stuff in it>'; }); var settings_table = settings_table+'<close it...

jQuery Validation Enable Submit Button when Valid

I am using jQuery validation on my form and I would like to be able to disable the submit button and change its class, when the form validates. I know I could bind a function on the key up event but I want to know if this is possible from within the jQuery validate framework. I tried doing what this guy suggested, but got nowhere. I am...

Annoying Problem of Aligning CSS Drop Down

Hello all, View Here: http://174.132.101.73/~ree/header/ I have a drop down box. I am trying to get the text "Link 1", "Link 2" and "Link 3" to align left under the products link when you hover over it. But I can not get that to work for the life of me. I am sure its something simple. You will find the CSS code in question at the botto...

Copying from form to form in jQuery

I had a requirement to copy all fields from one form to another similar form. So instead of copying field by field I wrote a routine, form2form, using jQuery. function form2form(aF1, aF2) { var selection = "#" + aF1 + " .copy"; $(selection).each(function() { document.forms[aF2].elements[$(this).attr('name')].value = $(this).val(...

Placing jQuery Refernce at the bottom of HTML Document breaks User Control

Walter Rumsby provided a great answer to Where to place JavaScript in an HTML file. He references the work done by the Yahoo Exceptional Performance team and their recommendation to place scripts at the bottom of the page. Which is a hard and fast rule that I've been following for quite sometime now. In the same thread Levi Rosol pointed...

Jquery Hover Problem

I have one item that has a hover method attached to it, and when you hover it displays another div on top of it... unfortunately once the upper div displays it redoes the actions (since i added the same class for it to actually stick around) $(document).ready(function(){ $(".cartHover").hover( function () { $("#unique...

Remove Spacing Between Drop Down Menu

One final question with my CSS drop down box! I can not seem to remove the space in between the links "Link 1", "Link 2" and "Link 3". Under the Products drop down. Here is a demo: http://174.132.101.73/~ree/header/ How can I do this? I appreciate any more help. Thanks all ...

jquery: accordion and combobox

Greetings, I got trapped by following problem: We got an non-accordion Menu, and within this menu several combo boxes. The problem is, that actually none of the combo boxes are shown properly (no matter if you use the "traditional" combo boxes, or some fancy sexy-combo, /auto complete combo boxes etc.). Here the code: <html xmlns="...

Nested Maps in JQuery ajax data to send - how to serialize 'properly'?

var location = { "location" : { "name" : $("#user_loc_name").val(), "street_address" : $("#user_loc_street_address").val(), "city" : $("#user_loc_city").val(), "province" : $("#user_loc_province").val(), "country" : $("#user_loc_country").val(), "postal_code" : $("user_loc_postal_code").val(), "publ...

Jquery and ASCX control rendered multiple times on a page

I have an ascx control which contains dropdownboxes I want to be able to reset with JavaScript. Because the ascx control is rendered multiple times on the aspx page, I programatically add a distinguishing field to each dropdown such as this in the code behind of the ascx: var g = Guid.NewGuid().ToString().Replace("-", ""); DropDownListB...

Add absolute hyperlink URL

I have the part of the jquery code success: function(results) { if (results.d.Product.length > 1) { var html = '<h3>' + results.d.Product+ '<h3>' + '<div>' + results.d.ProductDescription + '</div>' + '**<a href="#">' + results.d.Url + '</a>';** $(test).html(html); ...

Dynamic mql_filter on Freebase Suggest

Is it possible to dynamically add an mql_filter to constrain results from a Freebase Suggest control? $(function() { $("#button").onclick(function() { // add an mql_filter to #film, a Freebase Suggest control }); $("#film").suggest({type:'/film/film'}); }); ...

Check XML node exists by Value using JQuery

Hi, I'm trying to check if a value in an xml node exists using Jquery. The xml string is: <SectionAnswers> <SectionAnswer> <detailID>2216</detailID> <SourceAnswerID>979</SourceAnswerID> </SectionAnswer> <SectionAnswer> <detailID>2218</detailID> <SourceAnswerID>981</SourceAnswerID> </SectionAnswer> <Sec...