/* 
JavaScript Document
Developer: Muthuswamy K
E-Mail: muthu.work@gmail.com
Web: http://www.muthuswamy.in
*/

/* Tabs */
$(document).ready(function(){$('#right-panel ul.tab-nav').tabs({fx:{height:'toggle'}}); });

/* Rounded Corners with Border*/
$(document).ready(function(){
	$("#right-panel .box .box-content").wrapInner("<div class=\"box-content-hold rocor\"><\/div>");
});

/* Code Syntax */
$(document).ready(function(){dp.SyntaxHighlighter.HighlightAll('code');});

/* Comment Form */
$(document).ready(function(){
	/* Author */
	if($("#author").attr("value")=="") {$("#author").attr("value","Name (required)");}	
	$("#author").focus(function(){if($(this).attr("value")=="Name (required)") $(this).attr("value","");});
	$("#author").blur(function(){if($(this).attr("value")=="") $(this).attr("value","Name (required)");});
	/* Email */
	if($("#email").attr("value")=="") {$("#email").attr("value","Email (required) (will not be published)")}
	$("#email").focus(function(){if($("#email").attr("value")=="Email (required) (will not be published)") $(this).attr("value","")});
	$("#email").blur(function(){if($("#email").attr("value")=="") $(this).attr("value","Email (required) (will not be published)")});
	/* Website */
	if($("#url").attr("value")=="") {$("#url").attr("value","Website")}
	$("#url").focus(function(){if($("#url").attr("value")=="Website") $(this).attr("value","")});
	$("#url").blur(function(){if($("#url").attr("value")=="") $(this).attr("value","Website")});
	/* Comment */
	if($("#comment").attr("value")=="") {$("#comment").attr("value","Your Comments")}
	$("#comment").focus(function(){if($("#comment").attr("value")=="Your Comments") $(this).attr("value","")});
	$("#comment").blur(function(){if($("#comment").attr("value")=="") $(this).attr("value","Your Comments")});
	/* Reset on Submit */
	$("#commentform").submit(function(){
		if($("#author").attr("value")=="Name (required)") $("#author").attr("value","")
		if($("#email").attr("value")=="Email (required) (will not be published)") $("#email").attr("value","")
		if($("#url").attr("value")=="Website") $("#url").attr("value","")
		if($("#comment").attr("value")=="Your Comments") $("#comment").attr("value","")
	});
});