我想在我的Jade模板中使用Macromedia Flash,Jade是否支持Flash?
答案 0 :(得分:1)
确实如此:-) Jade只是一种HTML伪语言,所以输出的任何内容都是HTML。所有这一切 - 你真的应该使用像swfobject这样的东西来渲染你的flash标签:
http://code.google.com/p/swfobject/
但是jade的基本概念是使用Jade语法而不是HTML。所以不要这样:
<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' width='300' height='300' id='player1' name='player1'>
<param name='movie' value='player.swf'>
<param name='allowfullscreen' value='true'>
<param name='allowscriptaccess' value='always'>
<param name='flashvars' value='file=playlist.xml'>
<embed id='player1'
name='player1'
src='player.swf'
width='300'
height='300'
allowscriptaccess='always'
allowfullscreen='true'
flashvars="file=playlist.xml"
/>
</object>
你会输入这样的东西:
object(classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000', width='300', height='300', id='player1', name='player1')
param(name='movie', value='player.swf')
param(name='allowfullscreen', value='true')
embed(id='player1',
name='player1',
src='player.swf'
width='300',
height='300',
allowscriptaccess='always',
allowfullscreen='true',
flashvars="file=playlist.xml")
我希望这有助于为您清除一些事情。快乐的编码!