Access plugin php using wp-admin/admin.php url
-
I have the plugin with folder/files and I am using the plugin in admin dashboard.
Folder: views
actions.php
client_register.phpAnd I created one menu like this
add_submenu_page("custom", "Client Registration", "New Client Site",'manage_options', "client_register", 'page_client_register'); if ( ! function_exists( 'page_client_register' ) ) { function page_client_register(){ render_page_client_register(); } }
And I am able to call the
page_client_register
function (which is actually a independent php file) like this.
https://127.0.0.1/wp-admin/admin.php?page=client_register
This is possible because I created the menu.How can I access other files similar to that way?
usingwp-admin/admin.php
urlIf I directly call the files like
https://127.0.0.1/wp-content/plugins/<pluginname>/views/actions.php
it says Direct PHP ACCESS is not allowed in some cloud sites.How can I access these files using
wp-admin/admin.php
?
- The topic ‘Access plugin php using wp-admin/admin.php url’ is closed to new replies.