Freewheel

<script>

function DWFLinksToThumbnails() {

// Define URL for interactive Freewheel DWF Viewer web service
renderDWF='http://freewheel.autodesk.com/dwf_s.aspx\?dwf=';

// Specify thumbnail width/height
thWidth = '400';
thHeight = '400';

// Define URL for Freewheel DWF to PNG service - this is used to dynamically render DWF links as PNG images
th1='http://freewheel.autodesk.com/dwfImage.aspx\?width='+thWidth+'\&height='+thHeight+'\&path=';

// Iterate through all hyperlinks in the document

for(i=0;i x=document.links[i];

// Filter URLs - check if links are to DWF files
if(x.href.match(/\.dwf$|\.DWF$/)&&x.href.match(/^http:\/\//)&&!x.href.match(/\=http|google\.com/))

// Modify the orig link urls to be Freewheel enabled urls with orig dwf url used as parameter on the DWF to PNG webservice url and the interactive Freewheel viewing web service.
// Use the browser DOM to modify the original content of the DWF hyperlinks

{x.title='Click to view: '+x.href;x.innerHTML=x.innerHTML+'
';
g=renderDWF+x.href;
x.href=g;
x.target = "_blank";
}
}
}

// Run the DWFit Freewheel javascriptlet
// NOTE: This function call should be placed at the very bottom of the HTML code, just above the </Body> tag
DWFLinksToThumbnails();
</script>

Comments