我有一个问题:
<iframe id="iframe1" src='http://stockcharts.com/h-sc/ui?s=MT&p=D&yr=2&mn=0&dy=0&id=p43321191731' width="300px" height="300px"></iframe>
在 Lift 网络框架 (Scala) 版本中。我得到:
Message: java.util.NoSuchElementException
scala.RandomAccessSeq$$anon$13.next(RandomAccessSeq.scala:165)
scala.xml.parsing.MarkupParser$class.normalizeAttributeValue(MarkupParser.scala:1191)
结果是 iframe src 属性中的问号 ?
导致了这一点。
我该怎么做才能快速解决这个问题?
最佳答案
http://www.mail-archive.com/liftweb@googlegroups.com/msg08961.html
问题是&号,需要转义
<iframe id="iframe1" src='http://stockcharts.com/h-sc/ui?s=MT&p=D&yr=2&mn=0&dy=0&id=p43321191731' widt h="300px" height="300px"></iframe>
关于xhtml - Scala xhtml 属性因问号而中断,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2888632/