Developer forum

Forum » Templates » import external js file

import external js file


Reply
Hi,

How can I maintain the </script> after xslt transformation?

I am trying to import and external JS file in to the master template. I write:
<script type="text/javascript" src="..."></script> but after the transformatio i get:
<script type="text/javascript" src="..." />

I need to get it normal otherwise browsers will not use the external js file. Any ideas?
I can place a character between the script tag, but would rather know how to avoid that.

Best Regards,
Nuno

Replies

 
Reply
Insert <xsl:comment /> between the script tags... :-)
 
Reply
Hi,

I was using another workaround but this is a cleaner and better way. Thanks.

Best Regards,
Nuno

 

You must be logged in to post in the forum