On 03/03/07, Brad Perkins <[EMAIL PROTECTED]> wrote:
> Josh,
>
> After further testing this doesn't appear to work with IE6 (or Safari).
>
> Your technique for binding the radio buttons works in the main page,
> but it appears that any javascript returned via the ajax call is
> ignored by IE6 (and
Brad Perkins schrieb:
> Thanks for the tip. That looks promising.
>
> Brad
If you use load() or $.ajax with the dataType option set to 'html',
javascripts will be evaluated.
$('#target').load('from/here.php');
$.ajax({
url: 'from/here.php',
dataType: 'html'
});
For more information
Thanks for the tip. That looks promising.
Brad
On 3/2/07, Daemach <[EMAIL PROTECTED]> wrote:
>
> You can do this with the taconite plugin, which allows you to pass HTML back
> from the server and insert it into another element on the page. After
> you've done all your updates, if you include an
You can do this with the taconite plugin, which allows you to pass HTML back
from the server and insert it into another element on the page. After
you've done all your updates, if you include an block at the end you
can put your script there rebind everything.
http://www.malsup.com/jquery/taco
re mostly in Europe and so are
probably soundly asleep. ;0)
-- Josh
- Original Message -
From: "Brad Perkins" <[EMAIL PROTECTED]>
To: "jQuery Discussion."
Sent: Friday, March 02, 2007 4:02 PM
Subject: Re: [jQuery] Bind event to radio button group
> Josh,
>
Josh,
After further testing this doesn't appear to work with IE6 (or Safari).
Your technique for binding the radio buttons works in the main page,
but it appears that any javascript returned via the ajax call is
ignored by IE6 (and also by Safari).
BTW, my AJAX stuff is really AJAH (returning HT
> If I return your examples with the AJAX content the bind works. Is
> there a better way to do that?
AFAIK that's the only way to do it, if your radio buttons only appear after
an AJAX call. But, I am a noob myself, so don't take my word for it!
-- Josh
_
Josh and Sean,
Thanks for the help. Both solutions appear to work.
Part of my problem was that I was initially performing the bind in
$(document).ready(...). At first neither of your suggestions worked.
Then I realized that the radio buttons I want to bind to are in a
table that appear in the pag
Code for your example (just tested):
$("[EMAIL PROTECTED]").each(
// For each button, run this code. The "i" is the loop
iteration index on
the current element
function( i ){
// Bind the onclick event to alert the iteration index
v
Brad,
Looks like you need to use the .each function to iterate through each radio
button.
Here's some demo code:
http://www.bennadel.com/blog/534-The-Beauty-Of-The-jQuery-Each-Method.htm
Docs:
http://jquery.bassistance.de/api-browser/#eachFunction
SEAN O
http://www.sean-o.com/
Br
ing the syntax above.
-- Josh
- Original Message -
From: "Brad Perkins" <[EMAIL PROTECTED]>
To:
Sent: Friday, March 02, 2007 1:30 PM
Subject: [jQuery] Bind event to radio button group
> I'm new to jQuery. I'm trying to bind a function to a group of radio
> bu
I'm new to jQuery. I'm trying to bind a function to a group of radio buttons.
For example,
$("[EMAIL PROTECTED]").bind("click",
function() {
alert ('radio button clicked');
}
);
should run the function anytime a radio button named 'rb' is clicked
but isn't working.
12 matches
Mail list logo