$.easing.easeOutElastic = function (x, t, b, c, d) {
		var s=1.70158;var p=0;var a=c;
		if (t==0) return b;  if ((t/=d)==1) return b+c;  if (!p) p=d*.3;
		if (a < Math.abs(c)) { a=c; var s=p/4; }
		else var s = p/(2*Math.PI) * Math.asin (c/a);
		return a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b;
}
 
// create custom tooltip effect for jQuery Tooltip
$.tools.tooltip.addEffect("easeOutElastic",
 
	// opening animation
	function(done) {
		this.getTip().animate({top: '-=3'}, 300, 'easeOutElastic', done).show();
	},
 
	// closing animation
	function(done) {
		this.getTip().animate({top: '-=2'}, 0, 'easeOutElastic', function()  {
			$(this).hide();
			done.call();
		});
	}
);
 

$("#demo img[title]").tooltip(
{ position: "top center", opacity: 1.0, effect: "easeOutElastic"}

  
);

$(function(){
$(".menuParent").click(function () {
    var myClass = $(this).children('ol').attr("class");
    if (myClass.search('activeSubMenu') == -1)
    {
        $('.activeSubMenu').slideUp();
        $(this).children('ol').slideDown();
        $(this).children('ol').addClass('activeSubMenu');    
    }
    else
    {
         $('.activeSubMenu').slideUp();
         $(this).children('ol').removeClass('activeSubMenu');  
    }
   
    
    });

});
$("#contactForm :input").tooltip({

	// place tooltip on the right edge
	position: "center right",

	// a little tweaking of the position
	offset: [-2, 10],

	// use the built-in fadeIn/fadeOut effect
	effect: "fade",

	// custom opacity setting
	opacity: 0.7,
    tipClass: "formTooltip"

});
$("#userRegisterForm :input").tooltip({

	// place tooltip on the right edge
	position: "center right",

	// a little tweaking of the position
	offset: [-2, 10],

	// use the built-in fadeIn/fadeOut effect
	effect: "fade",

	// custom opacity setting
	opacity: 0.7,
    tipClass: "formTooltip"

});
//brushes start
SyntaxHighlighter.brushes.Bash = function()
{
    var keywords =    'if fi then elif else for do done until while break continue case function return in eq ne gt lt ge le';
    var commands =  'alias apropos awk bash bc bg builtin bzip2 cal cat cd cfdisk chgrp chmod chown chroot' +
                    'cksum clear cmp comm command cp cron crontab csplit cut date dc dd ddrescue declare df ' +
                    'diff diff3 dig dir dircolors dirname dirs du echo egrep eject enable env ethtool eval ' +
                    'exec exit expand export expr false fdformat fdisk fg fgrep file find fmt fold format ' +
                    'free fsck ftp gawk getopts grep groups gzip hash head history hostname id ifconfig ' +
                    'import install join kill less let ln local locate logname logout look lpc lpr lprint ' +
                    'lprintd lprintq lprm ls lsof make man mkdir mkfifo mkisofs mknod more mount mtools ' +
                    'mv netstat nice nl nohup nslookup open op passwd paste pathchk ping popd pr printcap ' +
                    'printenv printf ps pushd pwd quota quotacheck quotactl ram rcp read readonly renice ' +
                    'remsync rm rmdir rsync screen scp sdiff sed select seq set sftp shift shopt shutdown ' +
                    'sleep sort source split ssh strace su sudo sum symlink sync tail tar tee test time ' +
                    'times touch top traceroute trap tr true tsort tty type ulimit umask umount unalias ' +
                    'uname unexpand uniq units unset unshar useradd usermod users uuencode uudecode v vdir ' +
                    'vi watch wc whereis which who whoami Wget xargs yes'
                    ;
    
    this.regexList = [
        { regex: SyntaxHighlighter.regexLib.singleLinePerlComments,        css: 'comments' },        // one line comments
        { regex: SyntaxHighlighter.regexLib.doubleQuotedString,            css: 'string' },        // double quoted strings
        { regex: new RegExp(this.getKeywords(keywords), 'gm'),            css: 'keyword' },        // keywords
        { regex: new RegExp(this.getKeywords(commands), 'gm'),            css: 'functions' }        // commands
        ];
}

