Hi, I wont to be able to send a variable to a JavaScript function when I click on a link but for some reason I cant find anywhere on how to do it on the internet.
Here is the function at the top of my page:
<script>
$(document).ready(function(){
$('[name=updateInterface]').click(function() {
$("#interfaceScreen").load("modules/interfac...
I have a json array
var states = { "1": "California", "2": "LA" };
How can i count and print the items in states. It should print 2.
if I use states.length it gives an error
...
In one of my projects I'm using simplemodal to load a dialog that contains a function setup_dialog(). I use the simplemodal callback onShow() to execute setup_dialog(). This functions perfectly in Firefox. But in IE I get an error about setup_dialog() not existing.
Is this a known limitation of IE (hard to believe) and what can I do to ...
I am using the typeWatch plugin to monitor a text field and I want to send a callback to a controller to then replace a divin the view. The event is hitting the controller but I cannot seem to get the div to update the contents:
$(function() {
$("#start_date").typeWatch( { highlight: true, callback: finished } );
function finished...
Code as follows:
<div class="mama">
<div class="son">Item 1</div>
</div>
<div class="mama">
<div class="son">Item 2</div>
</div>
$(".mama").hover(
function() {
$(".son").show();
},
function() {
$(".son").hide();
}
);
Forward to help. Thanks!
...
i'm trying out this jquery plugin http://plugins.jquery.com/project/stylish-select-box/
it works good but with prototype + jquery in noConflict mode
this function broke others scripts
Array.prototype.indexOf = function (obj, start) {
for (var i = (start || 0); i < this.length; i++) {
if (this[i] == obj) {
return i;
...
Hi...
Trying to add dynamic borders on my website top, left, and right sides... The pages on my site are dynamic... That is they change... I need to have a script that adapts a div to the webpage simply...
Anyone know this?
I got this script from some guy on this forum, but I am trying to avoid jQuery (don't ask)...
<p class="bgr">Con...
If you have a fair number of regular expressions used by both client (javascript) and server side code (C#, vb.net) and want to store them in one place to avoid duplication, where do you store them?
I could use registerscript and write out the regex as strings, but just wondering if there is something more elegant.
...
Hi,
I have 3 dropdownlists for Country,State and Metro.
I want to when user seclect Country then State dropdownlist fill Jquery and when select Sate then Metro dropdownlist fill(like cascading dropdownlist of ajax).These process i want to do with JQuery.
...
I've been working on some code where I trigger the code on hover/unhover. Then I decided to trigger the same code also on focus/blur. Usually with hover/unhover only, I go for the usual hover comma no unhover format. But this time since I was trying to add focus/blur, I had to use bind and use this.bind with the second part too, like thi...
Hi,
I want to implement paging in Repeater via JQuery.
Is it possible? If yes, then how I achieve this?
...
I'm creating an HTML/JavaScript widget to be used on third-party sites. This widget is generated by a <script> that our customers will insert on their page. The <script> creates an <iframe> in the customer's domain, and then creates and inserts all of that <iframe>'s content using JavaScript.
It's important that this <iframe> contain Cl...
I am working on a jQuery plugin and I would like for the user to pass in a method name to be executed after a flag (in the code) is set to true. I already have the flags working as needed, I just need a way to execute the method that is passed.
For example:
(function(jQuery){
$.fn.extend({
pluginName: function(options) {
var ...
Thanks for looking, all sincerely helpful answers are up-voted.
I have some date input fields that are there when the page loads and a bunch that get generated dynamically. Instead of calling .datepicker() on that class each time a new instance is generated, I'm using .live, but it doesn't seem to be working. Any idea why?
$("input[name...
To all,
I am trying to retrieve the exchange rate from Google with jQuery's $.getJSON(). Using the request: "http://www.google.com/ig/calculator?hl=en&q=1USD=?CAD"
returns a simple JSON file: {lhs: "1 U.S. dollar",rhs: "1.03800015 Canadian dollars",error: "",icc: true}
I am using the following jquery function to get the Canadian ...
I'm building a price estimator form, which uses jQuery to manipulate select menus. Basically, when a new quantity is chosen, the value of each option in every select menu is multiplied by a per-unit price, and a new price is shown to the user.
What I'm trying to do is pull the per-unit prices from a PHP file, which stores these prices i...
This one has me stumped.
<div id="container">
<div id="store"></div>
<div id="contact"></div>
</div>
I'm looking for the contact divs position as child of "container". So just to be extra clear, if i'm looking for 'contact's position, i need jquery to return the number 1.
any help is greatly appreciated!
thanks!
...
Is it possible to scroll to a specific location on the page using jQuery?
Does the location I want to scroll to have to have:
<a name="#123">here</a>
Or can it just move to a specific DOM id?
...
Hi, I'll admit the title is a bit confusing but it was hard to come up with a better one.
Ok, so What I have is 3 pages, first is the main page that the user loads up and the other 2 are ones that are going to be loaded into the main page with jQuery.
Here is the JavaScript code on the first page:
$(document).ready(function(){
$("#ma...
For the life of me, I can not figure out why some styles are not being applied to an unordered list.
If you view this site: http://www.alclawyers.com.au/ in Firefox, you will notice there are circles down the bottom of the text that can be clicked to shift to different panels of content.
Now, when you visit the same site in IE7, none o...