跟着老师的代码写,然后就提示异常:java.lang.IllegalArgumentException: Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required,在网上搜了相关内容之后,在启动类上加了@ImportResource(locations = "application.properties")注解后,启动报错变成:org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 1 in XML document from class path resource [application.properties] is invalid; nested exception is org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 1; 前言中不允许有内容。在网上搜索了相关答案,采用了各种改编码改内容的方式,均无效,但把mybatis的注解@MapperScan(basePackages = "com.imooc.mapper")删除后就可以正常启动.....真不知道怎么办了,求助!