Rewrite admin section

Merged
#62 · Created  · Last updated

Merged pull request

Merged in niknetniko/nextcellent/exp/better_admin (pull request #62)

b6dd69b·Author: ·Closed by: ·2016-02-03

Description

This is a pretty large change, since it rewrites large parts of the admin screens. I believe this is a big step forward in cleaning up and improving the old code, without breaking compatibility.

Please note that the pull request has a lot of commits, but a portion of those are reversed later, since I made commits while developing. I'll make an effort to have a clean git history in the future.

Because there are a lot of changes, I will break them up in parts. These changes are mostly behind the scenes.

General

  • Admin pages now extend an interface. This improves the loading of the different pages.

  • A lot of old pages are now refactored to be one class in one file.

  • All edited/converted files now follow the WordPress naming conventions.

  • A lot of HTML was cleaned up, and deprecated tags were removed.

  • Existing classes were converted to the new system and to best practices (private variables and functions were possible).

  • A lot of JavaScript was improved.

  • The installer was refactored to use classes.

  • The image uploader was improved.

  • This also includes a fix for the widgets that produced an error in the upcoming WordPress 4.3.

  • This also include translations updates for Dutch, and an update pot file.

Gallery/image managing

  • The gallery/image managing pages are completely rewritten, using PHP5 and the WordPress API.

  • The relevant files were moved to their own package.

  • For the user this means the managing pages now behave exactly as built-in WordPress.

  • For the user there are now also working screen options, with the WordPress Screen Options API.

  • The row actions (e.g. to make custom thumbnails) were also rewritten with new JavaScript.

  • There are now many advanced options to make thumbnails: rotating, zooming, etc. This fixes issues #21, #27 and #28 (requested by users).

  • Various database statements were optimized to be much faster. I will improve this even more in the future.

Database upgrades

  • Cleaned up the database upgrade notifications.

Backwards compatibility & performance

  • These changes are fully backwards compatible. Changed functions only have additional, optional parameters. All filters and actions will work as before.

  • There are some changes to URLs in the admin section, but I didn't find any plugin the linked directly, so it should be fine.

  • These changes have no noticeable impact on performance or memory usage, and they make parts of the code a lot more readable.

If a conflict occurs due to the merging of another pull request, I'll update this one. I have added inline PHP documentation as well, so it should be clear what everything does. If you do have questions, feel free to ask.

I have tested the changes and did not find errors, but if you do find them, feel free to tell me, so that I can fix them.

0 attachments

0 comments

Loading commits...