假如我們的框架是topframe,leftframe,mainframe的
1,我們知道這個框架一共有四個頁面,例如為all.rhtml,left.rhtml,top.rhtml,main.rhtml
2,把all.rhtml放在rails的layouts下
3,把all.rhtml的src要這樣寫
<frameset rows="80,*" cols="*" frameborder="yes" border="1" framespacing="1" bordercolor="#666666">
<frame src="/message/top" name="topFrame" scrolling="No" noresize="noresize" id="topFrame" />
<frameset rows="*" cols="160,*" framespacing="0" frameborder="yes" border="1" bordercolor="#666666">
<frame src="/message/left" name="leftFrame" scrolling="No" noresize="noresize" id="leftFrame" />
<frame src="/message/main" name="mainFrame" id="mainFrame" />
</frameset>
</frameset>
src="/message/left"就對應著views下message下的left.rhtml
4,把left.rhtml,top.rhtml,main.rhtml都放在views的message下(對應的action是message_controller.rb)下
link:
http://lists.rubyonrails.org/pipermail/rails/2006-June/045371.html
posted on 2009-03-13 19:20
fl1429 閱讀(646)
評論(0) 編輯 收藏 所屬分類:
Rails