Develop
2013.04.23 16:12
[js] 이미지 사이즈를 동적으로 조절..
조회 수 7474 댓글 0
IMG 태그 안에 삽입하여 해당 이미지 사이즈를 동적으로 조정
<html> <head> <title>image resize</title> <style> body,table,tr,td {font-size:9pt;} </style> <script> function img_resize(img){ var mywidth = 200; if( img.width > mywidth ){ r = mywidth / img.width; w = img.width * r; h = img.height * r; img.width = w; img.height = h; } } </script> </head> <body> <table border=0 cellpadding=0 cellspacing=0> <tr> <td><img src="test.jpg" border=0 onLoad="img_resize(this);"></td> </tr> </table> </body> </html>
-
[c] GD라이브러리 설치 테스트 소스
-
[c] 문자열 치환해주는 str_replace() 함수
-
[c] 숫자(int, Number)를 hex코드로 변환하는 소스
-
[c] 내가 만든 암호화 프로그램.. 좋아^^
-
[c] 암호화 알고리즘 DES 구현 ㅋㅋ
-
[c] 학교 건물 최단거리 찾는 웹 연동 프로그램
-
[js] 셀렉트박스(select)의 옵션(option) 동적으로 추가/제거
-
[js] 숫자만 입력하게 하는 자바스크립트
-
[c] 패킷 에널라이저 예제 소스(성안당)
-
[js] 수명체크 프로그램 ㅋㅋ
-
도메인 관련 솔루션 분석할 거.. ㅋㄷ
-
프로그래밍 소스 관련 사이트..