Is there a way to use the wordpress theme / plugin editor inside my plugin to give the user the ability to edit the css file of my plugin ?
Im building a plugin that gives the user an option to add some CSS. First i was going to use just a textarea but then i thought it would be pretty could if i can use the WordPress editor that will open my style.css file.
I could put just a link to http://www.xxxxxx.com/wp-admin/plugin-editor.php but it would be great if i can integrate it into my plugin.
Regards
To start with you could use the following code. For security you could also add some nonce check and even use the settings api. Here
plugin-test
is your plugin folder name.If you are looking for some more complex solution I wrote WP Custom File Editor plugin based on code from Thesis theme http://diythemes.com/