Passing function arguments via a shortcode

You can absolutely pass arguments to your shortcode, but not in the method you described. Please see the Shortcode API (https://codex.wordpress.org/Shortcode_API) Your shortcode with arguments will look more like: [vertical_posts label=Answers category=answers number=4]

Create a new account on site B with data from the purchase of site A

I managed to solve via CURL requests via PHP, the code is as follows. functions.php of site A: add_action( ‘woocommerce_order_status_completed’, ‘change_role_on_purchase’ ); function change_role_on_purchase( $order_id ) { $order = new WC_Order( $order_id ); $items = $order->get_items(); foreach ( $items as $item_id => $item ) { $product_id = $item->get_variation_id() ? $item->get_variation_id() : $item->get_product_id(); if ( $product_id … Read more