php – 'Connection could not be established with host smtp.gmail.com [Unable to find the socket transport "ssl"

exception or error: I’m trying to send a message with SwiftMailer using localhost. However I keep getting the error: 560:tid 1472] [client ::1:65504] PHP Fatal error: Uncaught exception ‘Swift_TransportException’ with message ‘Connection could not be established with host smtp.gmail.com [Unable to find the socket transport “ssl” – did you forget to enable it when you …

php – How can I get grid row id outside $grid->actions or $grid->column()->display? in laravel-admin

exception or error: Laravel Version: 5.8.* PHP Version:7.3.* Laravel-admin: 1.7.9 Description: I extended default Grid class to add button to table view, but I couldn’t get row id of grid. I wanted to do something like below. $grid->addButton(‘詳細’, route(‘master_maker_detail’, [ ‘maker_id’ => $grid->row->getKey() ])); How to solve: More exceptions or solve method

php – not getting result as expected with fetch_object() in while loop

exception or error: i m working on a project where i display some images uploaded by user and it is fetched from DB table with fetch_object() method, this is my code: <?php $ph1 = $media->fetch_assoc(); echo “testarray”; print_r($ph1); while ($photo = $media->fetch_object()) { ?> <li> <div class=”gallery-item”> <a href=”<?= $system->getDomain() ?>/uploads/<?= $photo->path ?>” data-fancybox=”gallery”> <img …

php – Echo the table when insert the data in the form

exception or error: I have created form to insert data into my SQL SERVER 2014 Database. I can’t echo the data show my page when I have insert the data. Below is my coding: <?php $qry=”SELECT id, code, description, payment_amount FROM payment_setup”; $result = mysqli_query($conn,$qry); if ($result->num_rows > 0) { echo “<table><tr><th>id</th><th>Code</th><th>Description</th><th>Payment Amount</th><th>Action</th></tr>”; while($row = …

php – How to delete the image from the storage in laravel?

exception or error: I am currently trying to delete an image when a user updates his/her post before publishing. Everything works fine, the image is changed in the database and post page, but I want to delete the previous image. Here is my controller public function updatePost(Request $request){ $data = $request->all(); $postid = $request[‘id’]; $isExist …