I have seen one other post with the issue but I don’t know if there is a clear resolution. The error says
“There seems to be an error initializing. Please verify you are using an up-to-date web browser.
Also check the WP REST API isn’t disabled by a security plugin. Feel free to contact Print My Blog support.”
/wp-json/
in the url.https://domain.com/wp-json/wp2/
…. instead it is https://domain.com/wp2/
"jetpack-related-posts": [
],
Any ideas? Thanks for the help.
]]>public static function wallet_post_type_args() {
return apply_filters( 'hrw_wallet_post_type_args' , array(
'labels' => array(
'name' => esc_html__( 'All Wallet' , HRW_LOCALE ) ,
'singular_name' => esc_html__( 'All Wallet' , HRW_LOCALE ) ,
'all_items' => esc_html__( 'All Wallet' , HRW_LOCALE ) ,
'menu_name' => esc_html_x( 'All Wallet' , 'Admin menu name' , HRW_LOCALE ) ,
'add_new' => esc_html__( 'Add Wallet' , HRW_LOCALE ) ,
'add_new_item' => esc_html__( 'Add New Wallet' , HRW_LOCALE ) ,
'edit' => esc_html__( 'Edit' , HRW_LOCALE ) ,
'edit_item' => esc_html__( 'Edit Wallet' , HRW_LOCALE ) ,
'new_item' => esc_html__( 'New Wallet' , HRW_LOCALE ) ,
'view' => esc_html__( 'View Wallet' , HRW_LOCALE ) ,
'view_item' => esc_html__( 'View Wallet' , HRW_LOCALE ) ,
'view_items' => esc_html__( 'View Wallet' , HRW_LOCALE ) ,
'search_items' => esc_html__( 'Search Users' , HRW_LOCALE ) ,
) ,
'description' => esc_html__( 'Here you can able to see list of Wallet' , HRW_LOCALE ) ,
'public' => true ,
'show_ui' => true ,
'capability_type' => 'post' ,
'publicly_queryable' => true ,
'exclude_from_search' => false ,
'hierarchical' => false , // Hierarchical causes memory issues - WP loads all records!
'show_in_nav_menus' => true ,
'show_in_menu' => 'hrw_wallet' ,
'menu_icon' => HRW_PLUGIN_URL . '/assets/images/dash-icon.png' ,
'supports' => array('title', 'editor','custom-fields'),
'show_in_rest' => true,
'show_in_graphql' => true,
'graphql_single_name' => 'hrwwallett',
'graphql_plural_name' => 'hrwwalletts',
'query_var' => true ,
'map_meta_cap' => true ,
// 'rewrite' => false ,
'capabilities' => array(
'create_posts' => 'do_not_allow' ,
)
)
) ;
}
]]>I aim to have the plugin automatically assign lottery ticket numbers to orders made via the API based on the order quantity.
Could someone provide guidance or examples on how to structure order requests using the WP REST API in a way that aligns with the WooCommerce Lottery plugin’s ticket assignment mechanism? Any insights or code snippets would be greatly appreciated.
So I tested out the order request via the WP REST API and realized that in using the WordPress REST API Endpoint to make orders to the lottery site, ticket selection or assigning is not possible.
Orders made via the API are created successfully but then no ticket is assigned and when you check the lottery history tabs all purchases or orders via the API have ZERO as their ticket numbers.
But for ticket purchases or orders made directly on the site, everything works as it should
]]>I’ve tried looking around the forum but I can’t find anyone with the exact same problem as me.
I get this in the admin dashboard :
Here is an error associated with Connecting WP REST API
Please Flushing rewrite rules by updating permalink in Settings->Permalinks and make sure the WP REST API is enabled.
I tried :
Flushing Permalink Settings
Checking REST API status (I’ll come back to this later on)
Check for plugin conflicts
Check your .htaccess file
None of them are causing the issue. The only thing that I could find that could help me (or anyone) to get this problem out of the way is when I try to go to “https://domain.com/wp-json/wp-statistics/v2/check”, this comes back :
{“code”:”rest_no_route”,”message”:”No route was found matching the URL and request method.”,”data”:{“status”:404}}
Moreover, when I go to “https://domain.com/wp-json/”, it seems to respond well.
Any idea how to solve that issue ? thanks
The JSON result from WordPress www.domain_name/wp-json/wp/v2/posts can only show the registered user (author) who has created the post. How do I retrieve the override name (guest_author_name), I want to show on mobile app the guest_author_name instead of a user who posted.
]]>