I'm having problems with IE6 and javascript applied to ajax content.
I'm not able to use any sort of javascript (plain or with jQuery) on the content that is retrieved with ajax.
I have my main html page that loads the Header content with ajax (for this task I'm using the jQuery .load() method)
Something like
<html>
<body>
<div id="header">
... here the content that comes from the ajax call...
(i.e. <div id="myText">myText loaded with ajax</div>)
...
Now I'm trying to add some events to this content. This is working fine in Firefox and Chrome but not in IE6. I tried with jQuery live(), plain javascript loaded inside the ajax content but nothing. IE doesn't like it. Do you have any workaround for this issue? Thanks
Update
the script I'm using is like this
$("#goButton").live("click", function(){
$search = $('#searchPhrase');
if ($search.val() == $search.attr('title')) {
$search.val('');
}
});
this is the content that is loaded with the Ajax call
<form id="s" action="/searchresults.jsp">
<input type="text" id="searchPhrase" title="Search" value="Search"/>
<input type="image" alt="Search this Website" src="/images/go_button.png" id="goButton"/>
</form>
anyway the rendered page is quite big but every jQuery or js is working fine in IE if I don't consider the ajax content.