I have an activerecord model and set of validators to it, But I also have to provide front end validation.
Is there a gem or a smart way to use activerecord validators, for instance in jquery validation plugin, instead of writing it by hand?
Thanks
...
I'm creating a simple jQuery editor, nothing complicated, and just can't seem to find out why the events do not work. See code below.
var $editor = $('<div>').addClass('editor')
.insertBefore(this.$element)
.append(this.$element);
var $b = $('<div>').addClass('button-wrapper')
.appendTo($editor);
this.$element.css({h...
I'm trying to create a dynamic module where I drop an object on screen. Then a jQuery dialog opens with three drop-down lists. When I select a value in the first drop-down list I'm trying to filter the results in the next list via Ajax.
This is my JS code:
$("#ddlTableType").live(
'change',
function()
{
...
This code shows the primary div tag elements fine but ignores or does not recognize CSS and HTML in a child div tag.
I can get this code to open multiple divs but not the divs nested inside the first level of divs. 6 hours later I am hoping for outside help.
Here is the code:
<html>
<head>
<style type="text/css">
#tabs{
margin:20 px ...
Greetings,
I'm having a lot of trouble with the IE8 buy of getting black borders when using a JQUERY slider, with PNG transparent images.
Using a slightly modified version of the Nivio slider.
I have searched high and low for fixes and blocks of code but so far none have worked.
What happens is that as soon as the img cycles it gets ...
Hi there ...
am wondering ... how to only accept alphabetical pressed keys from the keyboard .. i am using the jQuery .keypress method ... now i wanna know how to filter the passed key ...
i am trying to build a simple autocomplete plugin for jQuery ...i know a about jQuery UI, but i want to do it myself ...
thanks in advance :)
...
Ok, let's say I have a navigation system constructed in nested divs and I want to show sub-menu divs (and sub-sub-menu divs) when I do a mouseover on the menu div AND hide sub-menu divs (and sub-sub-menu divs) on a mouseout, or more precisely, when I mouseover a different menu div.
What would be the best way?
So far, here's what I've g...
I have inherited the following code snippet:
<div id="topbox">
<h3>
<div class="compare_link">Compare Products</div>
<input type="checkbox" id="compare_123" name="chkcompare[]" value="123" />
</h3>
</div>
What I'm trying to figure out is:
I want to find all h3 selectors that have compare_link and HTML checkbox as...
Im trying to build a page that will allow a user to select a maximum of 8 out of 20 checkboxes, in a specific order, on a single form.
Im trying to make a page that will only be viewable if the right sequence of checkboxes are clicked, a neat way to let only those who have the checkbox sequence in on a certain part of my website.
What ...
Following is an example code test harness which emulates the problem I am experiencing. Basically, when not using resizable() for the textarea, clicking on the "Content [+/-]" allows the fieldset to collapse and no textarea is shown. However, when using resizable, clicking on "Content [+/-]" causes the text area to be hidden, but the ori...
I have a form generated dynamically with the method .append() of jQuery.
I can add any number of new input, textbox, cmbbox, etc...
But the problem is that when I do the sumbit of the form, the PHP target does not receive the new input added, but just the vars connected to the input already in the form before the append().
Any ideas?
...
Hi,
I have quite an odd problem here - I am using jquery for resizing my background image (png, width: 1793, height: 1200, size: 872kb).
My function is here:
bgInit = function(img, clbk) {
var bgObj = $('#bgImg');
var bgHeight = bgWidth = 0;
bgObj.attr('src',img).ready(function(){
var bgRatio = bgObj.height()/bgObj.width();
...
Hey everyone
How can i customize asp.net controls like devexpress did?
Here is some example, this is actually what i want to make:
http://demos.devexpress.com/ASPxGridViewDemos/GridEditing/EditModes.aspx
About this, any tutorial, any resource?
Thanks.
...
Is it possible to use shift and mouse click to select multiple elements on a page using jquery?
I have several divs that i have given a tabindex to so that i can select them and can do things like delete them etc.
I want to be able to select more than 1 by holding down shift and using the mouse to click on each div and am struggling to...
Hi!
Is there any official jQuery plugin (like jQuery UI) that allows those effects in all browsers? Or at least IE8, Chome, FF and Opera. I don't want user plugins as those often lack support in the long term, are uncompatible with one another or lack consistent quality and optimization.
I saw some "Overlay and Shadow Classes" in the j...
Hello,
I'm trying to create cascading DDLs.
My aspx page:
<form id="form1" runat="server">
<table>
<tr>
<td>סוג שולחן</td>
<td><asp:DropDownList ID="ddlTableType" runat="server" /></td>
</tr>
<tr>
<td>קוד שולחן</td>
<td><asp:DropDownList ID="ddlTableCode" runa...
I'm working on an app in ASP.NET MVC 2, and the output of the table looks the way I'd expect in Chrome and IE8:
but this is how it looks in FF 3.6.8 it looks like this:
I'm using javascript/jquery to add rows, this is the code:
function onAddItem() {
itemCount = itemCount + 1;
var rowString = "<tr id=" + it...
I am trying to present a form inside an overlay. The form is loaded via ajax. This all works fine on firefox 3.x.
But on Safari 5.0(5533.16), the overlay shows but does not make an ajax request, rather makes a html request.
Here is how I configure it in my js and then on document.ready I call ModalPostForm.init();
pastie - http://pas...
I'm looking for a jQuery Rails deep linking solution...
Facebook has a great system as it doesn't have the ugly #s in the URL. Anyone know what they use and / or have any recommendations?
...
Hi,
I need to add some function that returns a value to a dom element. I tried to use jquery's bind method, but it seems that events always return a jquery collection.
My goal is creating a flashcard application. So I created flashcard objects that contain methods and variables including the dom element representing the flashcard on the...