I have a PHP code with 2 pages.
Page 1: allows for loading of variable inputs into several arrays and then into several SESSION variables created using these arrays.
Page 2: creates and displays a png utilizing all the SESSION variables and using “imagecreate”.
Sometimes, randomly, page 2 does not always load all the SESSION variables before the pgn is created, leading to a malformed image.
Refreshing page 2 then creates the correct image, confirming that all the SESSION variables are finally being passed to page 2.
Can the png creation be delayed until after all SESSION variables are loaded or is there another solution?