There are other issues with the way you're doing it too. You're loading a full HTML page into a <span>. <span>'s should be used for inline content only. Use a <div> when you're using it to contain block elements.
You shouldn't be putting a full page into the DOM. You should only be using document fragments (no <html>, <body>, etc). As for the CSS, you should have one stylesheet for your entire site and just put all the CSS into that. The code you're using is pretty dated. Copying old example code off the web is generally a bad idea. There's no reason to test for getElementById, all browsers have that. You'd be better off using a library like jQuery for both DOM manipulation and your AJAX calls. -- Dan DeFelippi +1.585.466.4747 http://driverdan.com Follow me on Twitter at @ExpertDan <http://twitter.com/ExpertDan> On Thursday, June 21, 2012 5:15:43 PM UTC-5, Eric Leversen wrote: > > Well of course IE 7/8 doesn't. What was I thinking???? ;-> > With that info, I've got it working. > > Thanks a million, Patrick. > > > > Eric Leversen > [email protected] > > > > > On Jun 21, 2012, at 4:56 PM, Patrick Fox wrote: > > Eric - > > IE7/8 disregards <style> blocks in Ajax content. A quick search on SO: > > http://stackoverflow.com/questions/3134164/ie-doesnt-apply-css-loaded-through-ajax > > > A better approach would be to load an external stylesheet in the initial > page load. > > Regards, > Patrick > > On Thu, Jun 21, 2012 at 12:27 PM, Eric Leversen < > [email protected]> wrote: > >> I've encountering an issue with IE7/8 where CSS does not seem to work in >> pages that are called via AJAX. >> IE9 seems to work, as do Firefox, Safari, and Chrome. >> >> Page with working CSS in IE8: >> http://ftw-dev.org/temp/ie_rollover_test.html >> >> Same page loaded via AJAX. Note that the CSS does not seem to be applied: >> http://ftw-dev.org/temp/ie_ajax_rollover_test.html >> >> Questions: >> -Is there a known workaround for this? >> -Is there a better way to have a label appear over a link on rollover and >> input text boxes on focus? >> >> Thanks! >> >> Eric Leversen >> http://farmtowork.org/ >> >> >> >> Regards, >> >> Eric Leversen >> [email protected] >> >> >> >> >> -- >> Our Web site: http://www.RefreshAustin.org/ >> >> You received this message because you are subscribed to the Google Groups >> "Refresh Austin" group. >> >> [ Posting ] >> To post to this group, send email to [email protected] >> Job-related postings should follow http://tr.im/refreshaustinjobspolicy >> We do not accept job posts from recruiters. >> >> [ Unsubscribe ] >> To unsubscribe from this group, send email to >> [email protected] >> >> [ More Info ] >> For more options, visit this group at >> http://groups.google.com/group/Refresh-Austin >> > > > > -- > ---------------------- > Patrick J. Fox | Presentation Layer Architect Austin, TX > > -- > Our Web site: http://www.RefreshAustin.org/ > > You received this message because you are subscribed to the Google Groups > "Refresh Austin" group. > > [ Posting ] > To post to this group, send email to [email protected] > Job-related postings should follow http://tr.im/refreshaustinjobspolicy > We do not accept job posts from recruiters. > > [ Unsubscribe ] > To unsubscribe from this group, send email to > [email protected] > > [ More Info ] > For more options, visit this group at > http://groups.google.com/group/Refresh-Austin > > > -- Our Web site: http://www.RefreshAustin.org/ You received this message because you are subscribed to the Google Groups "Refresh Austin" group. [ Posting ] To post to this group, send email to [email protected] Job-related postings should follow http://tr.im/refreshaustinjobspolicy We do not accept job posts from recruiters. [ Unsubscribe ] To unsubscribe from this group, send email to [email protected] [ More Info ] For more options, visit this group at http://groups.google.com/group/Refresh-Austin
