faqts : Computers : Programming : Languages : JavaScript : Images

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

8 of 19 people (42%) answered Yes
Recently 6 of 10 people (60%) answered Yes

Entry

How do I set the border color on an HTML image?

Dec 19th, 2005 02:52
Trung Ha Pham, Yves Valiquette,


You can use CSS to set border images

<img src="http://www.faqts.com/images/faqts.gif" style="border:1px solid 
red">

wana use script?

<html>
<body>
<img src="http://www.faqts.com/images/faqts.gif" id="img1">
<script>
document.getElementById('img1').style.border="1px solid #BBEEBB";
</script>
</body>
</html>