select into outfile

I have a php script and I am trying to make

select * from registro into outfile "file.csv"   

but fails, also I tried it from myphpAdmin and the system says

#1045 - Access denied for user 'epiz_23186001'@'192.168.%' (using password: YES)

Any idea to export a table using php?

thanks

I'm sorry, but `select into outfile` is not possible on free hosting. The databases are on separate servers, and you can't access files on those servers anyways.

To dump the contents of a table to a CSV file, you can either use phpMyAdmin's Export feature to export the table to CSV, or you can write a custom PHP script which reads all the rows from the table and writes it to a file itself (using `file_put_contents`, `fwrite` or similar functions).