Support

Search results for ""

Sorry, no results found. Perhaps you would like to search the community forum?
All Topics
menzer

Adding information above the table & filter boxes

Hi I need to information above the admin column pro filter table, is there a hook I can latch on to to do this? I just cannot seem to find it

1 month ago
Stefan
Developer

Yes, there is a default WordPress hook for that, we use it ourselves to add our own logic.
The hook is called `restrict_manage_{type}’.

restrict_manage_posts

restrict_manage_users

restrict_manage_comments

If you really want to place some things above, you can use JS to move it in the DOM, we also do that since we’re also limited to the position this hook gives us. Let me know if you have any further questions.

1 month ago
menzer

Thanks for yoour quick response Stefan, I really appreciate it, I would love to put somethings above, I just tried the hook your suggested but it places the info inbetween the ‘Add Filter’ button and calendar dropdown, so how do I use JS to move it in the DOM and hook into the above area, any help would be appreciated (I only need an example and I will learn from there)

Thanks once again

1 month ago
Stefan
Developer

You’re welcome. This is not really ACP logic but let me send you some useful links.
If you like to use Jquery which is already available in the WordPress Admin, you probably want to have a look at the manipulation methods of Jquery:

https://api.jquery.com/category/manipulation/dom-insertion-outside/

So make sure that the elements that you add with the hook have a unique ID or class so you can target them with Jquery and move them to any element in the DOM where you like.

1 month ago

You must be logged in to reply to this topic.