0


通配符的匹配很全面, 但无法找到元素 ‘tx:advice‘ 的声明

在这里插入图片描述

💗wei_shuo的个人主页

💫wei_shuo的学习社区

🌐Hello World !


通配符的匹配很全面, 但无法找到元素 ‘tx:advice’ 的声明

错误原因:

xmlns和xsi:schemaLocation未书写约束或者书写错误

在这里插入图片描述

  • 正确书写
<beansxmlns:tx="http://www.springframework.org/schema/tx"xsi:schemaLocation="
       http://www.springframework.org/schema/tx
       http://www.springframework.org/schema/tx/spring-tx.xsd
       "></beans>

xmlns

xmlns是xml namespace的缩写,也就是XML命名空间;xml命名空间指定xml里有哪些:节点、子节点、属性,名字,值,默认值,规范xml

xmlns:tx="http://www.springframework.org/schema/tx"

xsi:schemaLocation

xsi:schemaLocation:实例中引用模式文档;XML Schema提供了两个在实例文档中使用的特殊属性,用于指出模式文档的位置:

xsi:schemaLocation:用于声明了目标名称空间的模式文档

xsi:noNamespaceSchemaLocation:用于没有目标名称空间的模式文档


🌼 结语:创作不易,如果觉得博主的文章赏心悦目,还请——

点赞

👍

收藏

⭐️

评论

📝

冲冲冲

🤞


在这里插入图片描述

标签: spring java 后端

本文转载自: https://blog.csdn.net/weixin_62765017/article/details/129516627
版权归原作者 wei_shuo 所有, 如有侵权,请联系我们删除。

“通配符的匹配很全面, 但无法找到元素 ‘tx:advice‘ 的声明”的评论:

还没有评论