What I want to do is this:
- Create an .html or .php page
- Write HTML code and creating an element that looks like an Identity card. Writing CSS in same file in style tags.
- Writing some JS in script tags to alter some properties of HTML code.
Using html2canvas library to convert that Identity card in a photo and store the image (By converting the canvas to image) in database using appropiriate JS functions.
In a separate main file, calling ajax function to execute .html or .php page I have created above.
Is it possible? I want to do this so that users can't see this process. They would see only image that I've stored in database, that I would fetch later.
NOTE: I can do this process on same page without any problem. But I want to do it in a separate page using ajax.