hi,
here is a small example with the masked input plugin :
//apply the mask to an input
$('.st').live('click', function() {
$(this).mask("99:99");
});
.st is a text input with a td, the use can clone the td. However, when you clone this td, and try to click in the .st of the new element, your gain the focus of the first .st and it'...
I'm using Google App Engine, Jquery and Django. I want POST data to be sent to the server side when a form is submitted, and I do this in JQuery with the following code:
$("#listform").submit(function() {
$.ajax({
type: "POST",
url: "/xhrtest",
data: {'name': 'h...
I'm developing this app which as a very basic Ajax form and I'm currently validating the form input through jQuery with it's default validation plugin.
I'm wondering if I should also do server-side validation after submitting the form or just ignore and assume everything is right since the client-side validation was successful?
There's...
Dear all,
As the title, is it possible to get the current location (url) of an external page loaded in a jqModal window?
And further, in the implementation of the jqModal, in where the external page is located? iFrame or div?
Thanks for your kindly advise.
BRs,
William Choi
...
Is there any better way to rewrite this ?
$('element').removeClass('class-1').removeClass('class-2').removeClass('class-3').removeClass('class-5') ...
to .removeClass('class-105')
:)
i want to remove all class-(n) classes
Thanks
...
$('#request_song').autocomplete({
serviceUrl: '<%= ajax_path("trackName") %>',
minChars:1,
width: 300,
delimiter: /(,|;)\s*/,
deferRequestBy: 0, //miliseconds
params: { artists: 'Yes' },
onSelect: function(value, data){
artist = $('#request_artist').val(); //this will return "The Killers"
//make an ajax request to "...
Using this: http://malsup.com/jquery/corner/ I set up my nested divs so the container acts as a border like so:
$('#top').corner("bevel 68px").parent().css('padding', '1px').corner('bevel 70px');
<div id="ctop">
<div id="top">
//stuff
</div>
</div>
Now this works with rounded corners, the borders run along the edge. However,...
I am building a breakout game using jQuery and the <canvas> element. To control the paddle, it will follow the mouse. So I need to get the mouse co-ordinates in my drawPaddle() method.
Looking on the jQuery site it has examples like this:
$(document).mousemove(function(e){
$('#status').html(e.pageX +', '+ e.pageY);
});
Which does...
On jquery's validate plugin, an error message only disappears after the user has made focus on another element. I want to make it disappear as soon as the right info is written. How can validation be triggered 'onchange'?
...
Is there a way to disable the paste (control V) into a text box using javascript/jquery for IE?
I do not have access to the markup unfortunately or I would use onPaste="return false". Can it be attached with Jquery?
If it cannot be disabled at least is there a way to detect it so that when the paste event occurs just remove the text ...
I am using getJson to pull in some info onto the page
$('#request_song').autocomplete({
serviceUrl: '<%= ajax_path("trackName") %>',
minChars:1,
width: 300,
delimiter: /(,|;)\s*/,
deferRequestBy: 0, //miliseconds
params: { artists: 'Yes' },
onSelect: function(value, data){
// alert('You selected: ' + value + ', ' + $('#...
I'd like to add a fade-in/fade-out effect to the error messages displayed on jquery's validate. What's the way to do this? Could I use a div and on them and work them separately? Does the plugin include this effect?
I'm using this code to place error messages (I need it for proper placing):
$("#commentForm2").validate({
erro...
How to detect, does browser support the CSS :first-child selector?
...
I've tried to wrap up my problem with a complete example below - the original problem is part of a jQuery plug-in that I'm writing to extend the behaviour of an ASP.NET ajax application I already have.
The aspx page below has one drop down list which is marked for auto post back. I've also bound a change event using jquery (which ultima...
My last question asked for running once without the use of booleans. I decided I needed booleans but not a lot of variables since that would be messy.
So let's say I have this:
var counter = 0;
$(function() {
$('#typing').keyup(function() {
switch($(this).val().toLowerCase()) {
case 'test':
// DO THIS...
Hello Guys,
I have many hrefs(with dynamic Ids) in my asp.net app that have the same CssClass=MyClass.
I want these button to be hidden with a condition.
I used the .ready
$(document).ready(function() {
if(condition)
$('.MyClass').css("display","none");
});
the problem is docuement.ready doesn't execut when there is a poctba...
I'm dynamically creating and destroying textareas for this purpose. However, when I create a textarea and then an instance of it in tinymce--then come back to the page again, it doesn't work. I've found that the solution is to simply remove any existing instance of that same name, but I was wondering if it's possible to just do it at sta...
*Update: I have pasted working code in order to erase any ambiguity about what is going on. I have also tried to remove the preventDefault on both handlers, does not help
I have a form where upon the button click, a JS event needs to happen, and the form needs to submit.
As per the code below, what I thought would happen is: alert(but...
Hiya,
I want to add an Amazon Books Wish List to my site and I want to style it with CSS.
So, how can I do it? Should I use PHP or can I use Jquery?
Do you know PHP tutorials for it or any Jquery plug in?
Thanks
...
I'm pretty new to javascript, and has built a script that is working in webkit but not in firefox. When i check for errors in firebug, I get this:
google.maps.Geocoder is not a constructor
$('.to, .from').geo_autocomplete(new google.maps.Geocoder, {
what does it mean?
...