unterminated string literal

前端 未结 9 1329
轮回少年
轮回少年 2020-11-30 06:07

The following code:

var str= \"English Comprehension<\\/strong>
                    
                    
9条回答
  •  渐次进展
    2020-11-30 06:36

    Remove the newlines, it will work. GOTCHA to keep in mind ;) See it simple works all fine here without newlines: http://jsfiddle.net/87dYh/

    var str= "English Comprehension<\/strong>
    • Synonyms/Antonyms/Word Meaning (Vocabulary)<\/li>
    • Complete the Sentence (Grammar)<\/li>
    • Spot error/Correct sentence (Grammar/sentence construction)<\/li>
    • Sentence Ordering (Comprehension skills)<\/li>
    • Questions based on passage (Comprehension skills)<\/li> <\/ul> "; alert(str);

提交回复
热议问题