How to send multiple files with Ajax

I have Ajax Code which is sending input:file info, but i have a problem, program is sending the last file info, and I can’t get information about past files What’s wrong? I will be grateful for help HTML Form <input type="file" name="files[]" id="sss" multiple> <div class="bloj"></div> PHP $nkar = $_FILES[‘file’][‘name’]; $nkar_loc = $_FILES[‘file’][‘tmp_name’]; $flr=$_FILES[‘file’]; print_r($flr);… Read More How to send multiple files with Ajax

Using pure javascricpt ajax request to echo in php

Hey im trying to get rid of jquery and go pure javascript. The problem is when do the ajax request no data is coming back from the request Here is process. I am not getting any data in the processing part. <form name="inputform" method="post"> <input type="text" id="user" name="user"> <input type="text" id="name" name="name"> <input type="text" id="email"… Read More Using pure javascricpt ajax request to echo in php

How can I visit to another pagination page or searching, the button does not work

The button action does not work after searching in the index page. The action button does not work on the second page. My Ajax Script $(document).on("click", "#pagination a, #search_btn, #reset_btn", function() { if(this.id == ‘reset_btn’){ $("#searchform").reset(); } $.ajax({ url: this.dataset.url, type: ‘get’, data: $("#searchform").serialize(), processData: false, cache: false, contentType: false, success: function(data) { $("#pagination_data").html(data); },… Read More How can I visit to another pagination page or searching, the button does not work

Hiding button by "Id" works, but clicking it not

I execute the top portion here automatically. In this script I can easily hide "showLine" via document.getElementById("showLine").style.visibility="hidden"; no problemo, but document.getElementById("showLine").click(); will not fire no matter what I do… The button does not press onload.. <script src="https://code.jquery.com/jquery-3.3.1.min.js"></script&gt; //Autoexecute on pageload <script type="text/javascript"> $(document).ready(function () { document.getElementById("showLine").click(); //document.getElementById("showLine").style.visibility="hidden"; }); </script> //script with button "showLine" <script> var… Read More Hiding button by "Id" works, but clicking it not

How to access ajax call's parameters in the success function?

I’m doing several ajax calls of the following type in a loop: var param1Val = ‘will be different in each loop’; var param2Val = ‘will be different in each loop’; $.ajax({ type: ‘POST’, url: someUrl, dataType: ‘xml’, data: { ‘param1’: param1Val, ‘param2’: param2Val }, success: function(result){ // how to access param1 and param2 here??? }… Read More How to access ajax call's parameters in the success function?

how i use multiple button on html table with ajax

< <div class="form-group"> <div > <a href="/addcourse"> <button class="btn btn-primary ">add course</button> </a> <div class="center"> <h1>manage courses</h1> </div> <div style="padding-left: 500px"> <form class="form-horizontal" style="width: 50%;"> <div class="form-group"> <label for="faculty" class="col-sm-2 control-label" ></label> <div class="col-sm-10"> <div class="btn-group"> <button index=0 id=’facultyDropdown’ class="btn">Faculties</button> <button class="btn dropdown-toggle" data-toggle="dropdown"> <span class="caret"></span> </button> <ul class="dropdown-menu"> {{#facultyId}} <li><a index="{{id}}">{{faculty}}</a></li> {{/facultyId}} </ul> </div>… Read More how i use multiple button on html table with ajax