hi,
ODS generates the following html for my vbar chart with goptions device=java:
<script language="javascript" type="text/javascript">
<!--
document.writeln("<OBJECT");
document.writeln('style=" width: 640px; height: 480px; background-color: #FDFBF3; border-width: 0px;"');
document.writeln("ALIGN=\"baseline\" class=\"Graph\"");
if (_ie == true) {
document.writeln("CLASSID=\"clsid:8AD9C840-044E-11D1-B3E9-00805F499D93\"");
if (_ie64 == true) {
document.writeln("CODEBASE=\"http://javadl.sun.com/webapps/download/AutoDL?BundleId=47155#Version=1,6,0,0\"");
}
else {
document.writeln("CODEBASE=\"http://java.sun.com/update/1.6.0/jinstall-6u24-windows-i586.cab#Version=1,6,0,0\"");
}
}
else {
document.writeln("CODEBASE=\"http://javadl.sun.com/webapps/download/GetFile/1.6.0_24-b07/windows-i586/xpiinstall.exe\"");
document.writeln("TYPE=\"application/x-java-applet;version=1.6\"");
}
document.writeln(">");
//-->
the browser translates this to:
<object style="width: 640px; height: 480px; background-color: rgb(253, 251, 243); border-width: 0px;" class="Graph" codebase="http://javadl.sun.com/webapps/download/GetFile/1.6.0_24-b07/windows-i586/xpiinstall.exe" type="application/x-java-applet;version=1.6" align="bottom">
The document.writeln's are causing me problems since they don't get executed when inserted into a div by my ajax callback function.
In sas93 I found the code that generates this <object> tag in the phtml tagset, so I can change this to static html.
in sas913 I can't find it there, nor anywhere else. can anyone tell where this code comes from in sas913?
thanks, Bart
Dutch technical support pointed me to an updated ODS tagset (grphtags.tpl) which contains the document.writeln functions, on http://support.sas.com/kb/17/502.html
I removed the document.writeln functions and now the java graph works when inserted into a div by my ajax callback function.
The reason that document.writeln is used is to generate different html for Internet Explorer and other browsers.
My client uses Internet Explorer so my updated tagset generates html for IE only now.
Hi:
I think your best bet is working with SAS Tech Support on this one. I'm not sure what it is you want -- HTML without any <OBJECT> tags?? Or graphs without any interactivity? Have you tried using the JAVAIMG device??? It is very likely that between 9.1.3 and 9.3 changes were made in how the various graphing techniques interact with ODS. The big changes in FONTS and STYLES came with 9.2 and the big change with ODS GRAPHICS came in 9.3.
I figure you have come across this already:
cynthia
i want ODS to send the <object> string itself to the browser instead of sending document.writeln statements to the browser and having the browser write that out to an <object> string, because the browser will not do that if it is inserted dynamically into a <div> element.
i will ask tech support, thanks
Dutch technical support pointed me to an updated ODS tagset (grphtags.tpl) which contains the document.writeln functions, on http://support.sas.com/kb/17/502.html
I removed the document.writeln functions and now the java graph works when inserted into a div by my ajax callback function.
The reason that document.writeln is used is to generate different html for Internet Explorer and other browsers.
My client uses Internet Explorer so my updated tagset generates html for IE only now.
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.