skip to Main Content

Jquery – Clear fields when closing div

To open and close div I used the following code: $('#addvisit').on('click', function(e) { e.stopImmediatePropagation(); $('#fechvisit').slideToggle('slow'); }); <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <button type="button" id="addvisit" class="hs-button primary large">Adicionar Visitante</button> <div id="fechvisit" style="display: none;"> <div class="row"> <div class="col-xs-12"> <div class="form-group"> <label for="titl"> <strong>NOME VISITANTE</strong></label> <select…

VIEW QUESTION

PHP Include All Functions in Directory Inside Class

Is there a possibility of including all functions within directory within a class. For example: class.php class all_functions{ foreach(glob(__DIR__.'/functions/*.php') as $file){include($file);} } functions/function1.php function hello(){ echo 'hello'; } functions/function2.php function goodbye(){ echo 'goodbye'; } Result would be a class all_functions()…

VIEW QUESTION
Back To Top
Search