I’m using Symfony 4.4 and I’m doing my own authenticator. Everything works fine, I just can’t figure out how to compare the password entered by the user and the one in Ldap. I would like to do this in …
How to fix laravel 8 UI paginate problem?
I had a problem while trying out the recently released laravel 8, I’m trying to find out what the changes are and how it works. When I did that I had a problem with the paginate laravel 8 UI getting …
Access File Uploaded Attributes in Laravel 5
I upload a file In my controller, I did this I see this I want to pathname: “/private/var/tmp/phpb73hcy”, I’ve tried I just want this /private/var/tmp/phpb73hcy Any hints for me ? Answer Use $this->getPathname(). The Laravel UploadedFile class extends the Symfony UploadedFile class, which…
Replace value in array with result of mysqli_query
I’m having some trouble with php coding. What I want to do is following: Create an array ($rows) and fil it with the results of a mysqli_query ($query1) –> OK for each element in that array, replace the value of a certain key (pilot_rule_id) with the result of another mysqli_query ($query2). (t…
How do I securely store/get user information on the client side in web development?
I have been making good progress on a web based application over the past few months, however I realized a few vulnerabilities in the way I communicate information between client and server. I am using Angular JS and PHP as my main frameworks. Upon logging in, I store user data such as username, id, and assoc…
Laravel routes causing 404 Error on live server
I have a laravel app developed on my localhost and working perfectly. I am trying to deploy it onto an AWS Lightsail instance using nginx on Ubuntu 20.04. I have uploaded my laravel app and changed the nginx root directory to laravelapp/public. The main index page (landing page) is working fine but none of my…
How to calculate inside a foreach loop using php [closed]
I have this code where am able to get data from the database and insert into an array and also be able to insert it back in another table in the same database but what i want is that in the data there …
Foreach loop but print one time with multiple value
So I have in my database a table called “Clients” and an other one called “Pets”. They are linked by an associative table which means that a “Clients” can have two “…
whats causing the migration to fail with error ” there can only be on auto increment column”
My table posts does not have any limits, i am letting Laravel choose the auto increment by default. It still fails with “there can only be on auto increment column”. migration Answer You can’t have multiple auto incremented columns. Change the foreign keys type to unsignedInteger() and it should work. T…
Select option only posts id, I need the value too
I have an issue in a simple PHP MySQL project. When I try to fetch a record from a select option, it only gives me the id. I want the value from the select to be passed too. <form class="form-…