I've been searching the internet but I could not find any references, perhaps because I was searching wrong, so I resorted to creating this post.
I have a query in the database (MySql with PHP) that returns me a list of products with several characteristics (name, value, category, type, composition, etc.), and this listing is shown to the user on the screen.
On the left side we have filters, which are these features of the products listed initially, you would like:
1 - When selecting a filter, the result of the search is redone taking into account that selected filter, BUT WITHOUT GOING TO SEARCH THE INFORMATION AGAIN IN THE DATABASE, ie work with the result that is already in the screen of the user.
I know that for this it is necessary to create a JSON object and manipulate the information that is inside it, according to the filters that are selected, but to convert the result from PHP to the JSON object without problems (json_enconde / json_decode), but the problem is like searching within this object in order to show results with filters.
I do not want to fetch the information back into the database because if it does, I will have many queries and the response time can be high for the user.
If someone has any light to help, or has already made some similar code and can help me thank you.
Thanks to everyone