freemarker中include與import的區別

  在inc1.ftl與inc2.ftl中的內容分別是: <#assign username="劉德華">與<#assign username="張學友"> 接着我在hello.ftl模版中用include將inc1.ftl包含進來 <#include "/inc/inc1.ftl"> ${username} 此刻獲取的結果是:劉德華   接着我們在hello.ftl用include將inc1.f
相關文章
相關標籤/搜索