Guys,
I have a code snippet which I would like to improve and optimize and was
hoping to get some help. The form has two chained selects so when you
select an option on the first one, the second gets populated via an Ajax
call. The code is based off of Remy Sharp's chained select article and
That did the trick Karl. Thanks for your help! :D
Rey
Karl Rudd wrote:
As far as I know you can't use anything but a simple number with the
":eq()" selector.
You could rewrite the code as:
$( "select#cert_id option:eq(" + (i > 1?1:0) + ")" ).attr(
"selected", true );
Note how the terna
I wrote a simple little bit of code to set focus on the first visible
form element in a form
$('#tab0 table tr :input:visible:first').focus();
It works great in Firefox but IE throws the error
" 'this.parentNode.borderCss.on' is null or not an object "
I also tried
$('#tab0 input:eq(0)').fo
Instead of:
$( '#article p' )
You can use:
$( '#article > *' )
Which will get all the immediate children (but not grandchildren) of
#article. Append ":gt()" and ":eq()" to your hearts content.
Karl Rudd
On Tue, Apr 15, 2008 at 8:00 AM, Brian Talbot <[EMAIL PROTECTED]> wrote:
>
> Hi
I've been looking for a solution like this, but that will work with
any type of form input.
The code I've been using is below (where form-id is the ID of the
containing form)
It works great in Firefox but IE throws the error
'this.parentNode.borderCss.on' is null or not an object
I tried your ex
As far as I know you can't use anything but a simple number with the
":eq()" selector.
You could rewrite the code as:
$( "select#cert_id option:eq(" + (i > 1?1:0) + ")" ).attr(
"selected", true );
Note how the ternary operator is "outside" the selector string, it's
just used to produce a 1
Guys,
I wanted to set an option in a select element to "selected". The options
are being created on the fly. The rules are simple. If there's more than
one option, then set the second option to "selected". Otherwise, set the
first option to "selected". I tried to use a ternary operator but it
sorry fixed this - damn suhosin :(
On Apr 15, 12:58 am, Equand <[EMAIL PROTECTED]> wrote:
> Hi guys, i don't understand if it is a problem on my server or with
> ajax at all
> I'm sending POST data to server through ajax in jquery but the server
> reports no data received (php $_POST['data'] is e
Hi guys, i don't understand if it is a problem on my server or with
ajax at all
I'm sending POST data to server through ajax in jquery but the server
reports no data received (php $_POST['data'] is empty). However it
occurs only when the size of the data is over 50kb or so...
what can it be?
I'd like to know when a Javascript error occurs, and I'd like to be
sent an email when this happens. I'm not sure if or how jQuery can
help here, but I have a feeling that it can. I can write the server
side script to email the error, that's not a problem. But, I'm not
sure how to capture the J
just location.hash.slice(1);
--
Ariel Flesler
http://flesler.blogspot.com
On 14 abr, 14:01, "Scott Trudeau" <[EMAIL PROTECTED]> wrote:
> Not sure if there's a "jQuery way" ... this:
>
> var hashAnchor = self.document.location.hash.substring(1);
>
> Has worked for me...
>
> Scott
>
> On Mon, Apr
Hi All,
I was wondering if someone could help refine a content toggling
solution that I have now. As of now, the demo page below takes the
first 3 elements within a parent with a specific ID and
hides the remainder of the paragraphs in this parent by placing
them in a newly created and then c
Hi All,
I was wondering if anyone had any insight into an issue I'm having
when using JQuery to show/hide a series of elements on a page. I
currently have a set of comments (to be placed in a larger page) and
along with each comment a form is needed to allow users to flag an
individual comment.
Jacky schrieb:
I'm thinking if I can do this:
rules:{
planFromDate: {dateRange:'plan'}, planToDate: {dateRange:'plan'}
actualFromDate: {dateRange:'actual'}, actualToDate:
{dateRange:'actual'}
}
groups: {
dateRange: "planFromDate planToDate actualFromDate actualToDate"
}
$.validat
dineshv schrieb:
Say, there are 10,000 items in a server database and we set MAX=100.
Assume the user entry Q="the" results in 250 entries. The server
sends all 250 entries to the browser but Autocomplete (AC) will only
use the first MAX=100 entries. The 100 entries are displayed in a
scroll b
I have an iframe in my page, and I need to get the scrollTop, or the
amount the iframe is scrolled vertically, but the Dimensions plugin,
and everything else I've found, just don't work. This script needs to
be on my site, then when the iframe is scrolled I need to know how far
it was scrolled.
A
Say, there are 10,000 items in a server database and we set MAX=100.
Assume the user entry Q="the" results in 250 entries. The server
sends all 250 entries to the browser but Autocomplete (AC) will only
use the first MAX=100 entries. The 100 entries are displayed in a
scroll bar.
If the user sc
Cool - thanks kadda!
On Apr 12, 4:06 pm, kadda <[EMAIL PROTECTED]> wrote:
> On Apr 11, 3:35 am, DragonI <[EMAIL PROTECTED]> wrote:
>
>
>
> > Hi,
>
> > I'm having a problem disabling the cancel button. Maybe it's just
> > me ;)
>
> > code says: //required: false, // disables the 'cancel' button so
Not sure if there's a "jQuery way" ... this:
var hashAnchor = self.document.location.hash.substring(1);
Has worked for me...
Scott
On Mon, Apr 14, 2008 at 12:48 PM, [EMAIL PROTECTED] <
[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> Not sure if this is the right terminology, but what is the JQuery way
Hi,
Not sure if this is the right terminology, but what is the JQuery way
to detect if, and then store in a variable, the URL's hash value,
meaning anything coming after the "#"?
Thanks, - Dave
var id = $("div.policy:visible").attr("id");
- jake
On Mon, Apr 14, 2008 at 11:57 AM, [EMAIL PROTECTED]
<[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I have a number of DIVS of class = "policy" on my page. At any one
> time, only one will be displayed, that is, have the CSS "display"
> attribute s
Hi,
I have a number of DIVS of class = "policy" on my page. At any one
time, only one will be displayed, that is, have the CSS "display"
attribute set to "block". How can I write a JQuery expression to find
the ID of such a DIV?
Thanks, - Dave
Hi,
I would like to use the plugin nicejforms (http://www.lexcat.ro/nicejforms/),
this one works with only 1 form on the page.
But i want to use it with several forms on the page, how can i fix it?
An example with 2 forms => http://www.hybridbears.com/nicejforms/
thanks
--
Alexandre BOCA
[EMA
24 matches
Mail list logo