Plugin Directory

Changeset 2334762


Ignore:
Timestamp:
07/03/2020 10:21:37 AM (6 years ago)
Author:
gsayed786
Message:

Add get post and get posts apis

Location:
headless-cms/trunk
Files:
2 added
4 edited

Legend:

Unmodified
Added
Removed
  • headless-cms/trunk/headless-cms.php

    r2333762 r2334762  
    88 * License:     GPL2
    99 * License URI: https://www.gnu.org/licenses/gpl-2.0.html
    10  * Version:     1.0.1
     10 * Version:     1.0.2
    1111 * Text Domain: headless-cms
    1212 *
  • headless-cms/trunk/inc/classes/class-category.php

    r2333730 r2334762  
    7878            <td>
    7979                <?php
    80                     $image_id = get_term_meta( $term->term_id, 'category-image-id', true );
    81                     $add_image_class = ! empty( $image_id ) ? 'hcms_hide' : '';
     80                    $image_id           = get_term_meta( $term->term_id, 'category-image-id', true );
     81                    $add_image_class    = ! empty( $image_id ) ? 'hcms_hide' : '';
    8282                    $remove_image_class = empty( $image_id ) ? 'hcms_hide' : '';
    8383                ?>
     
    8989                </div>
    9090                <div>
    91                     <input type="button" class="button button-secondary hcms_tax_media_button <?php esc_attr_e( $add_image_class ); ?>" id="hcms_tax_media_button" name="hcms_tax_media_button" value="<?php esc_html_e( 'Add Image', 'headless-cms' ); ?>" />
    92                     <input type="button" class="button button-secondary hcms_tax_media_remove <?php esc_attr_e( $remove_image_class ); ?>" id="hcms_tax_media_remove" name="hcms_tax_media_remove" value="<?php esc_html_e( 'Remove Image', 'headless-cms' ); ?>" />
     91                    <input type="button" class="button button-secondary hcms_tax_media_button <?php echo esc_attr( $add_image_class ); ?>" id="hcms_tax_media_button" name="hcms_tax_media_button" value="<?php esc_html_e( 'Add Image', 'headless-cms' ); ?>" />
     92                    <input type="button" class="button button-secondary hcms_tax_media_remove <?php echo esc_attr( $remove_image_class ); ?>" id="hcms_tax_media_remove" name="hcms_tax_media_remove" value="<?php esc_html_e( 'Remove Image', 'headless-cms' ); ?>" />
    9393                </div>
    9494            </td>
  • headless-cms/trunk/inc/classes/class-plugin.php

    r2333730 r2334762  
    2525        Assets::get_instance();
    2626        Customizer::get_instance();
     27        Get_Post_Api::get_instance();
     28        Get_Posts_Api::get_instance();
    2729        Header_Footer_Api::get_instance();
    2830        Home_Page_Api::get_instance();
  • headless-cms/trunk/readme.txt

    r2333744 r2334762  
    11=== Headless CMS ===
    22Contributors: gsayed786
    3 Tags: headless-cms, decoupled
     3Tags: headless-cms, decoupled, graphql
    44Requires at least: 4.6
    55Tested up to: 5.4.2
     
    1515A WordPress plugin that adds following features to use WordPress as a headless CMS with any front-end environment using REST API
    1616This plugin provides multiple features and you can use the one's that is relevant to your front-end application. You don't necessarily need to use all.
    17 
    18 [Github-repo](https://github.com/imranhsayed/headless-cms)
    1917
    2018== Features ==
     
    43413. Get header and footer date: ( GET Request )
    4442* Get the header data ( site title, site description , site logo URL, menu items ) and footer data ( footer menu items, social icons )
    45 * `http://example.com/wp-json/rae/v1/header-footer?header_location_id=primary&footer_location_id=secondary`
     43* `http://example.com/wp-json/rae/v1/header-footer?header_location_id=hcms-menu-header&footer_location_id=hcms-menu-footer``
    4644
    47454. Get posts by page no: ( GET Request )
Note: See TracChangeset for help on using the changeset viewer.