I am very new to javascript. I am creating a multilingual website. It contains rtl and ltr languages. I have two css for those to languages. When user change his language I want to load respective css file. Is it possible in this way ? If not suggest any alternative way.
1条回答 默认 最新
- donglv9116 2016-05-24 14:28关注
Is posible enable and disable css stylesheet with javascript. A example: http://plnkr.co/0exLXB
function del_style() { document.getElementById("styles").disabled=true; } function add_style() { document.getElementById("styles").disabled=false; }
I think you could adapt the code for your site
本回答被题主选为最佳回答 , 对您是否有帮助呢?解决 无用评论 打赏 举报