var name = "Bob", time = "today"; var info=`Hello ${name}, how are you ${time}?` alert(info); 注意,使用的是反引号,而不是通常的单引号