SyntaxHighlighter.brushes.Bash.prototype    = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Bash.aliases        = ['bash', 'shell'];

SyntaxHighlighter.brushes.CSS = function()
{
    function getKeywordsCSS(str)
    {
        return '\\b([a-z_]|)' + str.replace(/ /g, '(?=:)\\b|\\b([a-z_\\*]|\\*|)') + '(?=:)\\b';
    };
    
    function getValuesCSS(str)
    {
        return '\\b' + str.replace(/ /g, '(?!-)(?!:)\\b|\\b()') + '\:\\b';
    };

    var keywords =    'ascent azimuth background-attachment background-color background-image background-position ' +
                    'background-repeat background baseline bbox border-collapse border-color border-spacing border-style border-top ' +
                    'border-right border-bottom border-left border-top-color border-right-color border-bottom-color border-left-color ' +
                    'border-top-style border-right-style border-bottom-style border-left-style border-top-width border-right-width ' +
                    'border-bottom-width border-left-width border-width border bottom cap-height caption-side centerline clear clip color ' +
                    'content counter-increment counter-reset cue-after cue-before cue cursor definition-src descent direction display ' +
                    'elevation empty-cells float font-size-adjust font-family font-size font-stretch font-style font-variant font-weight font ' +
                    'height left letter-spacing line-height list-style-image list-style-position list-style-type list-style margin-top ' +
                    'margin-right margin-bottom margin-left margin marker-offset marks mathline max-height max-width min-height min-width orphans ' +
                    'outline-color outline-style outline-width outline overflow padding-top padding-right padding-bottom padding-left padding page ' +
                    'page-break-after page-break-before page-break-inside pause pause-after pause-before pitch pitch-range play-during position ' +
                    'quotes right richness size slope src speak-header speak-numeral speak-punctuation speak speech-rate stemh stemv stress ' +
                    'table-layout text-align top text-decoration text-indent text-shadow text-transform unicode-bidi unicode-range units-per-em ' +
                    'vertical-align visibility voice-family volume white-space widows width widths word-spacing x-height z-index';

    var values =    'above absolute all always aqua armenian attr aural auto avoid baseline behind below bidi-override black blink block blue bold bolder '+
                    'both bottom braille capitalize caption center center-left center-right circle close-quote code collapse compact condensed '+
                    'continuous counter counters crop cross crosshair cursive dashed decimal decimal-leading-zero default digits disc dotted double '+
                    'embed embossed e-resize expanded extra-condensed extra-expanded fantasy far-left far-right fast faster fixed format fuchsia '+
                    'gray green groove handheld hebrew help hidden hide high higher icon inline-table inline inset inside invert italic '+
                    'justify landscape large larger left-side left leftwards level lighter lime line-through list-item local loud lower-alpha '+
                    'lowercase lower-greek lower-latin lower-roman lower low ltr marker maroon medium message-box middle mix move narrower '+
                    'navy ne-resize no-close-quote none no-open-quote no-repeat normal nowrap n-resize nw-resize oblique olive once open-quote outset '+
                    'outside overline pointer portrait pre print projection purple red relative repeat repeat-x repeat-y rgb ridge right right-side '+
                    'rightwards rtl run-in screen scroll semi-condensed semi-expanded separate se-resize show silent silver slower slow '+
                    'small small-caps small-caption smaller soft solid speech spell-out square s-resize static status-bar sub super sw-resize '+
                    'table-caption table-cell table-column table-column-group table-footer-group table-header-group table-row table-row-group teal '+
                    'text-bottom text-top thick thin top transparent tty tv ultra-condensed ultra-expanded underline upper-alpha uppercase upper-latin '+
                    'upper-roman url visible wait white wider w-resize x-fast x-high x-large x-loud x-low x-slow x-small x-soft xx-large xx-small yellow';

    var fonts =        '[mM]onospace [tT]ahoma [vV]erdana [aA]rial [hH]elvetica [sS]ans-serif [sS]erif [cC]ourier mono sans serif';
    
    this.regexList = [
        { regex: SyntaxHighlighter.regexLib.multiLineCComments,        css: 'comments' },    // multiline comments
        { regex: SyntaxHighlighter.regexLib.doubleQuotedString,        css: 'string' },    // double quoted strings
        { regex: SyntaxHighlighter.regexLib.singleQuotedString,        css: 'string' },    // single quoted strings
        { regex: /\#[a-fA-F0-9]{3,6}/g,                                css: 'value' },        // html colors
        { regex: /(-?\d+)(\.\d+)?(px|em|pt|\:|\%|)/g,                css: 'value' },        // sizes
        { regex: /!important/g,                                        css: 'color3' },    // !important
        { regex: new RegExp(getKeywordsCSS(keywords), 'gm'),        css: 'keyword' },    // keywords
        { regex: new RegExp(getValuesCSS(values), 'g'),                css: 'value' },        // values
        { regex: new RegExp(this.getKeywords(fonts), 'g'),            css: 'color1' }        // fonts
        ];

    this.forHtmlScript({ 
        left: /(&lt;|<)\s*style.*?(&gt;|>)/gi, 
        right: /(&lt;|<)\/\s*style\s*(&gt;|>)/gi 
        });
};

SyntaxHighlighter.brushes.CSS.prototype    = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.CSS.aliases    = ['css'];

SyntaxHighlighter.brushes.Diff = function()
{
    this.regexList = [
        { regex: /^\+\+\+.*$/gm,        css: 'color2' },
        { regex: /^\-\-\-.*$/gm,        css: 'color2' },
        { regex: /^\s.*$/gm,            css: 'color1' },
        { regex: /^@@.*@@$/gm,            css: 'variable' },
        { regex: /^\+[^\+]{1}.*$/gm,    css: 'string' },
        { regex: /^\-[^\-]{1}.*$/gm,    css: 'comments' }
        ];
};

SyntaxHighlighter.brushes.Diff.prototype    = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Diff.aliases        = ['diff', 'patch'];

SyntaxHighlighter.brushes.Php = function()
{
    var funcs    =    'abs acos acosh addcslashes addslashes ' +
                    'array_change_key_case array_chunk array_combine array_count_values array_diff '+
                    'array_diff_assoc array_diff_key array_diff_uassoc array_diff_ukey array_fill '+
                    'array_filter array_flip array_intersect array_intersect_assoc array_intersect_key '+
                    'array_intersect_uassoc array_intersect_ukey array_key_exists array_keys array_map '+
                    'array_merge array_merge_recursive array_multisort array_pad array_pop array_product '+
                    'array_push array_rand array_reduce array_reverse array_search array_shift '+
                    'array_slice array_splice array_sum array_udiff array_udiff_assoc '+
                    'array_udiff_uassoc array_uintersect array_uintersect_assoc '+
                    'array_uintersect_uassoc array_unique array_unshift array_values array_walk '+
                    'array_walk_recursive atan atan2 atanh base64_decode base64_encode base_convert '+
                    'basename bcadd bccomp bcdiv bcmod bcmul bindec bindtextdomain bzclose bzcompress '+
                    'bzdecompress bzerrno bzerror bzerrstr bzflush bzopen bzread bzwrite ceil chdir '+
                    'checkdate checkdnsrr chgrp chmod chop chown chr chroot chunk_split class_exists '+
                    'closedir closelog copy cos cosh count count_chars date decbin dechex decoct '+
                    'deg2rad delete ebcdic2ascii echo empty end ereg ereg_replace eregi eregi_replace error_log '+
                    'error_reporting escapeshellarg escapeshellcmd eval exec exit exp explode extension_loaded '+
                    'feof fflush fgetc fgetcsv fgets fgetss file_exists file_get_contents file_put_contents '+
                    'fileatime filectime filegroup fileinode filemtime fileowner fileperms filesize filetype '+
                    'floatval flock floor flush fmod fnmatch fopen fpassthru fprintf fputcsv fputs fread fscanf '+
                    'fseek fsockopen fstat ftell ftok getallheaders getcwd getdate getenv gethostbyaddr gethostbyname '+
                    'gethostbynamel getimagesize getlastmod getmxrr getmygid getmyinode getmypid getmyuid getopt '+
                    'getprotobyname getprotobynumber getrandmax getrusage getservbyname getservbyport gettext '+
                    'gettimeofday gettype glob gmdate gmmktime ini_alter ini_get ini_get_all ini_restore ini_set '+
                    'interface_exists intval ip2long is_a is_array is_bool is_callable is_dir is_double '+
                    'is_executable is_file is_finite is_float is_infinite is_int is_integer is_link is_long '+
                    'is_nan is_null is_numeric is_object is_readable is_real is_resource is_scalar is_soap_fault '+
                    'is_string is_subclass_of is_uploaded_file is_writable is_writeable mkdir mktime nl2br '+
                    'parse_ini_file parse_str parse_url passthru pathinfo readlink realpath rewind rewinddir rmdir '+
                    'round str_ireplace str_pad str_repeat str_replace str_rot13 str_shuffle str_split '+
                    'str_word_count strcasecmp strchr strcmp strcoll strcspn strftime strip_tags stripcslashes '+
                    'stripos stripslashes stristr strlen strnatcasecmp strnatcmp strncasecmp strncmp strpbrk '+
                    'strpos strptime strrchr strrev strripos strrpos strspn strstr strtok strtolower strtotime '+
                    'strtoupper strtr strval substr substr_compare';

    var keywords =    'and or xor array as break case ' +
                    'cfunction class const continue declare default die do else ' +
                    'elseif enddeclare endfor endforeach endif endswitch endwhile ' +
                    'extends for foreach function include include_once global if ' +
                    'new old_function return static switch use require require_once ' +
                    'var while abstract interface public implements extends private protected throw';
    
    var constants    = '__FILE__ __LINE__ __METHOD__ __FUNCTION__ __CLASS__';

    this.regexList = [
        { regex: SyntaxHighlighter.regexLib.singleLineCComments,    css: 'comments' },            // one line comments
        { regex: SyntaxHighlighter.regexLib.multiLineCComments,        css: 'comments' },            // multiline comments
        { regex: SyntaxHighlighter.regexLib.doubleQuotedString,        css: 'string' },            // double quoted strings
        { regex: SyntaxHighlighter.regexLib.singleQuotedString,        css: 'string' },            // single quoted strings
        { regex: /\$\w+/g,                                            css: 'variable' },            // variables
        { regex: new RegExp(this.getKeywords(funcs), 'gmi'),        css: 'functions' },            // common functions
        { regex: new RegExp(this.getKeywords(constants), 'gmi'),    css: 'constants' },            // constants
        { regex: new RegExp(this.getKeywords(keywords), 'gm'),        css: 'keyword' }            // keyword
        ];

    this.forHtmlScript(SyntaxHighlighter.regexLib.phpScriptTags);
};

SyntaxHighlighter.brushes.Php.prototype    = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Php.aliases    = ['php'];

SyntaxHighlighter.brushes.Plain = function()
{
};

SyntaxHighlighter.brushes.Plain.prototype = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Plain.aliases = ['text', 'plain'];

SyntaxHighlighter.brushes.Sql = function()
{
    var funcs    =    'abs avg case cast coalesce convert count current_timestamp ' +
                    'current_user day isnull left lower month nullif replace right ' +
                    'session_user space substring sum system_user upper user year';

    var keywords =    'absolute action add after alter as asc at authorization begin bigint ' +
                    'binary bit by cascade char character check checkpoint close collate ' +
                    'column commit committed connect connection constraint contains continue ' +
                    'create cube current current_date current_time cursor database date ' +
                    'deallocate dec decimal declare default delete desc distinct double drop ' +
                    'dynamic else end end-exec escape except exec execute false fetch first ' +
                    'float for force foreign forward free from full function global goto grant ' +
                    'group grouping having hour ignore index inner insensitive insert instead ' +
                    'int integer intersect into is isolation key last level load local max min ' +
                    'minute modify move name national nchar next no numeric of off on only ' +
                    'open option order out output partial password precision prepare primary ' +
                    'prior privileges procedure public read real references relative repeatable ' +
                    'restrict return returns revoke rollback rollup rows rule schema scroll ' +
                    'second section select sequence serializable set size smallint static ' +
                    'statistics table temp temporary then time timestamp to top transaction ' +
                    'translation trigger true truncate uncommitted union unique update values ' +
                    'varchar varying view when where with work';

    var operators =    'all and any between cross in join like not null or outer some';

    this.regexList = [
        { regex: /--(.*)$/gm,                                                css: 'comments' },            // one line and multiline comments
        { regex: SyntaxHighlighter.regexLib.multiLineDoubleQuotedString,    css: 'string' },            // double quoted strings
        { regex: SyntaxHighlighter.regexLib.multiLineSingleQuotedString,    css: 'string' },            // single quoted strings
        { regex: new RegExp(this.getKeywords(funcs), 'gmi'),                css: 'color2' },            // functions
        { regex: new RegExp(this.getKeywords(operators), 'gmi'),            css: 'color1' },            // operators and such
        { regex: new RegExp(this.getKeywords(keywords), 'gmi'),                css: 'keyword' }            // keyword
        ];
};

SyntaxHighlighter.brushes.Sql.prototype    = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Sql.aliases    = ['sql'];

SyntaxHighlighter.brushes.Xml = function()
{
    function process(match, regexInfo)
    {
        var constructor = SyntaxHighlighter.Match,
            code = match[0],
            tag = new XRegExp('(&lt;|<)[\\s\\/\\?]*(?<name>[:\\w-\\.]+)', 'xg').exec(code),
            result = []
            ;
        
        if (match.attributes != null) 
        {
            var attributes,
                regex = new XRegExp('(?<name> [\\w:\\-\\.]+)' +
                                    '\\s*=\\s*' +
                                    '(?<value> ".*?"|\'.*?\'|\\w+)',
                                    'xg');

            while ((attributes = regex.exec(code)) != null) 
            {
                result.push(new constructor(attributes.name, match.index + attributes.index, 'color1'));
                result.push(new constructor(attributes.value, match.index + attributes.index + attributes[0].indexOf(attributes.value), 'string'));
            }
        }

        if (tag != null)
            result.push(
                new constructor(tag.name, match.index + tag[0].indexOf(tag.name), 'keyword')
            );

        return result;
    }
    
    this.regexList = [
        { regex: new XRegExp('(\\&lt;|<)\\!\\[[\\w\\s]*?\\[(.|\\s)*?\\]\\](\\&gt;|>)', 'gm'),            css: 'color2' },    // <![ ... [ ... ]]>
        { regex: new XRegExp('(\\&lt;|<)!--\\s*.*?\\s*--(\\&gt;|>)', 'gm'),                                css: 'comments' },    // <!-- ... -->
        { regex: new XRegExp('(&lt;|<)[\\s\\/\\?]*(\\w+)(?<attributes>.*?)[\\s\\/\\?]*(&gt;|>)', 'sg'), func: process }
    ];
};

SyntaxHighlighter.brushes.Xml.prototype    = new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Xml.aliases    = ['xml', 'xhtml', 'xslt', 'html', 'xhtml'];
//brushesh end
//sh parms
SyntaxHighlighter.config.clipboardSwf = '/images/clipboard.swf';
SyntaxHighlighter.config.bloggerMode = true; 
SyntaxHighlighter.all();
//facebook
 window.fbAsyncInit = function() {
    FB.init({appId: 'your app id', status: true, cookie: true,
             xfbml: true});
  };
  (function() {
    var e = document.createElement('script'); e.async = true;
    e.src = document.location.protocol +
      '//connect.facebook.net/en_US/all.js';
    document.getElementById('fb-root').appendChild(e);
  }());