Plugin Directory

Changeset 2825533


Ignore:
Timestamp:
11/29/2022 12:06:44 AM (3 years ago)
Author:
happyprime
Message:

Updating readme/assets from GitHub

File:
1 edited

Legend:

Unmodified
Added
Removed
  • shadow-terms/trunk/readme.txt

    r2825530 r2825533  
    2020Support can be added to a custom post type with code like:
    2121
    22 ```
    23 <?php
    24 // Register the organization post type normally.
    25 register_post_type( 'organization', $args );
     22    <?php
     23    // Register the organization post type normally.
     24    register_post_type( 'organization', $args );
    2625
    27 // Add support for Shadow Terms to the organization post type.
    28 add_post_type_support(
    29     'organization',
    30     'shadow-terms',
    31     array(
    32         // Add post types that support the organization_connect taxonomy.
    33         'person',
    34         'press-release',
    35     )
    36 );
    37 ```
     26    // Add support for Shadow Terms to the organization post type.
     27    add_post_type_support(
     28        'organization',
     29        'shadow-terms',
     30        array(
     31            // Add post types that support the organization_connect taxonomy.
     32            'person',
     33            'press-release',
     34        )
     35    );
    3836
    3937With the example above, whenever an `organization` is created, a term with the same name will be created under the `organization_connect` taxonomy. When a person or press release is edited, that term will be available for assignment through standard WordPress taxonomy interfaces.
Note: See TracChangeset for help on using the changeset viewer.