i'm trying to create a wordpress plugin that imports some products and i want to be able to log any errors that occur, in a text file. I know that error logging already exists using:
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
but i want to make my own file logging only the errors that occur from my plugin. How can i do that?