Hello,
Can you please share the example. Or reference site. So I can check and let you know the possible solution.
thanks for reply! no worries – i managed to custom code it 🙂
Great!
Still sharing the code snippet which helps for other users too.
Copy below code and add into your child theme:
/**
* Enqueue 'Copy the Code' in wp-admin/backend area.
*
* @todo Change the <code>prefix_</code> and with your own unique prefix.
*
* @since 1.0.0
*/
if( ! function_exists( 'prefix_enqueue_copy_the_code_in_admin' ) ) :
function prefix_enqueue_copy_the_code_in_admin() {
if( is_callable( 'Copy_The_Code_Page::get_instance' ) ) {
add_action( 'admin_enqueue_scripts', array( Copy_The_Code_Page::get_instance(), 'enqueue_assets' ) );
}
}
prefix_enqueue_copy_the_code_in_admin();
endif;
Gist URL for reference – https://gist.github.com/6d102a3d6dbda0c9388fb5caa498c43c
Ah ok thanks for that. I actually coded the entire click-to-copy functionality from scratch LOL.
Hi Mahesh, can I join in this conversation?
I have the same problem as jeffreytay..
I should insert this shortcode:
[crp_referral_link]
It brings up a different link for each user.
when you click on copy and then paste the result is this:
<fieldset><code>https://www.greenhope.it/blog?ref=RIMNLL8</code></fieldset>
In practice, in addition to copying the link, are also copied the elements:
<fieldset><code> links... </code></fieldset>
I would like only the link to be copied.
I state that I don’t have a childe theme. Is there a alternative way? Could you help me please?
Thanks in advance
Marco