MMCT TEAM
Server IP : 103.53.40.154  /  Your IP : 18.119.113.79
Web Server : Apache
System : Linux md-in-35.webhostbox.net 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64
User : ppcad7no ( 715)
PHP Version : 8.2.25
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /home2/ppcad7no/vivahmilankendra.com/js/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home2/ppcad7no/vivahmilankendra.com/js/jquery.collapsible.js
/*!
* Collapsible.js v1.2.0
* https://github.com/jordnkr/collapsible
*
* Copyright 2017, Jordan Ruedy
* This content is released under the MIT license
* http://opensource.org/licenses/MIT
*/

(function($, undefined) {
    $.fn.collapsible = function(options) {

        var defaults = {
            accordion: false,
            accordionUpSpeed: 400,
            accordionDownSpeed: 400,
            collapseSpeed: 400,
			contentOpen: null,
            arrowRclass: 'arrow-r',
            arrowDclass: 'arrow-d',
            animate: true
        };

        var settings = $.extend(defaults, options);

        return this.each(function() {
            if (settings.animate === false) {
                settings.accordionUpSpeed = 0;
                settings.accordionDownSpeed = 0;
                settings.collapseSpeed = 0;
            }

            var $thisEven = $(this).children(':even');
            var $thisOdd = $(this).children(':odd');
			var accord = 'accordion-active';

            $(this).children(':nth-child(even)').css('display','none');
			

            if (settings.accordion === true) {
                if (settings.contentOpen !== null) {
                    $($thisEven[settings.contentOpen]).children(':first-child').toggleClass(settings.arrowRclass + ' ' + settings.arrowDclass);
                    $($thisOdd[settings.contentOpen]).show().addClass(accord);
				   
				}
                $($thisEven).click(function() {
					
					


                    if ($(this).next().attr('class') === accord) {
                        $(this).next().slideUp(settings.accordionUpSpeed).removeClass(accord);
                        $(this).children(':first-child').toggleClass(settings.arrowRclass + ' ' + settings.arrowDclass);
                    } else {
                        $($thisEven).children().removeClass(settings.arrowDclass).addClass(settings.arrowRclass);
                        $($thisOdd).slideUp(settings.accordionUpSpeed).removeClass(accord);
                        $(this).next().slideDown(settings.accordionDownSpeed).addClass(accord);
                        $(this).children(':first-child').toggleClass(settings.arrowRclass + ' ' + settings.arrowDclass);
                    }
	
					
					
                });
				
            } else {
                if (settings.contentOpen !== null) {
					
                    if (Array.isArray( settings.contentOpen )) {
                        for (var i = 0; i < settings.contentOpen.length; i++) {
                           
						  
						    var index = settings.contentOpen[i];
                            $($thisEven[index]).children(':first-child').toggleClass(settings.arrowRclass + ' ' + settings.arrowDclass);
                            $($thisOdd[index]).show();
						  
							
							
                        }
                    } else {
						
						//alert("condition found")  
                        $($thisEven[settings.contentOpen]).children(':first-child').toggleClass(settings.arrowRclass + ' ' + settings.arrowDclass);
                        $($thisOdd[settings.contentOpen]).show();
                    }
                }
                $($thisEven).click(function() {
					
					var cond_ari=$("#validCond").val();
					//var condSrc_ari=$("#validSource").val();										
					
					//if(cond_ari==1 && condSrc_ari=='req_next'){
						
				   //alert("Cond : "+cond_ari)  					
						
						
					if(cond_ari==1){
					//alert("condition found")  					
                    $(this).children(':first-child').toggleClass(settings.arrowRclass + ' ' + settings.arrowDclass);
                    $(this).next().slideToggle(settings.collapseSpeed);
					$("#validCond").val(0)
					}
					
                });
            }
        });
    };
})(jQuery);

MMCT - 2023