PluginProbe
Copy Anything to Clipboard for WordPress – Copy Button, Copy Text & Copy Code / 5.5.4
Copy Anything to Clipboard for WordPress – Copy Button, Copy Text & Copy Code v5.5.4
5.5.4 5.5.3 3.1.0 3.2.0 3.2.1 3.3.0 3.4.0 3.4.1 3.4.2 3.4.3 3.5.0 3.5.1 3.5.2 3.6.0 3.7.0 3.8.0 3.8.1 3.8.2 3.8.3 4.0.0 4.0.2 4.0.3 4.0.4 4.0.5 4.1.0 All 79 releases
← All changes | readme.txt +632 -163 3.6.0 → 5.5.4 View file →
@@ -1,195 +1,700 @@
1 -=== Copy Anything to Clipboard ===
2 -Contributors: Mahesh901122, freemius
1 +=== Copy Anything to Clipboard for WordPress – Copy Button, Copy Text & Copy Code ===
2 +Contributors: clipboardagency, freemius
3 3 Donate link: https://www.paypal.me/mwaghmare7/
4 -Tags: Clipboard, Copy, Copy to Clipboard, Coupon, Deal
5 -Tested up to: 6.4.3
6 -Stable tag: 3.6.0
4 +Tags: clipboard, copy to clipboard, copy code, elementor, shortcode
5 +Tested up to: 7.1.3
6 +Stable tag: 5.5.4
7 7 Requires PHP: 5.6
8 8 Requires at least: 4.4
9 9 License: GPLv2 or later
10 10 License URI: https://www.gnu.org/licenses/gpl-2.0.html
11 11
12 +Copy Anything to Clipboard is the #1 WordPress copy-to-clipboard plugin trusted by 10,000+ active websites with 352,151+ downloads 🚀. Instantly add smart copy buttons to text, code, coupon codes, links, prompts, emails, or any content with built-in analytics and powerful Global Injector controls.
13 +
12 14 == Description ==
13 15
14 -**[Copy Anything to Clipboard](https://clipboard.agency/)** is the #1 WordPress plugin with **1,80,599+** downloads 🚀
16 +**Copy Anything to Clipboard** helps visitors copy **text, links, coupon codes, commands, email addresses, AI prompts, and code snippets** in one click—no awkward text selection on mobile, no broken formatting in the clipboard.
15 17
18 +Use it on **blogs, docs, WooCommerce and deal sites, SaaS landing pages, tutorials, and support hubs** where you want fewer “how do I copy this?” questions and smoother sharing of URLs, promos, and technical steps.
16 19
17 -Get up to 20% to 30% discount by [upgrading to pro](https://clipboard.agency/#pricing), make this shopping extravaganza unforgettable! 🎁
20 +**Why site owners install it**
18 21
22 +* **Better UX** – Especially on touch devices, a dedicated copy control beats “long-press to select.”
23 +* **Higher intent actions** – Coupon codes, affiliate links, and checkout snippets convert better when copying is frictionless.
24 +* **Flexible placement** – Target elements automatically, or drop shortcodes/blocks only where you need them.
19 25
20 -== # How to use
26 +**Integration options**
21 27
22 -There are 3 wasy to use the "Copy Anything to Clipboard" plugin.
28 +* **Global Injector** – Rules that match **CSS selectors** (e.g. `pre`, `code`, `.coupon`) plus **display conditions** and live preview.
29 +* **Classic CSS selector rules** – Site-wide automatic copy buttons for matching markup.
30 +* **Shortcodes** – `[copy]` (alias: `[ctc]`) for precise placement in the editor, widgets, and templates.
31 +* **Elementor** – 25+ widgets for common patterns (code, coupon, email, prompt, deal link, and more).
32 +* **Gutenberg** – Native blocks for the block editor.
23 33
24 -1. [Automatically with "CSS Selector"](https://clipboard.agency/doc/usage/css-selectors/)
25 -2. [Manually with "Shortcode"](https://clipboard.agency/doc/usage/shortcode/)
26 -3. Manually with "Elementor widgets"
34 +**Highlights**
27 35
28 -=== # METHOD 1 – Automatically with "CSS Selector"
36 +* **Button, Icon, and Cover** presets; copy as **plain text** or **HTML** where supported.
37 +* **Performance-minded** – Combine display conditions with how you publish rules so assets run where copy UI is actually used.
38 +* **Works with typical WordPress stacks** – Themes, builders, and caching setups; mobile and modern desktop browsers.
29 39
30 -This is the quick, most useful way and is mostly used by a lot of users with this plugin.
40 +---
31 41
32 -Use this method, if you want to add the copy button automatically to all the elements with the same selector.
42 +=== How to use ===
33 43
34 -E.g. If youre website post contain the code snippet's in the `<pre>` tag then by setting the `pre` tag as selector in "Copy Anything to Clipboard" will add the copy button to all the `pre` tags.
44 +You can add copy buttons anywhere on your WordPress site using one of the following methods:
35 45
36 -So, Youre user can copy the code snippet with just a click.
46 +1. **EASY: [Shortcodes](https://docs.clipboard.agency/guides/shortcodes/)**
47 + Manually add copy controls with `[copy]` anywhere in your content.
37 48
38 -**Example 2:** You're blog post has the blockquote and you want to add the copy button to the blockquote.
49 +2. **AUTOMATIC: [Global Injector](https://docs.clipboard.agency/guides/global-injector/)**
50 + Automatically inject copy buttons into any element using [CS selectors](https://docs.clipboard.agency/guides/css-selectors/) like `pre`, `code`, `blockquote`, or any custom selector with advanced display conditions.
39 51
40 -==== How to use with CSS Slector?
52 +3. **Elementor Widgets**
53 + Add copy buttons visually using dedicated Elementor widgets.
41 54
42 -- **Step 1** – Go to “Copy to Clipboard”
43 -- **Step 2** – Click on the “Add New” button
44 -- **Step 3** – Add the selector. E.g. `pre` or `blockquote`
45 -- **Step 4** – Click on “Create”
46 -- **Step 5** – Visit the page and see the copy button
55 +4. **Gutenberg Blocks**
56 + Insert copy buttons directly inside the WordPress block editor using Gutenberg blocks.
47 57
48 -For more details read:
58 +=== METHOD 3 – Manually with "Shortcodes" ===
49 59
50 -- [Add the copy button to Blockquote](https://clipboard.agency/blog/add-copy-button-to-blockquote/)
51 -- [Add the copy button to Code Snippet](https://clipboard.agency/blog/add-copy-button-to-code-snippet/)
60 +Use **`[copy]`** anywhere you want an explicit copy control (Classic editor, **Shortcode** block, widget areas, patterns, or PHP templates via `do_shortcode()`). **`[ctc]`** is the same shortcode with a shorter name—use either.
52 61
53 -=== # METHOD 2 – Manually with "Shortcode"
62 +**How it works (matches the plugin code)**
54 63
55 -You can use this method if you want to add the copy button to the specific element.
64 +* **Default** layout is the **inline** preset (clickable text + icon). Switch with **`preset="button"`**, **`preset="icon"`**, or **`preset="cover"`**.
65 +* **`text="…"`** (or text wrapped between `[copy]` and `[/copy]`) is what lands on the clipboard.
66 +* **`display="…"`** overrides the visible label when it must differ from the copied string (masked secrets, mailto links, etc.).
67 +* **Legacy pair:** **`text="…"`** + **`content="…"`** — `content` is copied, `text` is what visitors see (handy for hiding long URLs behind a short CTA).
56 68
57 -Use the shortcode `[copy]` or `[copy_inline]` shortcodes.
69 +**Try it on a fresh install** — add a **Shortcode** block (or switch the block editor to **Code editor**), paste one snippet, **Update**, view the page, and tap the control.
58 70
59 -E.g.
71 +==== Example 1 – Datetime inside a sentence ====
60 72
61 -<code>
62 -The zoom meeting is scheduled on data [copy]15 November 2022[/copy] please note down it.
63 -</code>
73 +<pre>
74 +Next live workshop: [copy]2030-03-19 10:00 America/New_York[/copy] — copy the full value for your calendar tool.
75 +</pre>
64 76
65 -==== How to use with Shortcode?
77 +==== Example 2 – Email inside a sentence ====
66 78
67 -You may use the shortcode `[copy_inline]` to copy the inline content.
79 +<pre>
80 +Billing questions? Email [copy][email protected][/copy] and include your order ID.
81 +</pre>
68 82
69 -E.g.
83 +==== Example 3 – Show the mailbox, copy a ready-made mailto link ====
70 84
71 -<code>
72 -Contact us:
85 +<pre>
86 +[copy display="[email protected]"]mailto:[email protected]?subject=Question%20from%20website[/copy]
87 +</pre>
73 88
74 -- Email: [copy_inline text="[email protected]"]
75 -- Phone: [copy_inline text="+91 1234567890"]
76 -- Address: [copy_inline text="123, Street, City, State, Country"]
77 -- Website: [copy_inline text="https://clipboard.agency/"]
78 -- Facebook: [copy_inline text="https://www.facebook.com/clipboard.agency/"]
79 -</code>
89 +Visitors see **[email protected]**; the clipboard receives the full **mailto:** string with the subject line.
80 90
81 -Or, Use it as coupon code:
91 +==== Example 4 – Mini support block (swap in your real IDs) ====
82 92
83 -<code>
84 -Use coupon code [copy_inline text="COUPONCODE"] to get 10% discount.
85 -</code>
93 +<pre>
94 +Before you open a ticket, include:
86 95
87 -Or, Use it as deal:
96 +- Order ID: [copy]WC-104592-UK[/copy]
97 +- Line item SKU: [copy]BM-HOODIE-M-NVY[/copy]
98 +- Return auth: [copy]REF-88C0A921[/copy]
99 +</pre>
88 100
89 -<code>
90 -Get the deal [copy_inline text="https://clipboard.agency/deal/"] to get 10% discount.
91 -</code>
101 +==== Example 5 – Coupon inside marketing copy ====
92 102
93 -Or, Use for username and password:
103 +<pre>
104 +Launch week only — use [copy]SPRINGLAUNCH26[/copy] at checkout for 25% off your first year.
105 +</pre>
94 106
95 -<code>
96 -Username: [copy_inline text="username"]
97 -Password: [copy_inline text="password" display="*********"]
98 -</code>
107 +==== Example 6 – Long store URL, short friendly label ====
99 108
100 -=== # METHOD 3 – Manually with "Elementor Widgets"
109 +<pre>
110 +[copy text="https://www.amazon.com/dp/B0D1EXAMPLE/ref=nosim?tag=clipboard0d-20"]Copy our Amazon pick[/copy]
111 +</pre>
101 112
102 -We build coupole of different widgets for Elementor page builder.
113 +The visitor reads **Copy our Amazon pick**; the clipboard gets the full tagged URL.
103 114
104 -You can use the following widgets to add the copy button to the specific element.
115 +==== Example 7 – Carrier-style tracking number ====
105 116
106 -- [Email Samples](https://clipboard.agency/demos/#email-samples) 📧 <br/>Elevate your email communication by referring to our collection of samples. Dive into the intricacies of crafting impactful emails.
107 -- [ChatGPT Prompt's (AI)](https://clipboard.agency/demos/#chatgpt-prompts-ai) 🤖 <br/>Harness the power of AI with ChatGPT prompts. Learn how to create effective prompts for dynamic interactions.
108 -- [Coupon Codes](https://clipboard.agency/demos/#coupon-codes) 💸 <br/>Optimize your savings with our guide on utilizing coupon codes effectively.
109 -- [Deals](https://clipboard.agency/demos/#deals) 🛍️<br/>Explore exclusive deals and promotions to make the most of your shopping experience.
110 -- [Inspirational Quotes](https://clipboard.agency/demos/#inspirational-quotes) 🌟<br/>Find inspiration in our curated collection of quotes that uplift and motivate.
111 -- [Contact Information](https://clipboard.agency/demos/#contact-information) 📞<br/>Organize and manage your contacts with our intuitive contact information templates.
112 -- [Addresses](https://clipboard.agency/demos/#addresses) 🏡<br/>Simplify address management and ensure accuracy with our address template.
113 -- [Blog Posts](https://clipboard.agency/demos/#blog-posts) 📰<br/>Dive into the world of blogging with tips and templates for creating engaging blog posts.
114 -- [Business Information](https://clipboard.agency/demos/#business-information) 🏢<br/>Streamline your business details and maintain a professional image with our business information templates.
115 -- [Social Media Posts](https://clipboard.agency/demos/#social-media-posts) 📱<br/>Enhance your social media presence with our templates for creating captivating posts.
116 -- [Notes and Reminders](https://clipboard.agency/demos/#notes-and-reminders) 📝<br/>Stay organized and on top of tasks with our note-taking and reminder templates.
117 -- [Bookmarks](https://clipboard.agency/demos/#bookmarks) 📚<br/>Keep track of important web pages and resources with our bookmark templates.
118 -- [Event Details](https://clipboard.agency/demos/#event-details) 🎉<br/>Plan and organize events seamlessly with our event details templates.
119 -- [Travel Information](https://clipboard.agency/demos/#travel-information) ✈️<br/>Make your travels stress-free with templates for organizing essential travel information.
120 -- [Lyrics](https://clipboard.agency/demos/#lyrics) 🎵<br/>Dive into the world of music with our templates for organizing song lyrics.
121 -- [Meeting Notes](https://clipboard.agency/demos/#meeting-notes) 📅<br/>Optimize your meetings with organized and effective meeting note templates.
122 -- [Technical Code](https://clipboard.agency/demos/#technical-code) 💻<br/>Manage and document code efficiently with our technical code templates.
123 -- [Commands](https://clipboard.agency/demos/#commands) 💻<br/>Streamline your workflow with templates for commonly used commands.
124 -- [Legal Documents](https://clipboard.agency/demos/#legal-documents) 📜<br/>Ensure legal compliance and clarity with our templates for various legal documents.
125 -- [Quotes from Books](https://clipboard.agency/demos/#quotes-from-books) 📖<br/>Discover and share impactful quotes from literature with our curated collection.
126 -- [To-Do Lists](https://clipboard.agency/demos/#to-do-lists) 📋<br/>Stay organized and focused on your tasks with our effective to-do list templates.
127 -- [Personal Notes](https://clipboard.agency/demos/#personal-notes) 📖<br/>Capture your thoughts and reflections with our templates for personal notes.
128 -- [Educational Content](https://clipboard.agency/demos/#educational-content) 🎓<br/>Enhance your learning experience with our templates for educational content.
129 -- [Passwords and Codes](https://clipboard.agency/demos/#passwords-and-codes) 🔒<br/>Ensure security and manage your passwords and codes effectively with our templates.
130 -- [Social Media Hashtags ](https://clipboard.agency/demos/#social-media-hashtags-) ️⃣<br/>Boost your social media visibility with effective hashtag usage using our templates.
131 -- [Research Findings](https://clipboard.agency/demos/#research-findings) 📊<br/>Organize and present your research findings professionally with our templates.
132 -- [Travel Packing List](https://clipboard.agency/demos/#travel-packing-list) 🧳<br/>Prepare for your travels efficiently with our comprehensive packing list templates.
133 -- [Love Messages](https://clipboard.agency/demos/#love-messages) 💖<br/>Express your feelings with heartfelt love messages using our templates.
117 +<pre>
118 +Track this shipment: [copy]1Z999AA10123456784[/copy]
119 +</pre>
134 120
135 -==== How to use with Elementor widgets?
121 +==== Example 8 – Developer onboarding (framework installer) ====
136 122
137 -- **Step 1** – “Install and activate the "Elementor" plugin
138 -- **Step 2** – Go to “Add/Edit with Elementor”
139 -- **Step 3** – Search for widget. E.g. "Copy"
140 -- **Step 4** – Drag and drop the widget to the page
141 -- **Step 5** – Set the content
142 -- **Step 6** – Publish the page and see the copy button
123 +<pre>
124 +Run this once: [copy]npx create-next-app@latest my-shop --typescript --eslint --tailwind --app[/copy]
125 +</pre>
143 126
144 -For more details read:
127 +==== Example 9 – One-line WP-CLI maintenance ====
145 128
146 -- [See All Live Demos](https://clipboard.agency/#demos)
129 +<pre>
130 +Safe cache flush: [copy]wp cache flush && wp rewrite flush[/copy]
131 +</pre>
147 132
148 -== # Key Benefits
133 +==== Example 10 – API key visible on screen vs clipboard ====
149 134
150 -- **Copy with Ease**: Say goodbye to highlighting, right-clicking, and copying. Our plugin simplifies the process. 🎉
151 -- **Versatile Solutions**: Copy text, links, codes, and more with just a click. 🌐
152 -- **Seamless Integration**: Works with your existing WordPress site, no hassle. 💼
153 -- **Efficient and User-Friendly**: Save time and frustration when sharing content. ⏱️
154 -- **Cross-Browser Compatibility**: Enjoy consistent performance across all major browsers. 🌐
155 -- **Mobile-Friendly**: Works on all mobile devices, including tablets and smartphones. 📱
156 -- **Lightweight**: Our plugin won’t slow down your site. 🚀
157 -- **Easy to Customize (PRO)**: Customize the look and feel of your copy button. 🎨
158 -- **Developer-Friendly**: Our plugin is easy to integrate with your existing code. 👨‍💻
159 -- **SEO-Friendly**: Our plugin won’t affect your SEO. 📈
135 +<pre>
136 +Production key (rotate after testing): [copy text="sk_live_51QxYzAbCdEfGhIjKlMnOpQrStUvWx0123456789" display="sk_live_…6789"]
137 +</pre>
160 138
161 -== 🤩 FREE and Popular Copy to Clipboard Plugin Ever
139 +Visitors only see the shortened mask; the full secret is still copied once for trusted teammates.
162 140
163 -Over **10,000 thousands plus** active people are empowering their websites with “Copy Anything to Clipboard” – 100% compatible for all themes and plugins.
141 +==== Example 11 – Guest Wi‑Fi card ====
164 142
165 -**Welcome for featured requests**
143 +<pre>
144 +SSID: [copy]Guest-Office-5G[/copy] · Passphrase: [copy text="WinterLake#2026!" display="••••••••••••"]
145 +</pre>
166 146
167 -If you have any suggestion or any featured request then don’t hesitate to <a href="https://clipboard.agency/contact/">contact us</a>.
147 +==== Example 12 – Teams / Meet style link ====
168 148
169 -=== Bug reports
149 +<pre>
150 +Join the stand-up: [copy]https://teams.microsoft.com/l/meetup-join/19%3ameeting_EXAMPLE%40thread.v2/0?context=%7b%22Tid%22%3a%22...%7d[/copy]
151 +</pre>
170 152
171 -Bug reports for “Copy Anything to Clipboard” are welcomed in WordPress <a href="https://wordpress.org/support/plugin/copy-the-code/">support forum</a>.
153 +==== Example 13 – Conference hashtag or emoji drop ====
172 154
173 -=== Further reading
155 +<pre>
156 +Share photos with [copy]#ClipboardAgencyLive2026[/copy] — we monitor that tag all week.
157 +</pre>
174 158
175 -For more info check out the following:
159 +==== Example 14 – Button preset (big tap target, copies a long shell line) ====
176 160
177 -* The [clipboard.agency](https://clipboard.agency/) official website 📌
178 -* The [Contact us](https://clipboard.agency/contact/) 👋
179 -* The [Getting started guide](https://clipboard.agency/doc/) 📃
180 -* All other my [WordPress plugins](https://wordpress.org/plugins/search/mahesh901122/) 💎
181 -* Contribute with plugin [contact us](https://clipboard.agency/contact/) ✨
182 -* Make a [small donation](https://www.paypal.me/mwaghmare7/) for continue FREE support 💪
161 +<pre>
162 +[copy preset="button" button-text="Copy Docker install" text="curl -fsSL https://get.docker.com | sh"]
163 +</pre>
183 164
165 +==== Example 15 – Icon-only control in a tight layout ====
166 +
167 +<pre>
168 +Docker CE (Ubuntu): [copy text="sudo apt-get install docker-ce docker-ce-cli containerd.io" preset="icon" tooltip="Copy apt install line"]
169 +</pre>
170 +
171 +==== Example 16 – Optional open-after-copy URL (great for coupons) ====
172 +
173 +<pre>
174 +[copy preset="button" text="SAVE20" button-text="Copy code & checkout" redirect="https://clipboard.agency/checkout/?coupon=SAVE20"]
175 +</pre>
176 +
177 +==== Example 17 – Cover preset for a code/card preview ====
178 +
179 +<pre>
180 +[copy preset="cover" text="body { margin: 0; font-family: system-ui, sans-serif; }" button-text="Copy CSS"]body { margin: 0; … }[/copy]
181 +</pre>
182 +
183 +The visible card shows the shortened preview; the overlay copies the full CSS string.
184 +
185 +==== Example 18 – Legacy `text` + `content` pair (same idea as Example 6) ====
186 +
187 +<pre>
188 +[copy text="Open the parking map" content="https://maps.app.goo.gl/dQw4w9WgXcQ"]
189 +</pre>
190 +
191 +==== Example 19 – Bank-style reference (dummy data) ====
192 +
193 +<pre>
194 +SEPA reference: [copy]RF18539007547034[/copy]
195 +</pre>
196 +
197 +==== Example 20 – Plain JSON snippet for API testers ====
198 +
199 +<pre>
200 +Paste this body: [copy]{ "event": "signup", "plan": "pro", "trial_days": 14 }[/copy]
201 +</pre>
202 +
203 +=== METHOD 2 – Global Injector (NEW in v5.0.0) ===
204 +
205 +The **Global Injector** is the most powerful way to automatically add copy buttons anywhere on your website.
206 +
207 +It allows you to target elements using CSS selectors and control exactly where the copy buttons appear.
208 +
209 +**Key Capabilities**
210 +
211 +* **Display Conditions** – Show copy buttons only on specific pages, posts, categories, or custom conditions.
212 +* **Multiple Style Presets** – Choose from **Button**, **Icon**, or **Cover** styles with live preview.
213 +* **Advanced Targeting** – Precisely target elements using CSS selectors such as `pre`, `code`, `blockquote`, and more.
214 +* **Performance Optimized** – Plugin assets load only on pages where copy buttons are used.
215 +
216 +==== How to Use Global Injector ====
217 +
218 +1. Go to **Copy to Clipboard → Global Injector** in your WordPress dashboard.
219 +2. Click **Add New Injector**.
220 +3. Enter the **CSS selector** you want to target (for example: `pre`, `code`, or `blockquote`).
221 +4. Select a **style preset** – Button, Icon, or Cover.
222 +5. (Optional) Configure **Display Conditions** to control where the copy button appears.
223 +6. Click **Save** and preview the changes on your site.
224 +
225 +=== METHOD 2 – Automatically with "CSS Selector" ===
226 +
227 +This is the **quickest and most commonly used method**. It automatically adds copy buttons to all elements that match a specific CSS selector.
228 +
229 +Use this method when you want copy buttons to appear **automatically across your entire website** without manually adding them to each element.
230 +
231 +==== Examples ====
232 +
233 +**Example 1 – Code Snippets**
234 +
235 +If your posts contain code snippets inside the `<pre>` tag, simply set the selector to `pre` (without the angle brackets `<` and `>`).
236 +
237 +The plugin will automatically add a **copy button to every `<pre>` element**, allowing visitors to copy code snippets with one click.
238 +
239 +**Example 2 – Blockquotes**
240 +
241 +If you want users to copy quotes from your blog posts, set the selector to `blockquote` (without the angle brackets `<` and `>`).
242 +
243 +A copy button will automatically appear for **all blockquote elements** on your site.
244 +
245 +You can target **any HTML element or custom class** using CSS selectors such as:
246 +
247 +- `pre` - If your posts contain code snippets inside the `<pre>` tag.
248 +- `code` - If your posts contain code snippets inside the `<code>` tag.
249 +- `blockquote` - If you want users to copy quotes from your blog posts.
250 +- `.coupon-code` - If your posts contain coupon codes.
251 +- `.email-address` - If your posts contain email addresses.
252 +- `.copy-this` - If you want to copy specific content.
253 +
254 +==== How to Use with CSS Selector ====
255 +
256 +1. Go to **Copy to Clipboard** in your WordPress dashboard.
257 +2. Click the **Add New** button.
258 +3. Enter the **CSS selector** you want to target (for example: `pre` or `blockquote`).
259 +4. Click **Create** to save the selector.
260 +5. Visit your page and you will see the **copy button automatically added** to the targeted elements.
261 +
262 +For more detailed guides:
263 +
264 +- [Add copy buttons to blockquotes](https://docs.clipboard.agency/guides/shortcodes/)
265 +- [Add copy buttons to code snippets](https://clipboard.agency/blog/how-to-add-copy-buttons-to-code-blocks/)
266 +
267 +=== METHOD 4 – Manually with "Elementor Widgets" ===
268 +
269 +The plugin includes **multiple Elementor widgets** that allow you to easily add copy buttons to specific content on your page.
270 +
271 +Simply drag and drop a widget and configure the content you want visitors to copy.
272 +
273 +These widgets are useful for many types of content including:
274 +
275 +- Emails
276 +- ChatGPT / AI prompts
277 +- Coupon codes
278 +- Deals and affiliate links
279 +- Inspirational quotes
280 +- Contact information
281 +- Addresses
282 +- Social media posts
283 +- Commands and technical code
284 +- Passwords and secure values
285 +- Notes, reminders, and checklists
286 +- Blog content and educational materials
287 +- Hashtags and social media resources
288 +- Research notes and documentation
289 +- Travel information and packing lists
290 +- Personal messages and quotes
291 +
292 +You can explore **live examples for all widgets here:**
293 +
294 +[View Elementor widget demos](https://clipboard.agency/demos/)
295 +
296 +---
297 +
298 +==== How to Use Elementor Widgets ====
299 +
300 +1. Install and activate the **Elementor** plugin.
301 +2. Open a page and click **Edit with Elementor**.
302 +3. Search for the widget (for example: **Copy**).
303 +4. Drag and drop the widget onto the page.
304 +5. Enter the content you want users to copy.
305 +6. Publish the page and test the **copy button**.
306 +
307 +For full examples and widget demos:
308 +
309 +[See all live demos](https://clipboard.agency/#demos)
310 +
311 +---
312 +
313 +=== Key benefits ===
314 +
315 +* **Global Injector** – Selector-based rules, display conditions, and live preview from the admin.
316 +* **One-click copy** – No manual selection; clearer affordances for code, coupons, and contact fields.
317 +* **Multiple presets** – **Button**, **Icon**, and **Cover** layouts to fit dense UI or minimal docs.
318 +* **Builder-native** – Deep **Elementor** coverage plus **Gutenberg** blocks for modern sites.
319 +* **Shortcodes** – `[copy]` / `[ctc]` for surgical placement in the classic editor, widgets, and templates.
320 +* **Mobile and cross-browser** – Tested behavior on common phones and current Chrome, Firefox, Safari, and Edge.
321 +* **Lightweight by design** – Pair rules with conditions so you are not loading UI where it is unused.
322 +* **PRO** – Extra customization, behavior options, and analytics when you need to scale or brand the experience.
323 +
324 +---
325 +
326 +**PRO** adds advanced customization and analytics. Compare plans:
327 +
328 +https://clipboard.agency/pricing/
329 +
330 +---
331 +
332 +=== Trusted by thousands of WordPress sites ===
333 +
334 +**10,000+ active installs** rely on Copy Anything to Clipboard for docs, deals, dev blogs, and support content. It is built to cooperate with **popular themes and page builders** (including Elementor) instead of fighting your layout.
335 +
336 +=== Feature requests ===
337 +
338 +Ideas and edge cases help the roadmap. Share yours:
339 +
340 +https://clipboard.agency/contact/
341 +
342 +**Installation, Elementor, Gutenberg, performance, and HTML vs plain text** are covered in the **FAQ** tab on this plugin page.
343 +
344 +---
345 +
346 +=== Google Chrome Extension ===
347 +
348 +We also provide a **Google Chrome Extension** that allows users to quickly copy content from any website.
349 +
350 +[Chrome Web Store](https://chromewebstore.google.com/detail/copy-anything-to-clipboar/mdljigkhfeiobmhanibkgjkldnabeahl)
351 +
352 +The extension works perfectly alongside the **Copy Anything to Clipboard WordPress plugin**, making it easy to copy text, links, commands, code snippets, and more across the web.
353 +
354 +---
355 +
356 +=== Further reading ===
357 +
358 +* [Website](https://clipboard.agency/)
359 +* [Documentation](https://clipboard.agency/doc/)
360 +* [Live demos](https://clipboard.agency/#demos)
361 +* [Support](https://clipboard.agency/contact/)
362 +* [More plugins on WordPress.org](https://wordpress.org/plugins/search/clipboardagency/)
363 +
364 +If the plugin saves you time, you can support ongoing development here:
365 +
366 +[Support development on PayPal](https://www.paypal.me/mwaghmare7/)
367 +
368 +---
369 +
370 +== FAQ ==
371 +
372 += What is the Global Injector? =
373 +
374 +The **Global Injector** (from v5.0.0) adds copy controls wherever matching elements appear. You define a **CSS selector** (for example `pre`, `code`, or `.promo-code`), pick a **Button**, **Icon**, or **Cover** preset, optionally set **display conditions**, and preview before saving. Open **WordPress Dashboard → Copy to Clipboard → Global Injector**.
375 +
376 += How do I add copy buttons to code snippets? =
377 +
378 +Create a **Global Injector** rule or a classic **CSS selector** entry with selector `pre` or `code`, choose a style, save, and matching code blocks get a copy control (subject to your display conditions).
379 +
380 += Can I add copy buttons only on certain posts or pages? =
381 +
382 +Yes. Use **display conditions** in Global Injector, or use **shortcodes** only where you need them (`[copy]` or `[ctc]`).
383 +
384 += Does this plugin work with Elementor? =
385 +
386 +Yes. With Elementor active, edit a page, search the panel for **Copy**, and use the dedicated widgets (copy button, code snippet, coupon, prompts, and more).
387 +
388 += Does this plugin work with Gutenberg? =
389 +
390 +Yes. Insert the bundled blocks (for example **Copy Button** and **Copy Icon**) from the block inserter.
391 +
392 += Can I customize how the copy control looks? =
393 +
394 +Yes—styles, colors, placement, and labels are configurable in the admin. **Global Injector** includes a **live preview**. Deeper styling and analytics are part of **PRO**.
395 +
396 += How can I control where copy buttons appear? =
397 +
398 +Use **display conditions** in Global Injector to limit rules by post type, taxonomy, individual content, user role, and more so design and asset loading stay intentional.
399 +
400 += Is the plugin mobile friendly? =
401 +
402 +Yes. Copy actions are built for phones and tablets as well as desktop.
403 +
404 += Does it work in all browsers? =
405 +
406 +Yes. Current versions of **Chrome**, **Firefox**, **Safari**, and **Edge** are supported.
407 +
408 += Will this plugin slow down my website? =
409 +
410 +It is built to stay lightweight. Combine **display conditions** with how you scope rules so scripts and styles load where copy UI is actually used.
411 +
412 += Can I copy one value but show a different label? =
413 +
414 +Yes. The legacy `content` attribute is what gets copied. Inner shortcode text is the visible label. Example: `[copy content="/path/to/file"]Install path[/copy]` copies `/path/to/file` and shows **Install path**.
415 +
416 += Can the plugin copy HTML as well as plain text? =
417 +
418 +Yes. Depending on settings and shortcode attributes, content can be copied as **plain text** or **HTML**, which helps with code snippets and formatted excerpts.
419 +
420 += Where can I read documentation or get support? =
421 +
422 +Guides: https://clipboard.agency/doc/ — Contact: https://clipboard.agency/contact/
423 +
424 +---
425 +
426 +== Screenshots ==
427 +
428 +1. **Global Injector – Copy Button Rules**
429 +Add and manage automatic copy button rules with **CSS selectors, display conditions, and style presets** like Button, Icon, and Cover.
430 +
431 +2. **Copy Buttons on the Frontend**
432 +Copy buttons automatically appear on **code snippets, blockquotes, commands, coupon codes, or any content element**.
433 +
434 +3. **Shortcodes and Gutenberg Blocks**
435 +Add copy controls manually with `[copy]` / `[ctc]`, or use **Copy Button** and **Copy Icon** blocks in the WordPress block editor.
436 +
437 +---
438 +
184 439 == Installation ==
185 440
186 -1. Install the <code>Copy Anything to Clipboard</code> plugin either via the WordPress plugin directory, or by uploading the files to your server at <code>wp-content/plugins</code>.
441 +You can go from zero to working copy buttons in a few minutes—install the plugin, activate it, then add either a **Global Injector** rule or a **shortcode** on a test page.
187 442
443 +1. Install **Copy Anything to Clipboard** from this directory, or upload the plugin folder to:
444 +
445 +<pre>
446 +wp-content/plugins
447 +
448 +</pre>
449 +2. Activate the plugin through the **Plugins** menu in WordPress.
450 +
451 +3. Go to **WordPress Admin → Copy to Clipboard**.
452 +
453 +4. Choose one of the following methods to add copy buttons:
454 +
455 +- **Global Injector (Recommended)**
456 + Automatically inject copy buttons using CSS selectors and display conditions.
457 +
458 +- **CSS Selector**
459 + Automatically add copy buttons to elements like `pre`, `code`, or `blockquote`.
460 +
461 +- **Shortcodes**
462 + Manually add copy controls using `[copy]` or `[ctc]`.
463 +
464 +- **Elementor Widgets**
465 + Drag-and-drop widgets for Elementor page builder.
466 +
467 +- **Gutenberg Blocks**
468 + Use native WordPress blocks for copy buttons and icons.
469 +
470 +For full setup instructions, read the documentation:
471 +
472 +https://clipboard.agency/doc/
473 +
474 +---
475 +
476 +== Blocks ==
477 +
478 +This plugin provides **4 blocks for the WordPress block editor**:
479 +
480 +### Copy Icon
481 +Add a small icon that lets users quickly copy text or code to the clipboard.
482 +
483 +### Copy Button
484 +Add a visible button that allows users to copy content with one click.
485 +
486 +### Term Title
487 +Display the title of the current taxonomy term such as category or tag.
488 +
489 +### Social Share
490 +Allow visitors to quickly share content across social media platforms.
491 +
188 492 == Changelog ==
189 493
494 += 5.5.4 =
495 +
496 +* **Fix: Blank admin dashboard / Global Injector pages** – Full-bleed React admin screens (Dashboard, Global Injector, Rules list, Analytics) no longer collapse under `#wpbody`, which previously clipped content below the header. Thanks to [@deartanker](https://wordpress.org/support/users/deartanker/) for reporting. See: https://wordpress.org/support/topic/dashboard-page-is-blank-2/
497 +* **Fix: Elementor widget assets loading on every page** – Elementor widgets now register styles/scripts and let Elementor enqueue them only when the widget is present, instead of loading all widget assets on every Elementor page. Copy buttons still load the shared core script when needed.
498 +* **Improvement: Freemius first-path** – Freemius activation and account screens now use the Dashboard (`page=ctc`) instead of the Global Injector editor, so Add New Rule is not taken over during opt-in.
499 +* **Improvement: WordPress 7.1.3 compatibility** – Confirmed Tested up to WordPress 7.1.3.
500 +
501 += 5.5.3 =
502 +
503 +* **Improvement: WordPress 6.9 compatibility** – Confirmed Tested up to WordPress 6.9.
504 +* **Docs: [copy] `content` vs inner label** – FAQ now documents that `content` is the clipboard payload and inner shortcode text is the visible label (for example `[copy content="/path/to/file"]Install path[/copy]`).
505 +* **Improvement: Telemetry endpoint** – Opt-in usage telemetry now posts to `signals.surror.workers.dev`.
506 +* **Improvement: Freemius SDK** – Updated WordPress SDK to 2.13.4.
507 +
508 += 5.5.2 =
509 +
510 +* **Fix: [copy] shortcode display with `content` attribute and inner markup** – When the legacy `content` attribute sets the clipboard payload and the shortcode also wraps inner content (for example `[copy content="/path/to/file"]Install path[/copy]`), the visible label now uses the inner content for `display` while `text` remains what gets copied. Previously the label could fall back to the same value as `content` and ignore the wrapped text.
511 +* **Improvement: Compatibility to WordPress 6.9.4** – The plugin is now compatible with WordPress 6.9.4 and the latest Gutenberg plugin.
512 +
513 += 5.5.1 =
514 +
515 +* **Fix: Highlight.js / code block copy formatting** – Copy buttons added via Global Injector to `pre` and `code` blocks (including themes using Highlight.js, such as the setup on zanglikun.com) now preserve indentation and whitespace when copying, so Java / PHP / shell snippets paste exactly as shown instead of being flattened into a single left-aligned block. Thanks to Likun Zang for reporting the issue.
516 +* **Fix: [copy] shortcode in table cells** – `[copy]` inside table plugins (Data Tables Generator by Supsystic, wpDataTables) now works correctly. Scripts and styles load when the table shortcode is on the page, and copy controls work with cached or dynamically rendered table content. Thanks to [@jayceezay](https://wordpress.org/support/users/jayceezay/) for reporting. See: https://wordpress.org/support/topic/copy-shortcode-in-table-cells-not-working-anymore/
517 +* **Fix: Thrive Architect HTML block integration** – Copy buttons rendered inside a Thrive Architect HTML block (for example, custom blockquotes with `ctc-wrapper` markup) are now reliably detected and bound by the frontend script, so clicking the button correctly copies the content even when the HTML is pre-rendered or cached.
518 +* **Improvement: Shortcode copy buttons (event delegation)** – Copy buttons from `[copy]` shortcodes now use document-level event delegation, so buttons added dynamically (e.g. by table plugins after page load) remain clickable.
519 +* **Improvement: Code / pre support in Global Injector** – Global Injector rules targeting `pre` / `code` elements now integrate more safely with external highlighters and pre-rendered content, ensuring the “Copy Anything to Clipboard” behavior stays consistent without breaking existing theme or page builder output.
520 +
521 += 5.5.0 =
522 +
523 +* **New: Gutenberg block analytics (Pro)** - Copy events from all Gutenberg copy blocks (Copy to Clipboard Icon, Copy Icon, and Copy Button) are now tracked as `source = 'gutenberg-block'` in the same analytics table. Pro Analytics dashboard shows a three-way source breakdown (Global Injector, Shortcodes, Gutenberg Blocks) and a Block by page view so you can see which pages drive the most Gutenberg block copy events.
524 +* **Improvement: Gutenberg block tracking** - Gutenberg copy block output includes `data-ctc-analytics` and `data-ctc-source="gutenberg-block"`; frontend sends analytics to `POST /ctc/v1/analytics/events` after each copy (non-blocking). Block scripts and styles still load only when the relevant block is present on the page.
525 +
526 += 5.4.2 =
527 +
528 +* **Fix: Icon block frontend scripts only load when block is present** - Icon block (Copy to Clipboard) styles and copy script are now enqueued only on pages that contain the Icon block, using `has_block( 'copy-the-code/icon' )`. This avoids loading assets on every page and improves performance when the block is not used.
529 +
530 += 5.4.1 =
531 +
532 +* **New: Telemetry opt-in** - Anonymized usage data can be shared to help improve the plugin. Opt-in is available from the welcome notice and via Settings → Dashboard; data is sent only when enabled and is cleaned on uninstall.
533 +* **Improvement: Copy-by-source analytics and telemetry summary (Pro)** - Analytics now includes a breakdown by copy source and a telemetry summary for opted-in usage insights.
534 +* **Improvement: Uninstall cleanup** - Telemetry and related options are removed when the plugin is uninstalled.
535 +* **Fix: Freemius not loading** - Resolved an issue where Freemius SDK could fail to load in some environments.
536 +
537 += 5.4.0 =
538 +
539 +* **New: Shortcode analytics + per-shortcode opt-out (Pro)** - Shortcode-based copy events are now tracked as `source = 'shortcode'` with post and page context, alongside Global Injector events. You can disable tracking for specific shortcodes via an `analytics` attribute (for example, `[copy analytics="off"]Code[/copy]` still copies but does not record analytics for that instance).
540 +* **New: Source breakdown & shortcode-by-page (Pro)** - The detailed Analytics endpoint now includes a Global Injector vs Shortcodes source breakdown and a shortcode-by-page view so you can see which pages and shortcodes drive the most copy events.
541 +* **Improvement: Volume vs Prior card accuracy** - The Volume vs Prior card now shows `/ N prev` whenever previous-period data exists (including `0`), reserving `-- prev` only for truly missing data, and uses clearer trend labels for trending vs lagging periods.
542 +* **Improvement: Free vs Pro previews in Analytics UI** - Free users see a blurred preview for Pro-only source breakdown data so the UI is no longer misleading; Pro users see real counts, percentages, and growth.
543 +* **Improvement: Version consistency & cache-busting** - Unified plugin version across the header, `CTC_VER` constant, core class, composer, and readme. Release tooling (`npm run version:check` / `version:set`) now fails on mismatches and keeps all version fields in sync, preventing stale assets and updater drift.
544 +* **Fix: Coupon widget copy button label** - The Elementor coupon widget now passes the correct config keys to the shared copy button helper, and the helper accepts both legacy (`copy_button_text`) and new (`button_text`) keys so the custom button text from widget settings always renders as expected.
545 +* **Fix: Preserve zero-valued style settings** - Global Injector rule meta now treats saved `'0'` values (e.g. blur, border width, padding) as valid instead of falling back to defaults, so zero-style configurations are applied consistently after saving.
546 +* **Security: Safer external links** - All plugin-generated links that open in a new tab (`target="_blank"`) now include `rel="noopener noreferrer"` to guard against reverse-tabnabbing and improve cross-window isolation.
547 +* **Security: Pro analytics limited to admins** - Pro analytics REST endpoints now require the `manage_options` capability, preventing non-admin users from accessing analytics data even if they obtain a valid REST nonce.
548 +* **Security: Analytics abuse protections** - The public analytics event endpoint (`POST /ctc/v1/analytics/events`) now enforces per-IP rate limiting and strict payload validation, returning `429` on abusive bursts and `400` for invalid event data to protect the `ctc_analytics` table.
549 +* **Improvement: Analytics timezone normalization** - Analytics events and query windows now consistently use UTC for `created_at` and date ranges, preventing shifted 24h/7d/30d boundaries on non-UTC sites.
550 +* **Improvement: Analytics retention & cleanup** - Older analytics events beyond roughly 13 months are now pruned in small batches by a daily scheduled cleanup job (retention days and batch size are filterable), keeping the `ctc_analytics` table fast while still supporting long-range comparisons.
551 +* **Fix: Emojis in code blocks now copied correctly** - WordPress renders emojis as `<img class="emoji">` elements; the copy logic now converts these to their `alt` text so emojis are included in the copied content. [Thanks @jayceezay](https://wordpress.org/support/topic/emojis-in-code-blocks-not-being-copied/)
552 +
553 += 5.3.1 =
554 +
555 +* **Fix: [copy] shortcode with formatted content** - When the shortcode encloses formatted text (e.g. bold), the front end now displays the formatting and copies plain text to the clipboard. Display uses allowed HTML (filterable); copy uses plain text unless `copy-as="html"`. [Thanks @jayceezay](https://wordpress.org/support/topic/copy-shortcode-is-broken/)
556 +* **New (developer):** Filter `ctc/shortcode/display_allowed_html` to customize allowed HTML for shortcode display content (e.g. add custom markup support).
557 +
558 += 5.3.0 =
559 +
560 +* **New: Analytics (Pro)** - See what gets copied. Copy tracking for Global Injector rules: track copy events per rule (rule ID, timestamp, success; no content stored). Analytics dashboard at Settings → Analytics: summary cards (total copies, active rules, top rule, % change), date range filter (24h, 7d, 30d, custom), activity chart, top rules table. Export CSV (Pro).
561 +* **New: Activity column in Main Rule List** - Copy count and 24h % change per rule. Free: count + blurred trend + Pro CTA; Pro: real trend. Link from Activity to Analytics filtered by rule.
562 +* **New: REST API for analytics** - `POST /ctc/v1/analytics/events` (public, for frontend tracking); GET endpoints and export for authenticated Pro users.
563 +* **Improvement: Global Injector** - Analytics option/link in rule editor and dashboard to open Analytics page (filtered by rule when applicable).
564 +
565 += 5.2.0 =
566 +
567 +* **New: Copy As (Clipboard Type)** - Choose what gets copied per rule: Text only, HTML, Text + HTML (default), Image (Pro), JSON (Pro), SVG (Pro). Global Injector Rule Editor includes "Copy as" section; shortcode and Gutenberg blocks support `copy-as` attribute. Uses CTC CopyEngine with Clipboard API; fallbacks for image (HTTPS/CORS) and legacy browsers.
568 +* **New: Image format for Copy As Image (Pro)** - Choose PNG, JPEG, or WebP when copying as image. Pro adds Image format selector in Copy As section; free plugin provides `ctc.globalInjector.copyAs.after` hook for extensibility.
569 +* **Improvement: Copy As extensibility** - Free plugin now uses `ctc.globalInjector.copyAs.after` hook; Pro plugin renders Image format UI (PNG/JPEG/WebP) when Copy As is Image Blob. Follows Rank Math free/Pro pattern.
570 +* **Improvement: Pro extension points** - Added `ctc/global_injector/rule_enum_fields`, `ctc/global_injector/rest_rule_data` filters; `ctc.globalInjector.fieldsToCompare` for unsaved-changes detection. Pro adds image_format via extend_meta_mapping, extend_admin_rule_data, extend_frontend_rule_data.
571 +* **New: ImageFormatSection (Pro)** - Pro component for Image format selection with ButtonGroup and docs link.
572 +* **Fix: Image format persistence** - Image format selection now persists after save and page refresh (load_rules and REST get_rule_data include image_format when Pro is active).
573 +
574 += 5.1.0 =
575 +
576 +* **New: Main Rule List** - Custom rules UI at Settings → Global Injector (`page=ctc-rules`): table with Status toggle, Rule Name/Target, Visual Style, Location; row actions Edit, Duplicate, Delete; search and status filter; empty state.
577 +* **New: Dashboard (Home)** - Copy to Clipboard dashboard at `page=ctc` (Settings → Copy to Clipboard).
578 +* **New: Shared admin components** - AdminHeader, ConfirmModal, Footer, Icons, ProBadge used by Dashboard, Main Rule List, and Rule Editor.
579 +* **Improvement: Rule Editor** - Header uses shared AdminHeader with back link to Global Rules list.
580 +* **Improvement: Legacy CPT redirects** - "Add New" and list edit links for `copy-to-clipboard` redirect to Global Injector.
581 +* **Developer:** `get_admin_rules()` API for admin list data; Main Rule List and Dashboard use React + Tailwind under `.ctc-admin-root`.
582 +* **Improvement: Global Injector CSS from PHP** - Global Injector styles (Button, Icon, Cover) are now output as minified inline CSS from PHP via the new Inline_CSS class. Only the styles and positions used by active rules are included; the `ctc/global_injector/inline_css` filter still applies to the final CSS.
583 +* **Fix: Cover style fatal error** - Added missing `get_global_injector_css()` method to the Cover style class so inline CSS builds correctly when Cover style is used (fixes "Call to undefined method Cover::get_global_injector_css()").
584 +* **New: Admin bar quick-edit for Global Injector** - When viewing a page where Global Injector rules apply, admins see a "CTC" item (with clipboard icon) in the admin bar. Sub-items list "Edit: [Rule name]" for each rule on the page and open the Global Injector settings with that rule selected.
585 +* **Improvement: Global Injector URL support** - The settings page now supports a `?rule=ID` query parameter to open the editor with a specific rule selected (e.g. from the admin bar or bookmarks). Added `get_selected_rule_id()` helper.
586 +* **New: Shortcode `redirect` attribute** - The `[copy]` shortcode now supports a `redirect` attribute for copy-then-redirect flows (e.g. `[copy redirect="https://store.com"]CODE10[/copy]`). After copying, the user is sent to the given URL. The existing `link` attribute remains supported for backward compatibility and has the same effect as `redirect`.
587 +* **Fix: Shortcode display text with inner content** - When both `text` and inner content are present (e.g. `[copy text="Hello World"]Copy this[/copy]`), the visible label now uses the inner content ("Copy this") and `text` is used only for the copy payload. Previously the label showed the `text` value.
588 +* **Fix: Native preset CSS when using tag="a"** - Using `tag="a"` for link-style copy buttons now correctly loads the native preset CSS so theme link styling is applied.
589 +* **Fix: Shortcode `link` attribute redirect** - The "Copy & Redirect" / "Combining Multiple Attributes" flow now works: when `link="https://example.com"` is set, the shortcode outputs `data-ctc-link` and the frontend opens the URL in a new tab after a successful copy (e.g. after "Copied! Redirecting...").
590 +* **Improvement: Shortcode performance** - Inline CSS for the shortcode is now output only for presets actually used on the page (inline, native, button, icon, cover), and the CSS is minified to reduce payload size.
591 +* **Improvement: Global Injector rules sidebar** - When opening the settings page with a specific rule (e.g. `?rule=318`), the selected rule is now scrolled to the top of the rules list within the sidebar only, without scrolling the whole page or moving the admin header out of view.
592 +* **Fix: Giant copy icons in tables** - Added explicit `width` and `height` attributes (24×24) to all Global Injector SVG icons (Button, Icon, and Cover styles) so theme CSS cannot scale them unexpectedly inside table cells. [Thanks @akashathu](https://wordpress.org/support/topic/giant-icons-in-table/)
593 +
594 += 5.0.1 =
595 +
596 +**Bug fixes and support issues (post-5.0.0)** — Thanks to the users who reported these on the [support forum](https://wordpress.org/support/plugin/copy-the-code/).
597 +
598 +* **Fix: 404 on ctc.js** - Moved script to `assets/frontend/js/lib/ctc.js` (renamed from vendor/ to avoid .gitignore conflict). Global Injector and shortcode enqueue the copy engine; fallbacks remain when script is unavailable. [Thanks @contemplate](https://wordpress.org/support/topic/404-js-file/)
599 +* **Fix: Giant copy icons in tables** - Copy icons inside table cells no longer scale with table font-size. Added CSS constraints for shortcode and block copy icons when inside `table` elements.
600 +* **Fix: Square brackets in shortcode content** - Legacy shortcodes using `content="... &#91;...&#93; ..."` now copy the correct `[` and `]` characters. The `content` attribute is decoded from HTML entities before use.
601 +* **Fix: Shortcode script loading** - Shortcode frontend script no longer depends on the removed vendor script; it loads independently with Clipboard API fallbacks.
602 +
603 += 5.0.0 =
604 +
605 +**🚀 Major Release - Global Injector & Complete Refactor**
606 +
607 +* **New: Global Injector** - Advanced copy button injection system with:
608 + * Display conditions to control where copy buttons appear
609 + * Multiple style presets (Button, Icon, Cover)
610 + * Live preview in the editor
611 + * Performance-optimized asset loading
612 +* **New: Refined Shortcode System** - Enhanced `[copy]` / `[ctc]` shortcodes with improved attributes and flexibility.
613 +* **New: Style Presets** - Pre-built button, icon, and cover styles for quick setup.
614 +* **Improvement: WordPress 6.7+ Compatibility** - Fixed `_load_textdomain_just_in_time` notices with proper plugin initialization timing.
615 +* **Improvement: Complete Asset Restructure** - Reorganized frontend and admin assets for better performance.
616 +* **Improvement: Gutenberg Block Enhancements** - Fixed block registration and optimized editor asset loading.
617 +* **Improvement: Freemius SDK Integration** - Improved SDK initialization with proper hook timing.
618 +* **Improvement: Code Quality** - Major codebase refactoring with improved naming conventions and standards.
619 +* **Fix: Block Editor Assets** - Resolved "invalid category" warnings for Gutenberg blocks.
620 +* **Fix: Frontend Script Loading** - Fixed 404 errors for clipboard scripts after asset restructure.
621 +* **Fix: Square Brackets in Shortcode** - Fixed HTML entities (`&#91;` `&#93;`) not being decoded properly in `content` attribute. [Thanks @akashathu](https://wordpress.org/support/topic/issue-with-square-brackets/)
622 +* **Fix: CSS var() Double Dashes** - Fixed WordPress converting `--` to en-dash inside CSS `var()` functions like `var(--wp--preset--color--bg)`. [Thanks @mikecargal](https://wordpress.org/support/topic/converted-to-2/)
623 +* **Fix: Legacy Shortcode `content` Attribute** - Restored proper handling where `content` attribute contains the text to copy and `text` attribute is the display text.
624 +* **New: Native Anchor Support** - Added `tag="a"` parameter to use theme's anchor styling instead of custom CTC styling.
625 +* **New: Icon Toggle** - Added `show-icon="no"` parameter to hide the copy icon when not needed.
626 +* **Developer: New Architecture** - Modular class-based architecture for better extensibility.
627 +
628 += 4.1.2 =
629 +
630 +* Fixed: iOS 26 compatibility issue by migrating from deprecated `document.execCommand('copy')` to modern Clipboard API (`navigator.clipboard.writeText()`).
631 +* Improvement: Added fallback support for older browsers that don't support the Clipboard API.
632 +* Improvement: Enhanced clipboard functionality across all copy methods (CSS selector, shortcode, Elementor widgets, and Gutenberg blocks).
633 +
634 += 4.1.1 =
635 +
636 +* Fix: Dependency build failed.
637 +
638 += 4.1.0 =
639 +
640 +* Improvement: Updated Freemius SDK library with version 2.13.0.
641 +* Improvement: Updated plugin metadata for compatibility with WordPress 6.8.
642 +* Improvement: Enhanced readme content, tags, and FAQ for better search visibility.
643 +
644 += 4.0.5 =
645 +
646 +* Improvement: Updated Freemius SDK library with version 2.11.0.
647 +* Improvement: Compatibility to WordPress 6.7.2.
648 +
649 += 4.0.4 =
650 +
651 +* Fixed: Disallow to add script for the contributor level user in the shortcode.
652 +* Improvement: Updated Freemius SDK library with version 2.9.0.
653 +* Improvement: Compatibility to WordPress 6.7.1.
654 +
655 += 4.0.3 =
656 +
657 +* Hot fix: The dependency not works for post types.
658 +
659 += 4.0.2 =
660 +
661 +* Fix: The js dependency not works for the shortcode.
662 +
663 += 4.0.0 =
664 +
665 +* New: Added the Gutenberg block "Term Title".
666 +* New: Added the Gutenberg block "Social Share".
667 +* New: Added the Gutenberg block "Copy Button".
668 +* New: Added the Gutenberg block "Copy Icon".
669 +* Improvement: Updated Freemius SDK library with version 2.7.4.
670 +* Improvement: Compatibility to WordPress 6.6.1.
671 +
672 += 3.8.3 =
673 +
674 +* Improvement: Updated the recurring cron job registration logic.
675 +
676 += 3.8.2 =
677 +
678 +* Fixed: Elementor copy button not works due to missing dependency.
679 +
680 += 3.8.1 =
681 +
682 +* Fixed: The copy animation not works for the shortcode.
683 +* Improvement: Compatibility to WordPress 6.5.3.
684 +
685 += 3.8.0 =
686 +
687 +* New: Added display conditions for the copy to clipboard to load the assets only on selected pages.
688 +* Improvement: Fixed the copy icon Gutenberg block title issue.
689 +* Improvement: Loading the Gutenberg block assets only on the block used pages.
690 +* Improvement: Added default copied button text.
691 +* Improvement: Compatibility to WordPress 6.5.2.
692 +
693 += 3.7.0 =
694 +
695 +* New: Added the copy icon Gutenberg block.
696 +
190 697 = 3.6.0 =
191 698
192 699 * New: Added the target selector support for the copy content in the Elementor widget.
193 700 * Improvement: Added to support to copy the markup content from the Copy Icon Elementor widget.
@@ -264,46 +769,9 @@
264 769 * Improvement: Improved the Elementor "Copy to Clipboard Icon" widget controls and structure.
265 770
266 771 = 3.1.0 =
267 772
268 -* New: Added button styling support for Elementor widget Copy Icon.
269 -* New: Added button styling support for Elementor widget Copy Button.
270 -* New: Added button styling support for Elementor widget Email Sample.
271 -* New: Added button styling support for Elementor widget Email Address.
272 -* New: Added button styling support for Elementor widget Phone Number.
273 -* New: Added button styling support for Elementor widget Blockquote.
274 -* New: Added button styling support for Elementor widget Code Snippet.
275 -* New: Added button styling support for Elementor widget Message.
276 -* New: Added button styling support for Elementor widget Deal.
277 -* New: Added button styling support for Elementor widget Coupon.
278 -* New: Added button styling support for Elementor widget AI Prompt Generator.
279 -* Improvement: Updated Freemius SDK version 2.6.0.
280 -
281 -= 3.2.1 =
282 -
283 -* Improvement: Improved the Elementor "Coupon Code" widget controls and structure.
284 -* Improvement: Improved the Elementor "Deal" widget controls and structure.
285 -* Improvement: Improved the Elementor "Email Address" widget controls and structure.
286 -* Improvement: Improved the Elementor "Email Sample" widget controls and structure.
287 -* Improvement: Improved the Elementor "Message" widget controls and structure.
288 -* Improvement: Improved the Elementor "Phone Number" widget controls and structure.
289 -* Improvement: Improved the Elementor "Shayari" widget controls and structure.
290 -* Improvement: Improved the Elementor "SMS" widget controls and structure.
291 -* Improvement: Improved the Elementor "Wish" widget controls and structure.
292 -
293 -= 3.2.0 =
294 -
295 -* New: Added the Elementor widget category "Copy Anything to Clipboard".
296 -* Improvement: Compatibility to WordPress 6.4.1.
297 -* Improvement: Improved the Elementor "AI Prompt Generator" widget controls and structure.
298 -* Improvement: Improved the Elementor "Blockquote" widget controls and structure.
299 -* Improvement: Improved the Elementor "Code Snippet" widget controls and structure.
300 -* Improvement: Improved the Elementor "Copy to Clipboard Button" widget controls and structure.
301 -* Improvement: Improved the Elementor "Copy to Clipboard Icon" widget controls and structure.
302 -
303 -= 3.1.0 =
304 -
305 -* New: Added new shortcode [copy_inline] which allow you to copy content from the inline element.
773 +* New: Added inline-style copy shortcode for paragraph-level snippets (unified under `[copy]` in v5+).
306 774 * New: Added Elementor widget Copy Icon.
307 775 * New: Added Elementor widget Copy Button.
308 776 * New: Added Elementor widget Email Sample.
309 777 * New: Added Elementor widget Email Address.
@@ -369,9 +837,8 @@
369 837 = 2.4.1 =
370 838
371 839 * Improvement: Added the sub-menus page links into the post type screen.
372 840 * Improvement: Removed the sub-menus Dashboard, Contact Us, Upgrade, and Support Forum.
373 -
374 841
375 842 = 2.4.0 =
376 843
377 844 * New: Integrated the Freemius library for automatic updates, upgrade and for quick support.