Gif图像在html页面中不工作?

Gif图像在html页面中不工作?,html,image,gif,thymeleaf,Html,Image,Gif,Thymeleaf,在html中,图像和gif的设置方式相同。所以我在百里香中也用同样的方法 在thymeleaf中,图像设置为 <img th:attr="src=@{${ball.png}} , title=#{background}, alt=#{background}" style="width: 150px; height: 150px;" /> 与设置为的gif图像相同 <img th:attr="src=@{${run.gif}} , title=#{background},

在html中,图像和gif的设置方式相同。所以我在百里香中也用同样的方法

在thymeleaf中,图像设置为

 <img th:attr="src=@{${ball.png}} , title=#{background}, alt=#{background}" style="width: 150px; height: 150px;" />

与设置为的gif图像相同

<img th:attr="src=@{${run.gif}} , title=#{background}, alt=#{background}" style="width: 150px; height: 150px;" />

图像将显示在那里,但gif图像不会显示在那里

我不知道为什么会这样


如果你知道答案,请在这里分享。

{${run.gif}
尝试用属性
run
的属性
gif
重写URL,我怀疑这是真的

如果要参照与上下文相关的图像,则应执行
@{/run.gif}

文件: