I am trying to backup my MySQL Database using PHP. I want to backup it to an .SQL so i can import it back in MySQL if anything goes wrong.
The only problem I found out when i tried to use Exec of System, that these functions are turned of by my host, and their not gonna activate it because of security reasons.
Also I cannot use : SELECT ... INTO OUTFILE.
What my thoughts are :
Is it possible to use SELECT * FROM [Table] and get a php array from that query.
And then push that data into an SQL file?
I cannot find information about this even though I tried some things. I know you can make a .txt file with the right text in it and call it a .sql but then i need to write everything by hand, thats gonna take a while.
Or is their a better way to do this?
Thanks in advance!