﻿/// <reference path="jquery-1.3.2-vsdoc.js" />

$(document).ready(function () {
	$("#txtText").watermark("Enter your email address or other text here...");
	var corner = 20;
	$("#main").corner({
		tl: { radius: corner },
		tr: { radius: corner },
		bl: { radius: corner },
		br: { radius: corner },
		antiAlias: true,
		autoPad: true
	});
	corner = 10;
	$(".box").corner({
		tl: { radius: corner },
		tr: { radius: corner },
		bl: { radius: corner },
		br: { radius: corner },
		antiAlias: true,
		autoPad: true
	});

	$(".links input").focus(function () {
		this.select();
		$(this).mouseup(function (e) {
			e.preventDefault();
		});
	});
	$("#recycle").click(function () {
		$("#email").attr("src", $("#img").val() + "?q=" + randomString(new Array('1', '2', '3', '4', '5', '6', '7', '8', '9'), 10));
		return false;
	});
});


function randomString(sChrs, iLen) {
    var sRnd = '';
    for (var i = 0; i < iLen; i++) {
        var randomPos = Math.floor(Math.random() * sChrs.length);
        sRnd += sChrs[randomPos];
    }
    return sRnd;
}