No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
2 Posted Topics
Hlo Plz anyone give a coading of classic asp i want to save my csv and excel file in databse
Try this <?php $connect = mysqli_connect("localhost", "root", "", "testing"); if(isset($_POST["submit"])) { if($_FILES['file']['name']) { $filename = explode(".", $_FILES['file']['name']); if($filename[1] == 'csv') { $handle = fopen($_FILES['file']['tmp_name'], "r"); while($data = fgetcsv($handle)) { $item1 = mysqli_real_escape_string($connect, $data[0]); $item2 = mysqli_real_escape_string($connect, $data[1]); $query = "INSERT into excel(excel_name, excel_phone) values('$item1','$item2')"; mysqli_query($connect, $query); } fclose($handle); echo "<script>alert('Import …
The End.