[jQuery] $('#someDiv').html(argument);

[jQuery] $('#someDiv').html(argument);

The only difference appears to be that the test code is triggered by a
button whilst the "real" code is passed via an onmouseover event.
Anyone have any ideas on this?
<!----------------//------
andy matthews
web developer
certified advanced coldfusion programmer
ICGLink, Inc.
andy@icglink.com
615.370.1530 x737
--------------//--------->
-----Original Message-----
From: discuss-bounces@jquery.com [mailto:discuss-bounces@jquery.com]On
Behalf Of Andy Matthews
Sent: Friday, June 30, 2006 1:57 PM
To: jQuery Discussion.
Subject: Re: [jQuery] $('#someDiv').html(argument);
Weird!
I just did a test with this:
    function testing(s) {
        $('#control').html(s);
    }
<div id="control">this is the control DIV</div>

<input type="button" value="why do you hate me" onclick="testing('jquery?
Why do you hate me?');">
<input type="button" value="maybe you don't hate me!"
onclick="testing('wait...maybe you don\'t have me!');">
And it works just fine.
Now I wonder if there's something on the other page which is interfering
with jQuery (no I'm not using Prototype).
<!----------------//------
andy matthews
web developer
certified advanced coldfusion programmer
ICGLink, Inc.
andy@icglink.com
615.370.1530 x737
--------------//--------->
-----Original Message-----
From: discuss-bounces@jquery.com [mailto:discuss-bounces@jquery.com]On
Behalf Of Andy Matthews
Sent: Friday, June 30, 2006 1:41 PM
To: [jQuery]
Subject: [jQuery] $('#someDiv').html(argument);
I know this has been asked before, and I've looked over each of those
threads but can't seem to get a solid answer. So here goes:
I have this line of code which works as is. It accepts a string and puts
that string as the innerHTML of a div.
function changeMe(coords) {
    document.getElementById("playerCoords").innerHTML = name;
}
Based on reading the discuss forum, I've tried updating that line with these
lines, none of which work:
$('#playerCoords').html(coords);
// returns the error "$("#playerCoords") has no properties
and
$('#playerCoords').get(0).innerHTML = coords;
// returns the same error as above.
Am I doing something wrong? I've tested this in both IE and FF for the PC
and both do the same thing.
<!----------------//------
andy matthews
web developer
certified advanced coldfusion programmer
ICGLink, Inc.
andy@icglink.com
615.370.1530 x737
--------------//--------->
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/
















































































    • Topic Participants

    • andy