WordPress.org

Ready to get started?Download WordPress

Forums

Admin site map on Dashboard (5 posts)

  1. Younghusband
    Member
    Posted 9 years ago #

    I am trying to replace the feeds on the Dashboard with a kind of sitemap for the admin with direct links to every submenu for wp-admin. For example:

    WRITE
    - Write Post
    - Write Page

    ...

    OPTIONS
    - General
    - Writing
    - Reading
    - Discussion
    - Permalinks
    - Misc

    etc etc for each category.

    Now here is the twist, instead of simply harcoding it I would like to do this dynamically, like how menu.php is done, so that user level affects the which links appear or not.

    Any tips or help on how I can pull this off?

  2. Kafkaesqui

    Posted 9 years ago #

    You could start by looking over menu.php in wp-admin/ . May not find reusable code in there, but it does list the various menus/submenus, files linked to through them, and allowed user levels.

  3. Younghusband
    Member
    Posted 9 years ago #

    That is what I would like to use as the base. Unfortunately I know jack about how Arrays are used, and so I am stumped. Ideally it would be some sort of code that uses the array from menu.php, but arranges everything in lists, much like the ones listed on the Codex.

  4. Joshua Sigar
    Member
    Posted 9 years ago #

    So, the actual problem is how to convert the array of menus to HTML list? If so, the solution is to learn PHP esp. array and loop, correct?

    Or what is it that you're asking? The coding done for you?

  5. Younghusband
    Member
    Posted 9 years ago #

    Well, first of all, I was wondering if it can even be done, but looking at your mail it looks like it can. This is great news. Do you think it will be difficult? I am only a beginner in PHP but am willing to tackle anything, but if this is an advanced problem in need of advanced skills please let me know. What I would like to do is make the page, then turn over the code to one of the plugin developers and make it a plugin someday to share with everyone.

    I will take your advice and look up array and loop.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags