Attributes array not saving values

The best way to achieve what i was wanting to do was to use the core blocks for latest post. Then style as I needed to. Here is what my code looks like. import { registerBlockType } from “@wordpress/blocks”; import { __ } from “@wordpress/i18n”; import { useBlockProps, InnerBlocks, } from “@wordpress/block-editor”; registerBlockType(‘sfs-test-header-para-block/sfs-test-header-para-container-block’, { title: … Read more

Display box in sidebar of custom post type

It’s really easy, it’s called meta box and you can create one with the following code. /** * Register meta box(es). */ function plugin_prefix_register_meta_boxes() { add_meta_box( ‘meta-box-id’, __( ‘My Meta Box’, ‘textdomain’ ), ‘plugin_prefix_my_display_callback’, ‘custom_post_type’ ); } add_action( ‘add_meta_boxes’, ‘plugin_prefix_register_meta_boxes’ ); /** * Meta box display callback. * * @param WP_Post $post Current post object. … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)