extjs 加载

#在application_helper.rb中
  def include_ext_js
    ext_js =""
    ext_js << stylesheet_link_tag("/ext/resources/css/ext-all.css")
    ext_js << javascript_include_tag("/ext/adapter/ext/ext-base.js")
    ext_js << javascript_include_tag("/ext/ext-all.js")
    ext_js
  end

 以后用到就不用重复加载了

#layouts/application.rhtml
<head>....
<%=include_ext_js%>
....
</head>

 

 

你可能感兴趣的:(JavaScript,css,ext)