검색결과 리스트
프로그램/- Script에 해당되는 글 7건
- 2011.10.11 Strong Password[강력한 암호]
- 2011.10.11 Facebook LikeBox
- 2011.09.23 로컬 스토리지
- 2011.08.03 [Jquery]영역의 높이 너비 값 구하기
- 2011.08.03 글자수 체크
- 2011.07.05 아이프레임 리사이징 & 뒤로가기잠금
- 2011.03.30 Base64 인코딩, 디코딩 변환
글
Password:
- Weak
- Medium
- Strong
$.fn.passwordStrength = function( options ){ return this.each(function(){ var that = this;that.opts = {}; that.opts = $.extend({}, $.fn.passwordStrength.defaults, options); that.div = $(that.opts.targetDiv); that.defaultClass = that.div.attr('class'); that.percents = (that.opts.classes.length) ? 100 / that.opts.classes.length : 100; v = $(this) .keyup(function(){ if( typeof el == "undefined" ) this.el = $(this); var s = getPasswordStrength (this.value); var p = this.percents; var t = Math.floor( s / p ); if( 100 <= s ) t = this.opts.classes.length - 1; this.div .removeAttr('class') .addClass( this.defaultClass ) .addClass( this.opts.classes[ t ] ); }) # Removed generate password button creation }); function getPasswordStrength(H){ var D=(H.length); # Added below to make all passwords less than 4 characters show as weak if (D<4) { D=0 } if(D>5){ D=5 } var F=H.replace(/[0-9]/g,""); var G=(H.length-F.length); if(G>3){G=3} var A=H.replace(/\W/g,""); var C=(H.length-A.length); if(C>3){C=3} var B=H.replace(/[A-Z]/g,""); var I=(H.length-B.length); if(I>3){I=3} var E=((D*10)-20)+(G*10)+(C*15)+(I*10); if(E<0){E=0} if(E>100){E=100} return E } # Removed generate password function }; $(document) .ready(function(){ $('input[name="password2"]').passwordStrength({targetDiv: '#iSM',classes : Array('weak','medium','strong')}); });
Jquery 강력한 암호
'프로그램 > - Script' 카테고리의 다른 글
Facebook LikeBox (0) | 2011.10.11 |
---|---|
로컬 스토리지 (0) | 2011.09.23 |
[Jquery]영역의 높이 너비 값 구하기 (0) | 2011.08.03 |
글자수 체크 (0) | 2011.08.03 |
아이프레임 리사이징 & 뒤로가기잠금 (0) | 2011.07.05 |
글
소스코드
<div id="fb-root"></div><script>(function(d, s, id) {var js, fjs = d.getElementsByTagName(s)[0];if (d.getElementById(id)) {return;}js = d.createElement(s); js.id = id;js.src = "//connect.facebook.net/ko_KR/all.js#xfbml=1";fjs.parentNode.insertBefore(js, fjs);}(document, 'script', 'facebook-jssdk'));</script>
<div class="fb-like" data-href="좋아요컨텐츠 링크등록" data-send="false" data-layout="button_count" data-width="450" data-show-faces="true" data-font="arial"></div>
기타 설정
페이스북에서 보여지는 좋아요 타이틀
<meta name="title" contelt="좋아요 타이틀" />
페이스북에서 보여지는 좋아요 요약글
<meta name="description" content="요약글 솰라솰라~" />
페이스북에서 보여지는 좋아요 대표이미지
<like rel="image_src" href="이미지경로" />
http://developers.facebook.com/docs/reference/plugins/like-box/
'프로그램 > - Script' 카테고리의 다른 글
Strong Password[강력한 암호] (0) | 2011.10.11 |
---|---|
로컬 스토리지 (0) | 2011.09.23 |
[Jquery]영역의 높이 너비 값 구하기 (0) | 2011.08.03 |
글자수 체크 (0) | 2011.08.03 |
아이프레임 리사이징 & 뒤로가기잠금 (0) | 2011.07.05 |
설정
트랙백
댓글
글
/* 스토리지 출력 */
/* 스토리지 삭제 */
/* 스토리지 모든 데이타 삭제 */
'프로그램 > - Script' 카테고리의 다른 글
Strong Password[강력한 암호] (0) | 2011.10.11 |
---|---|
Facebook LikeBox (0) | 2011.10.11 |
[Jquery]영역의 높이 너비 값 구하기 (0) | 2011.08.03 |
글자수 체크 (0) | 2011.08.03 |
아이프레임 리사이징 & 뒤로가기잠금 (0) | 2011.07.05 |
설정
트랙백
댓글
글
<html>
<head>
<title></title>
<style type="text/css">
#div1{
background:yellow;
border:0px;
padding:50px 50px 50px 50px;
width:400px;
height:400px;
}
#div2{
margin: 10 10 10 10;
background:red;
border:0px;
padding:0px;
width:200px;
height:200px;
}
</style>
<script type="text/javascript" src="/Js/jquery-1.4.2.min.js" />
<script type="text/javascript">
$(document).ready(function(){
$("#btn").click(function(){
var element = $("#div2");
alert("높이 : "+element.height());
alert("너비 : "+element.width());
alert("높이 : "+element.outerHeight());
alert("너비 : "+element.outerWidth());
alert("마진포함높이 : "+element.outerHeight(true));
alert("마진포함너비 : "+element.outerWidth(true));
});
});
</script>
</head>
<body>
<button id="btn">Click</button>
<div id="div1">
<div id="div2"><div>
</div>
</body>
</html>
'프로그램 > - Script' 카테고리의 다른 글
Facebook LikeBox (0) | 2011.10.11 |
---|---|
로컬 스토리지 (0) | 2011.09.23 |
글자수 체크 (0) | 2011.08.03 |
아이프레임 리사이징 & 뒤로가기잠금 (0) | 2011.07.05 |
Base64 인코딩, 디코딩 변환 (0) | 2011.03.30 |
설정
트랙백
댓글
글
'프로그램 > - Script' 카테고리의 다른 글
Facebook LikeBox (0) | 2011.10.11 |
---|---|
로컬 스토리지 (0) | 2011.09.23 |
[Jquery]영역의 높이 너비 값 구하기 (0) | 2011.08.03 |
아이프레임 리사이징 & 뒤로가기잠금 (0) | 2011.07.05 |
Base64 인코딩, 디코딩 변환 (0) | 2011.03.30 |
설정
트랙백
댓글
글
1. 방법
<iframe src="/Iframe/iframe.aspx" width="100%" height="100%" scrolling="no" id="contentFrame" name="contentFrame" frameborder="0" marginheight="0" marginwidth="0"></iframe>
2.방법
//사용Page
<iframe src="아이프레임.html" id="iframe1100" frameborder="0" scrolling="no" width="100%" />
//아이프레임.html 아이프레임 페이지
<script type="text/javascript">
$(document).ready(function() {
//페이지로드후 리사이징 시작
do_resize();
//리사이징후 스크롤 Top
parent.document.documentElement.scrollTop = 0;
});
//아이프레임 리사이징
function do_resize() {
var bodyHeight = $('#divSub3body').height();
var bodyWidth = $('#divSub3body').width();
self.resizeTo(bodyWidth, bodyHeight + 10);
}
//뒤로가기잠금
window.history.forward(1);
</script>
<div id="divSub3body">
내용
내용
내용
내용
내용
내용
내용
내용
내용
</div>
'프로그램 > - Script' 카테고리의 다른 글
Facebook LikeBox (0) | 2011.10.11 |
---|---|
로컬 스토리지 (0) | 2011.09.23 |
[Jquery]영역의 높이 너비 값 구하기 (0) | 2011.08.03 |
글자수 체크 (0) | 2011.08.03 |
Base64 인코딩, 디코딩 변환 (0) | 2011.03.30 |
설정
트랙백
댓글
글
<html> <head> <title>BASE64 Encode / Decode</title> <meta http-equiv="Content-Type" content="text/html; charset=ks_c_5601-1987"> <link rel="STYLESHEET" type="text/css" href="/Css/MyWeb.css"> </head> <body bgcolor="#ffffff" topmargin="0" leftmargin="0"> <table width="610" cellspacing="0" HEIGHT="307" ID="Table1"> <tr height="25"> <td style="BORDER-RIGHT: buttonface 1px solid;BORDER-BOTTOM: buttonface 1px solid"> </td> </tr> <tr> <td style="border-right:1 solid silver" align="center" valign="top"> <form name="frm64" ID="Form1"> <table cellpadding="4" cellspacing="0" align="center" bgcolor="#99a9bc" width="380" style="margin-top:20" ID="Table2"> <tr height="30" bgcolor="white"> <td align="middle"> <p><b>BASE64 Encode / Decode</b></p> <p><textarea name="text1" size="100" rows="10" class="verdana" style="border:1 solid black; width:550px" ID="Textarea1"></textarea></p> <p><input name="button1" onclick="CallEncode(document.frm64.text1.value)" type="button" value="Encode" ID="Button1"> <input name="button2" onclick="CallDecode(document.frm64.text1.value);" type="button" value="Decode" ID="Button2"> <input type="reset" id=reset1 name=reset1> </p> </td> </tr> </table> </form> </td> </tr> </table> <table bgcolor="#646464" height="18" cellpadding="0" cellspacing="0" width="610" ID="Table3"> <tr> <td align="right"><img src="/images/copyleft.gif" usemap="#Map" border="0" WIDTH="249" HEIGHT="18"></td> </tr> </table> <map name="Map"> <area shape="rect" coords="230,2,244,14" href="mailto:admin@taeyo.pe.kr"> </map> </body> <script language="javascript"> <!-- /**************************************************** base64.js --------- A JavaScript library for base64 encoding and decoding by Danny Goodman (http://www.dannyg.com). Described in "JavaScript and DHTML Cookbook" published by O'Reilly & Associates. Copyright 2003. [Inspired by many examples in many programming languages, but predominantly by Java routines seen in online course notes by Hamish Taylor at http://www.cee.hw.ac.uk/courses/2nq3/4/ The binary data manipulations were very helpful.] This library is self-initializing when included in an HTML page and loaded in a JavaScript-enabled browser. Browser compatibility has been tested back to Netscape 4 and Internet Explorer 5 (Windows and Mac). Two "public" functions accept one string argument (the string to convert) and return a string (the converted output). Because this library is designed only for client-side encoding and decoding (i.e., no encoded data is intended for transmission to a server), the encoding routines here ignore the 76-character line limit for MIME transmission. See details of encoding scheme in RFC2045: http://www.ietf.org/rfc/rfc2045.txt These routines are being used to encode/decode html element attribute values, which may not contain an equals (=) symbol. Thus, we do not allow padding of uneven block lengths. To encode a string, invoke: var encodedString = base64Encode("stringToEncode"); To decode a string, invoke: var plainString = base64Decode("encodedString"); Release History --------------- v.1.00 07Apr2003 First release ****************************************************/ var enc64List, dec64List; function CallEncode(str) { document.frm64.text1.value = base64Encode(str); } function CallDecode(str) { document.frm64.text1.value = base64Decode(str); } function initBase64() { enc64List = new Array(); dec64List = new Array(); var i; for (i = 0; i < 26; i++) { enc64List[enc64List.length] = String.fromCharCode(65 + i); } for (i = 0; i < 26; i++) { enc64List[enc64List.length] = String.fromCharCode(97 + i); } for (i = 0; i < 10; i++) { enc64List[enc64List.length] = String.fromCharCode(48 + i); } enc64List[enc64List.length] = "+"; enc64List[enc64List.length] = "/"; for (i = 0; i < 128; i++) { dec64List[dec64List.length] = -1; } for (i = 0; i < 64; i++) { dec64List[enc64List[i].charCodeAt(0)] = i; } } function base64Encode(str) { var c, d, e, end = 0; var u, v, w, x; var ptr = -1; var input = str.split(""); var output = ""; while(end == 0) { c = (typeof input[++ptr] != "undefined") ? input[ptr].charCodeAt(0) : ((end = 1) ? 0 : 0); d = (typeof input[++ptr] != "undefined") ? input[ptr].charCodeAt(0) : ((end += 1) ? 0 : 0); e = (typeof input[++ptr] != "undefined") ? input[ptr].charCodeAt(0) : ((end += 1) ? 0 : 0); u = enc64List[c >> 2]; v = enc64List[(0x00000003 & c) << 4 | d >> 4]; w = enc64List[(0x0000000F & d) << 2 | e >> 6]; x = enc64List[e & 0x0000003F]; if (end >= 1) {x = "=";} if (end == 2) {w = "=";} if (end < 3) {output += u + v + w + x;} } var formattedOutput = ""; var lineLength = 76; while (output.length > lineLength) { formattedOutput += output.substring(0, lineLength) + "\n"; output = output.substring(lineLength); } formattedOutput += output; return formattedOutput; } function base64Decode(str) { var c=0, d=0, e=0, f=0, i=0, n=0; var input = str.split(""); var output = ""; var ptr = 0; do { f = input[ptr++].charCodeAt(0); i = dec64List[f]; if ( f >= 0 && f < 128 && i != -1 ) { if ( n % 4 == 0 ) { c = i << 2; } else if ( n % 4 == 1 ) { c = c | ( i >> 4 ); d = ( i & 0x0000000F ) << 4; } else if ( n % 4 == 2 ) { d = d | ( i >> 2 ); e = ( i & 0x00000003 ) << 6; } else { e = e | i; } n++; if ( n % 4 == 0 ) { output += String.fromCharCode(c) + String.fromCharCode(d) + String.fromCharCode(e); } } } while (typeof input[ptr] != "undefined"); output += (n % 4 == 3) ? String.fromCharCode(c) + String.fromCharCode(d) : ((n % 4 == 2) ? String.fromCharCode(c) : ""); return output; } initBase64(); //--> </script> </html>
출처 - TAEYO.NET (http://taeyo.net/base64.htm)
'프로그램 > - Script' 카테고리의 다른 글
Facebook LikeBox (0) | 2011.10.11 |
---|---|
로컬 스토리지 (0) | 2011.09.23 |
[Jquery]영역의 높이 너비 값 구하기 (0) | 2011.08.03 |
글자수 체크 (0) | 2011.08.03 |
아이프레임 리사이징 & 뒤로가기잠금 (0) | 2011.07.05 |
RECENT COMMENT