put dymanic loading related kernel code and query kernel code into public/static

put dymanic loading related kernel code and query kernel code into
public/static.
everything in JS need be loaded at frontend from ruling com should be
placed here.
This commit is contained in:
Matthew Kaito Juyuan Fu committed 2011-10-21 14:11:41 +08:00
1 parent a0f1220b63
commit 0a6efeb0a2
4 files changed
+17 -11

No files matched your search

-11
View File
@@ -33,17 +33,6 @@
<div id="footer" class="footer">
This is the footer
</div>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script>
<script>
$.each($(".dymanic_load"),function(){
$(this).load($(this).attr("path"),
function(respText,textSta,XML){
if(textSta == 'error')
{$(this).html("Loading Failed");}
});
}
);
</script>
<!-- END example -->
</body>
+3
View File
@@ -76,6 +76,8 @@ module Parser
page.design.javascripts.each do |js|
res << "<script type='text/javascript' src='#{js.file.url}'></script>"
end
res << "<script type='text/javascript' src='/static/jquery.js'></script>"
res << "<script type='text/javascript' src='/static/kernel.js'></script>"
res
end
c.define_tag 'image' do |tag|
@@ -188,6 +190,7 @@ module Parser
page.design.javascripts.each do |js|
res << "<script type='text/javascript' src='#{js.file.url}'></script>"
end
res
end
c.define_tag 'layout_part' do |tag|