»
EnglishFrenchVietnamese

Print - CSS Stylesheet Importer by DOM - JavaScriptBank.com

Full version: jsB@nk » Snippet » CSS Stylesheet Importer by DOM
URL: http://www.javascriptbank.com/css-stylesheet-importer-by-dom.html

CSS Stylesheet Importer by DOM © JavaScriptBank.comLet use this simple JavaScript if you want to use the DOM to include a cascading style sheet. Very simple to implement and customize.

Full version: jsB@nk » Snippet » CSS Stylesheet Importer by DOM
URL: http://www.javascriptbank.com/css-stylesheet-importer-by-dom.html



JavaScript
<script type="text/javascript">// Created by: Benoit Asselin | http://www.ab-d.fr/function includeCSS(p_file) {var v_css  = document.createElement('link');v_css.rel = 'stylesheet'v_css.type = 'text/css';v_css.href = p_file;document.getElementsByTagName('head')[0].appendChild(v_css);}</script>