I am dynamically creating a large stylesheet as a string and desiring to injecting it into an iframe. Initially I approached it like this:
var css = '.newstyle { margin: 20px; } .newstyle2 { margin: 20px; }';
$('iframe').contents().find('head').append('<style type="text/css">'+css+'</style>');
Unfortunately, IE7 does not like this method. I'm not sure how else to approach this injection. Is there a cross-browser solution that will enable me to inject a mass of CSS from a string?