Copy The Code Wordpress Plugin - Rating, Reviews, Demo & Download

Copy The Code Preview Wordpress Plugin - Rating, Reviews, Demo & Download
No ratings yet
Free
Follow for free plugins, new theme releases and theme news

Plugin Description

Plugin add the Copy button within the <pre> tag and it copy the content of <pre> tag into the clipboard.

1. How it Works?

Simply, It search the <pre> tag within the page and add the Copy button within it.

2. It add `Copy` button for each `

` tag?

Yes, Once you activate the plugin it add search the <pre> tag and add the Copy button in it.

3. Can I use another selector instead of `

` tag?

Yes, You can change the selector though filter copy_the_code_localize_vars.

Eg. If you want to enable the Copy button for only single page, post etc. Then You can change the selector body.single pre though filter.

add_filter( 'copy_the_code_localize_vars', 'my_slug_copy_the_code_localize_vars' );
function my_slug_copy_the_code_localize_vars( $defaults )
{
    // `single class is added to the `` tag for the single page, post etc.
    $defaults['selector'] = 'body.single pre';

    return $defaults;   
}

4. Plugin compatible for all themes?

Yes, We have added !important for the Copy button to keep the button style same for each theme. We have tested below themes.

Theme: Bhari

Theme: Astra

Theme: AwesomePress

Theme: Storefront

Theme: OceanWP

Theme: Twenty Twelve

Theme: Twenty Sixteen

Theme: Twenty Seventeen

Extend the plugin on Github

Screenshots


Reviews & Comments