I'm trying to temporarily change the contents of a div on hover, using this jQuery:
$(document).ready( function() {
var $ratingHtml = '';
$('.userRating').hover(
function() {
$ratingHtml = $(this).html();
alert($ratingHtml);
$(this).html( 'Log in to rate' );
},
function...
By clicking on the "mylink" I want the link to be replaced by the number "123", which is extracted from parent tag.
I think I'm not doing the ".match(...." right.
jQuery:
$(document).ready(function(){
$(".link").click(function(){
var comid = $(this).parents("div.comment").attr("class").match(/comment-([0-9]+)/)[1];
$(".link")...
I'm using jQuery to display a tabbed area, and I have a table below the tabs. The whole thing, tabs and table, are re-sizable.
I'd like for the table to have a scroll bar, so that when you re-size the container, the scroll bar re-sizes.
Right now, I have two issues.
1) I'd like for the scroll bar to extend from just below the tabs...
I'm currently looking for an easy way to extract information from server XML responses using JavaScript. jQuery seems like a good candidate for this.
When it comes to parsing XML with jQuery, I keep coming across code examples similar to the following snippet:
function parseXml(responseXml) {
$(responseXml).find('someSelector')......
I have a series of images, and I simply want to record when each is clicked. They never show up in their own view, so running the code there is worthless.
I've wired up a click event using jQuery. Though the $.post doesn't work. Any idea how I can achieve what I am trying? The 'hit' is just an HTML element stored in the view when it dra...
I'm wanting to select some DOM elements using jQuery, modify some attributes, and then write the DOM elements back out as xhtml snippets for post processing. I want the resulting xHTML to have only the attributes specified in the original page html plus the modifications I make with jQuery.
Is there an existing javascript library or AP...
Hi, I'm trying to make modal window for my website, I have a problem with overlay or modal div I'm not sure what is the problem.
The thing is everything except modal window shouldn't be clickable, but for some reason my navigation <ul><li> tags are visible and clickable. Here is css of my modal window :
element.style {
display:block;
...
Hey, I am trying to get the class names dynamically for the script below.
I have different class names that are created through PHP so need to get them using jQuery dynamically.
As you can see below, there seems to be 2 areas where I need to get the class name. At the moment it is hard coded (the classes are named 'result'):
1) var ne...
I'm using this code:
var timeout = 500;
var closetimer = 0;
var ddmenuitem = 0;
function navBar_open()
{ navBar_canceltimer();
navBar_close();
ddmenuitem = $(this).find('ul').css('visibility', 'visible');}
function navBar_close()
{ if(ddmenuitem) ddmenuitem.css('visibility', 'hidden');}
function navBar_timer()
{ closetime...
I have some client-side JavaScript validation on a form. It works great. But I want to accommodate users who have JavaScript disabled. My validation isn't run from the form's onsubmit attribute, it's an event handler that is bound to a normal button in the form. So the button that kicks off the validation and submit isn't actually a subm...
For several months I've been working on a customer site building a web site using ASP.NET MVC with C#, SQL Server 2005, ADO.NET Entity Framework, JQuery and some ESRI web APIs and geodatabases. The test server is running IIS6 on Windows Server 2003. Over this time I've seen some weird things that have caused a lot of rework:
JavaScript...
Hi Im wondering if any one can help me figure out how to use different sets navigation tabs to load content to different div's independently?
For example: a horizontal navigation bar that loads content in a header DIV, and e vertical navigation bar that loads content in a div in the body part of the page ?!
Here is the ajax script im u...
I am trying to create a jquery plugin
I want have the following options:
1- $.plugin_name(variable)
2 - $(selector).plugin_name(variable)
the first case the plugin would not need to be applied to an element ( it could create one for example) the second case the same plugin will do whatever it does on the element/s selected
my quest...
When the mouse cursor moves over an image, I would like to display an alert() containing the value of that image's src attribute. How could I go about accomplishing this?
...
Hi People,
Can anyone see anything specific that would be causing issues with jQuery in ie6? No jQuery elements are loading at all in ie6. ALL OTHER BROWSERS ARE FINE!!!! Thank you so much for your help!
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html x...
I am having some strange problems loading content from another XHTML page via jQuery. When the second page I try to load from is served as XHTML I get the below error. I don't know if it helps but both documents validate when I get the error.
Uncaught Error:
NO_MODIFICATION_ALLOWED_ERR: DOM
Exception 7
Currently the header on t...
Dear all
I have a Zend Framework application. It works normal and load Jquery from my local folder. But after try this tutorial (but removed the Jquery call as in the tut) and revised some JS call (load some JS file from layout instead of view), it work abnomally: automatically load Jquery from Google CDN:
<script src="http://ajax.goog...
I would like to autorefresh a certain div with the ID of blue everytime I update a post with that ID.
I know the Jquery code looks something like this:
var auto_refresh = setInterval(
function ()
{
$('#blue').load('load.php').fadeIn("slow");
}, 10000);
Instead of loading "load.php" I would just like to reload the updated contents in t...
Hello,
I have a test web service called: MySimpleService.svc with a method called:GetUserNamesByInitials. below is the Linq to SQL code:
[OperationContract]
public static string GetUserNamesByInitials(string initials)
{
string result = "";
//obtain the data source
var testDB = new TestDBDataContext();
...
$.getScript('ajax/test.js', function() {
alert('Load was performed.');
});
.. like the above code which loads an external JS on request, is there something similar available to load an external CSS stylesheet when required?
Like for example when I use lightboxes (inline popups) on my site, I want to avoid loading lightbox JS and CS...