I get an endpoint which take some products of the database. That’s endpoint brings a JSON which looks like this: So, I need to make a table which shows colour[0] with size[0], colour[1] with size[1], etc. The main problem is that I can’t access by the name of the column (size and colour), because …
Tag: php
cakephp 4.x query to get results from database
I came across a problem recently that I have to make a find(all) query in cakephp. Problem is I was unable to call model function to cakephp controller & add a command in function that would allow me to make a find(all) function in cakephp and retrieve all rows in a database that I was looking for. I woul…
Extracting json string with PHP
JSON string that i received from the API Information that i wanted to extract My attempt The output: Did the JSON string that i received is in bad format? Why does it says undefined property? Appreciate any helps. thanks! Post that i’ve refer to: How do I extract data from JSON with PHP? Answer token is…
After the condition of a select is met, show or hide further selects
I have the following question because I haven’t found anything on the internet. I have created several selects with HTML. The select has the optiions yes / no. The first select checks whether the topic is relevant, if it is not relevant, then the remaining selects for the topic should disappear. I then …
MySQL returns wierd result with normal query
So I have this code: And it returns this instead of the normal values in the table: array(12) { [0]=> int(2) [“ID”]=> int(2) 1=> string(7) “anderes” [“Naam”]=> string(7) “anderes” [2]=> string(4) “0.00” [“Beschrijving”]=>…
How to get multiple values through session from a file which is running multiple times in PHP
I have a file which is run 2 to 3 times and there is a variable $student_name, and I want that variable to be available in another file. How to achieve it? file 1. file 2. but I am getting only the last assigned value. Answer If file 1 is executed 3 times, then $info will be re-created empty in
Remove product (item) from WooCommerce checkout page using AJAX
I have added a removal link to the checkout for each product. This part works fine. Problem is; upon removal, the page is “scrolled to top”. I would like to change this by adding AJAX to the removal process. I’ve tried, but without success. In other words; when clicking on the removal link, …
jwt token not found when i pass in username and password in curl
I want to use jwt token in my symfony project. But i have a problem because when i use: curl.exe -X POST -H “Content-Type: application/json” http://localhost:81/api/login_check -d ‘{“username”: “f.djawid@outlook.com”,”password”:”000000″}’…
ResellersPanel API is giving me domain errors even after I put the “domain” type
I am using Resellers Panel API. I am trying to create a simple order form in PHP. I am following this documentation : https://cp.resellerspanel.com/downloads/ResellersPanelAPI.pdf I manage to go this far. It accepted all the inputs fine. until I got to the domains. it gives me these error. No type provided fo…
Update ACF User Radio Button After Gravity Form Submit
having a issue with getting a ACF field associated with a user profile to update after a gravity form submission. As it stands, this logic currently does nothing :(. So i’m hoping someone can help out. Here is waht I have so far: So it should be pretty straight forward I would image, but it just seems t…