Struts Image tag!

Hi experts, how to change this html image tag:

<td background="images/Line_Vertical_dotted.gif" width="1"></td>

into a struts image tag??

Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Manikandan ThiagarajanSenior consultantCommented:
KirtipurItagolAuthor Commented:
very good article but doesn't solve my question though...
i've an html image tag like this :

<IMG height=4 src="image/spacer">
I can use a struts tag and change the above into:
<html:img height=4 srcKey="image.spacer"/>

There's no problem with that.
But here's another scenario:
here's my html image tag-----><td  background="images/Line_Vertical_dotted.gif" width="1"></td>
I want to change that into <html:img ...................../>
Any clue?

I want to change that into <html:img ...................../>
Any clue?

Do you mean you no longer want the td background to be the image?
OWASP: Forgery and Phishing

Learn the techniques to avoid forgery and phishing attacks and the types of attacks an application or network may face.

KirtipurItagolAuthor Commented:
I want the functionality to be unchanged ....thanks
You can use a style tag and css, which you should anyway in fact, as presentation should not be conflated with html tags
KirtipurItagolAuthor Commented:
May be I'm too confusing here.....So, there's no substitution for background attribute using struts tag?? forexample, i can use srcKey for src....
The html:img tag always renders an HTML <img> tag. The tag that you'd be using would have to be html:td which does not exist. You will just have to put the absolute or relative path to the image in the <td> tag or, as was already suggested, use a style sheet. I'd go with the style.
KirtipurItagolAuthor Commented:
Or else I can just leave it like that, correct??
It's better not to leave it like that, for the reason i gave

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
KirtipurItagolAuthor Commented:
basically the html guy screw the whole html page....and now he doesn't exist in the company...and I dont' have much skill on CSS....I want to replace all the html tags into struts tags...CEHJ can you tell me the right way to initiate??
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Java EE

From novice to tech pro — start learning today.