Uncategorized

Standardization of metadata in WordPress

Problem: Plugin and theme developers have no common naming scheme for post types and metadata, and they are not being properly registered.

Why it matters: If a common set of terms were used, it would allow users to easily migrate between multiple plugins of a given type (from one eCommerce plugin to another, for example), allow multiple plugins to work seamlessly with the same set of data.  In addition, by properly naming and registering metadata, it would allow for broader use of the API, as associated and related metadata would be easily accessed, understood and manipulated.

How to solve this: I would envision a solution which would involve the following:

  1. Consider requests to access/modify non-registered meta to be deprecated, and send up notices when WP_DEBUG is turned on
  2. When registering a new custom post type, allow a schema to be registered as well, for example:
    $args = array(
      'public' => true,
      'label'  => 'Event',
      'schema' => 'http://schema.org/Event'
    );
    register_post_type( 'event', $args );
  3. Allow developers to identify schemas used in the readme.txt
  4. ???
  5. Profit!
Standard

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s