So I created a page where the details a product can be stored.
Here is how it works:
- When the window loads 2 IDs are created (ABC and DEF).
- The user can insert any data and values in the site.
- After that they can click “SEND”.
- After clicking that button, there is a table in mySql named ‘Details’ where details such as ID1, ID2, time, and date are stored.
- Alongside that, a new table is created name “ABC_DEF” (ID1_ID2), and the data written by sender is stored in it.
- Then the site creates a link to share which contains only ID2. For example, https://www.example.com/Data/?share?ID2=DEF
- After sending this to the other person, when they try to open it, the site identifies the ?share and text after ?ID2 and searches for that row in the ‘Details’ table in mySql. Then it identifies the ID1 and ID2 and goes to retrieve the data in table ID1_ID2 to display to the user as output.
But the problem is the at all times the data is being stored in ‘Details’ and a table is being created by ID1_ID2. But at random times the data written is not being stored in the created table.
I don’t know if this is because of cache issue or what. And it’s very confusing since it works sometimes and it doesn’t. And it’s completely random on when it works and when it doesn’t.
The link is being created, the details in the ‘Details’ table are always being inserted correctly, and the table is being created every single time. But the data to be stored in the table is uncertain.
Is there any way to resolve and fix this?
I’ve used the languages HTML, CSS, jQuery, PHP, and mySql commands in PHP.