jquery

JQuery IE <div> opacity problem

I have a problem with IE. I have a layer that has this style to make it transparent and fullscreen. position:absolute; top: 0px; left: 0px; right: 0px; bottom: 0px; background-color: #000000; filter:alpha(opacity=50); -moz-opacity: 0.5; opacity: 0.5; z-index: 1; And i use the JQuery method fadeIn and fadeOut to show and hide it. Wel...

How can we return the css attributes of an element with jQuery?

One of the most powerful things of jQuery is to select any item on a page like this: $(".block").css("border","3px solid red"); How can I also get the values of the selected items like width height and top left offset? ...

How to call a function in javascript by its name

I was trying the next code without success HTML <a id="addBookButton" href="javascript:showForm('addBookButton','add-book','activateAddBookForm');" class="addA"><span>Add Book</span></a> Javascript function showForm(button,form,callback) { $("#"+button).hide(); $("#"+form).show(); callback(); } ...

jquery to find all exact td matches

$('#servertable td:eq(' + server + ')') this finds only 1 (first I think) match, how to find all matches. btw. td:contains will not work for me. ...

Firefox/jQuery is not reading any attribute for an img element

So I am attempting to combine two image galleries, Galleria and Lightbox. The way it is supposed to work is that Lightbox will read the href from the anchor tag and Galleria will read the src from the image tag in the following code: <a href="./public/images/gallery/2.JPG"> <img class="replaced" src="./public/images/gallery/2.JPG"/> </...

Delete a table row with javascript / jquery

This is not working. Firebug is not throwing any error though. HTML: <table> <tr><td>BookA</td><td><a href="javascript:deleteRow($(this));" class="red">Delete</a></td></tr> <tr><td>BookB</td><td><a href="javascript:deleteRow($(this));" class="red">Delete</a></td></tr> <tr><td>BookC</td><td><a href="javascript:...

Jquery Ajax call to webservice is failing

Hi there, Can anyone help? I have an issue with calling a asp.net webservice from jquery.. actually i think it maybe jquery ... as i have a break point and it doesn't arrive in the webservice.. Here is my jquery, the webservice method accepts 2 parameters... So i setup a simple test to pass in 7 and 7 .. i tried replacing with the wor...

jQuery find whole number and append decimal

Need to take a SELECT drop down list options and find if any of the values are whole numbers, then append a .00 to the list value option. need to change the value as well. <select> <option value="1">1</option> <option value="1.99">1.99</option> <option value="2.99">2.99</option> <option value="4">4</option> </select> Thanks in...

jqModal, jquery question

Hi, I have the following code; // open the modal when an element with a class 'edit' is clicked $('.edit').live('click', function() {` $('#mdl_edit').jqm({onHide: f($(this).attr('id')), ajax: 'ajax/edit_modal.aspx?lid=' + $(this).attr('id'), ajaxText: '<img src="img/ajax-loader.gif"' }); $('#...

ASP.NET MVC resolve urls in javascript

I am loading up some content via jQuery.load('/Business/Tags'), which works well when using my local webserver. But when using iis this does not resolve correctly. I have seen a couple different ways to get around this such as ResolveUrl. What is the best way to handle resolving urls in your javascript? ...

jGrowl not working with MasterPage

Hi, I'm trying to use jGrowl in an aspx page. But I encountered a problem that I couldn't solve. When I use a regular aspx page the jGrowl is working fine. however when I use the page with a MasterPage the jGrowl is not working ,I got a javascript error saying $.jGrowl is not a function. From Firebug Console, I can query $; $("a"); the...

fadeout manual (on click) with automatic (after few seconds)

$('<div class="error"></div>').html('<h2>(click here to dismiss)</h2>').insertAfter($('#someid')).fadeIn('slow').animate({ opacity: 1.0 }, 1000).click(function() { $(this).fadeOut('slow', function() { $(this).remove() }) }); is there a way to combine this with: $('#someid').animate({opactiy: 1.0 } fadeOut(...

Text Shadow with jquery

I wish to change the text-shadow attribute of elements with javascript. As far as I know jquery css does not work with text-shadow. Does anyone have any suggestions for dynamically changing text-shadow. Thanks! ...

Why doesn't addTextObject() with a jQuery variable work?

When developing a Windows Vista/7 Gadget, and putting out text using addTextObject(), this works: var mytext = "Hello"; document.getElementById("background").addTextObject(mytext , "Verdana", 11, "white", 10, 10); But I cant get this jQuery selector into a variable to work: var mytext = $("#myid").text(); document.getElementById("bac...

problem with calling remote ASMX using jQuery

Hi there. Been trying my best to understand this correctly. What is the difference between an XML, SOAP and JSON response? And how does one know how to call a web service whose response is one of the above? (...Please correct me if I'm off-track) The reason I ask this because I am trying to call a remote ASMX from jQuery within my .NET...

Is there a way to query HTML/XML content from a variable using jQuery?

If I have HTML content in a variable like so: var data = "<div id='myid'><div id='subid'>Text</div></div>"; Is there a way to query this using jQuery and selectors? As this, if it were HTML DOM: var data = $("#myid > #subid").text(); ...

Prevent Users from submitting form by hitting enter #2

Well in a previous question I asked the same thing, but the answer that i doesn't prevent a submit when the user is in a text-box. So basically what i need is the ability to keep a person from submitting a form unless the explicitly click the submit button. edit: basically the main reason for doing this is that this is an employer sur...

Passing a variable value from javascript to ASP

Hello all, With the help of this community, I've been able to pass a static chunk of text from javascript (clientside) to ASP 3.5 (server side)! This piece of code works beautifully: $('.drop').droppable({ tolerance: "touch", // Here should be a string drop: function() { $('[id$="myHidden"]').val('Testy test test'); __...

Simple JQuery ajax script question

How do I make it so that the browser calls up a php page and posts the results in a div every 10 seconds or so? Thanks. I am just learning jquery. ...

Using jQuery to grab the content from CKEditor's iframe

Hey guys, I have this custom written CMS that uses CKEditor *(FCKEditor v3) for editing content. Along with that I'm using the jQuery Validation plugin to check all fields for error prior to ajax-based submission. For passing on the data to the PHP backend, I'm using the serialize() function. Problem is, serialize manages to grab...