Good day,

I am doing on Java with Struts2 framework. The below is my html code :

<html:image alt="Calendar" src="/images/icon_calendar.gif" />
<img alt="Calendar" src="/images/icon_calendar.gif" />

The first line of my image is working fine, the image is show correctly in my web page. ()

However, the second line of my html is not working. It is showing broken image in my web page. ()

Would like to ask, what mistake in my code.

Kindly advise.

有帮助吗?

解决方案

Good day,

The problem is solved once I have post this question.

I have tried to solved it for few days.

The correct code should be as follow:

<html:image alt="Calendar" src="/images/icon_calendar.gif" />
<img alt="Calendar" src="images/icon_calendar.gif" />
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top