My migration fails when I try to execute php artisan migrate or php artisan migrate:refresh with this error: Code Users Table (migrated successfully) Address Table (fails with error) Answer One of the reasons to work with a framework such as Laravel is syntactic sugar. By following their conventions, you writ…
Problems with cUrl giving constant http code 0 => error 6
Hello and foremost thank you for your minute! I am having troubles with cURL. This seems to work perfect on my localhost but on my server it just doesn’t send off requests. Each response of the error code is “Could not resolve host: ….the url im searching…” I haven’t found …
PHP script taking too long. Need someone to take a look at my code to optimize it
I have a script that fetches data from a remote restful API and saves it to the local database. I get the reponse from the server in chunks of 2000 so i have to check if a nextRecordsUrl exists so i …
add specific text to a customm fields with php (wordpress)
I want to add text “Genre:” to the beginning of this custom field the reason that i dont simply add something like this is that i dont want to this text be shown when there isnt this field for a post Answer You can check if the field exists and then display your HTML element.
Why is my $items doesn’t hold a group of $item? Laravel 8 Ecommerce
I’m from the same post here but I’ve found the root problem why is my quantity won’t increment but I don’t know how to solve this. The problem is at my isset function (in Cart.php), because I tried to echo something there and just realized the function isn’t running. This is the …
How to create table with Foreign Keys in Laravel?
I have a users table and a roles table Now I want to create a user_role table which have two foreign keys But I’m getting an error: IlluminateDatabaseQueryException SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your Mar…
Livewire wire:model not working with nested components
I’m creating a page using livewire to list users from DB and be able to update them.. I have a Users parent component and (User)s child components users.blade.php: user.blade.php Users.php User.php This is what i’m getting in the browser Any idea why this is happening ? Answer I found the issue, i…
RecyclerView only shown on minimized [closed]
I use retrofit to get data from PHP(localhost) as JSON and display it with recycler view. My problem is my data never show whenever I go fullscreen(Image 1) and goes normal whenever I minimized the …
send to repository class variable laravel from controller
i´m traying to do query into my repository to get galleries that to have a restaurant and i need seach for id. One restaurant´s gallery only can to have 10 images, but we can to have more than one …
Create a Random AES Key in JS that can transferred to PHP?
I have a form processing script that uses AES and RSA Encryption together. At first, I solely used RSA but because of the data limit, I have started using AES encryption whose keys are now encrypted …