How to localize a simple HTML website page in my case?

前端 未结 11 634
没有蜡笔的小新
没有蜡笔的小新 2020-12-01 04:34

I am NOT developing any web service application which contain client side and backend server side (like java EE application or Ruby on Rai

11条回答
  •  感情败类
    2020-12-01 04:59

    You can use the standard HTML lang attribute:

    ScaleMaßstab
    

    And then you can hide and show the matching elements:

    function select_language(language) {
        $("[lang]").each(function () {
            if ($(this).attr("lang") == language)
                $(this).show();
            else
                $(this).hide();
        });
    }
    

    I use a simple selection:

    
    

提交回复
热议问题