custom url with custom post

You can omit the “base”, by adding rewrite => array( slug => ‘item’, with_front => false, ), Don’t forget to flush your rewrite rules after you changed that. The easiest way to do so it to simply visit the “admin > settings > permalinks” page. If you need to add that to an already registered … Read more

add_media_page function not creating submenu

Whenever you would use a class method within add_action function, then within the array parameter, you have to pass an instance of that class as the first value and then you the method name as the second value of the array. In your code, you did not pass any instance actually. And that’s why it … Read more