| @@ -10,14 +10,10 @@ | ||
| 10 | 10 | <div class="wrap copy-the-code"> |
| 11 | 11 | <div class="wrap"> |
| 12 | 12 | <h1><?php echo esc_html( COPY_THE_CODE_TITLE ); ?> <small>v<?php echo esc_html( COPY_THE_CODE_VER ); ?></small></h1> |
| 13 | 13 | |
| 14 | - <p> | |
| 15 | - <a href="<?php echo admin_url( 'edit.php?post_type=copy-to-clipboard' ); ?>" class="button">Back to List</a> | |
| 16 | - </p> | |
| 14 | + <p class="description"><?php _e( 'Add the new button as per your requirement. See more with <a href="https://maheshwaghmare.com/doc/copy-anything-to-clipboard/" target="_blank">getting started guide</a>', 'copy-the-code' ); ?></p> | |
| 17 | 15 | |
| 18 | - <p class="description"><?php _e( 'Add the new button as per your requirement. See more with <a target="_blank" href="https://clipboard.agency/doc/" target="_blank">getting started guide</a>', 'copy-the-code' ); ?></p> | |
| 19 | - | |
| 20 | 16 | <div id="poststuff"> |
| 21 | 17 | <div id="post-body" class="columns-2"> |
| 22 | 18 | <div id="post-body-content"> |
| 23 | 19 | |
| @@ -59,21 +55,8 @@ | ||
| 59 | 55 | </select> |
| 60 | 56 | <p class="description"><?php _e( 'Button Position Inside/Outside. Default Inside.', 'copy-the-code' ); ?></p> |
| 61 | 57 | </fieldset> |
| 62 | 58 | </td> |
| 63 | - </tr> | |
| 64 | - <tr> | |
| 65 | - <th scope="row"><?php _e( 'Copy Format', 'copy-the-code' ); ?></th> | |
| 66 | - <td> | |
| 67 | - <fieldset> | |
| 68 | - <select name="copy-format" class="copy-format"> | |
| 69 | - <option value="default" <?php selected( $data['copy-format'], 'default' ); ?>><?php echo 'Default'; ?></option> | |
| 70 | - <option value="google-docs" <?php selected( $data['copy-format'], 'google-docs' ); ?>><?php echo 'Google Docs'; ?></option> | |
| 71 | - <option value="email" <?php selected( $data['copy-format'], 'email' ); ?>><?php echo 'Email'; ?></option> | |
| 72 | - </select> | |
| 73 | - <p class="description"><?php _e( 'Copy the content for specific format.', 'copy-the-code' ); ?></p> | |
| 74 | - </fieldset> | |
| 75 | - </td> | |
| 76 | 59 | </tr> |
| 77 | 60 | </table> |
| 78 | 61 | </div> |
| 79 | 62 | <div id="tab-style"> |
| @@ -118,238 +101,19 @@ | ||
| 118 | 101 | <div class="postbox-container" id="postbox-container-1"> |
| 119 | 102 | <h3>Preview:</h3> |
| 120 | 103 | <div id="preview"></div> |
| 121 | 104 | |
| 122 | - <?php | |
| 123 | - /** | |
| 124 | - * Customization Options | |
| 125 | - */ | |
| 126 | - $stored = get_option( 'ctc_default_style' ); | |
| 127 | - if ( empty( $stored ) ) { | |
| 128 | - $stored = array(); | |
| 129 | - } | |
| 130 | - | |
| 131 | - $data = array( | |
| 132 | - 'btn_color' => isset( $stored['btn_color'] ) ? $stored['btn_color'] : '#424242', | |
| 133 | - 'btn_bg_color' => isset( $stored['btn_bg_color'] ) ? $stored['btn_bg_color'] : '#e1e3e8', | |
| 134 | - 'btn_font_size' => isset( $stored['btn_font_size'] ) ? $stored['btn_font_size'] : '14', | |
| 135 | - 'btn_line_height' => isset( $stored['btn_line_height'] ) ? $stored['btn_line_height'] : '18', | |
| 136 | - 'btn_t_padding' => isset( $stored['btn_t_padding'] ) ? $stored['btn_t_padding'] : '10', | |
| 137 | - 'btn_r_padding' => isset( $stored['btn_r_padding'] ) ? $stored['btn_r_padding'] : '20', | |
| 138 | - 'btn_b_padding' => isset( $stored['btn_b_padding'] ) ? $stored['btn_b_padding'] : '10', | |
| 139 | - 'btn_l_padding' => isset( $stored['btn_l_padding'] ) ? $stored['btn_l_padding'] : '20', | |
| 140 | - 'btn_l_margin' => isset( $stored['btn_l_margin'] ) ? $stored['btn_l_margin'] : '0', | |
| 141 | - 'btn_t_margin' => isset( $stored['btn_t_margin'] ) ? $stored['btn_t_margin'] : '0', | |
| 142 | - 'btn_r_margin' => isset( $stored['btn_r_margin'] ) ? $stored['btn_r_margin'] : '0', | |
| 143 | - 'btn_b_margin' => isset( $stored['btn_b_margin'] ) ? $stored['btn_b_margin'] : '0', | |
| 144 | - 'btn_tl_radius' => isset( $stored['btn_tl_radius'] ) ? $stored['btn_tl_radius'] : '0', | |
| 145 | - 'btn_tr_radius' => isset( $stored['btn_tr_radius'] ) ? $stored['btn_tr_radius'] : '0', | |
| 146 | - 'btn_br_radius' => isset( $stored['btn_br_radius'] ) ? $stored['btn_br_radius'] : '0', | |
| 147 | - 'btn_bl_radius' => isset( $stored['btn_bl_radius'] ) ? $stored['btn_bl_radius'] : '0', | |
| 148 | - 'btn_h_color' => isset( $stored['btn_h_color'] ) ? $stored['btn_h_color'] : '#424242', | |
| 149 | - 'btn_h_bg_color' => isset( $stored['btn_h_bg_color'] ) ? $stored['btn_h_bg_color'] : '#d0d1d6', | |
| 150 | - | |
| 151 | - // SVG Icon | |
| 152 | - 'svg_icon_color' => isset( $stored['svg_icon_color'] ) ? $stored['svg_icon_color'] : '#23282d', | |
| 153 | - 'svg_icon_h_color' => isset( $stored['svg_icon_h_color'] ) ? $stored['svg_icon_h_color'] : '#23282d', | |
| 154 | - 'svg_icon_width' => isset( $stored['svg_icon_width'] ) ? $stored['svg_icon_width'] : '20', | |
| 155 | - 'svg_icon_t_padding' => isset( $stored['svg_icon_t_padding'] ) ? $stored['svg_icon_t_padding'] : '10', | |
| 156 | - 'svg_icon_r_padding' => isset( $stored['svg_icon_r_padding'] ) ? $stored['svg_icon_r_padding'] : '10', | |
| 157 | - 'svg_icon_b_padding' => isset( $stored['svg_icon_b_padding'] ) ? $stored['svg_icon_b_padding'] : '10', | |
| 158 | - 'svg_icon_l_padding' => isset( $stored['svg_icon_l_padding'] ) ? $stored['svg_icon_l_padding'] : '10', | |
| 159 | - | |
| 160 | - // Cover | |
| 161 | - 'cover_color' => isset( $stored['cover_color'] ) ? $stored['cover_color'] : '#ffffff', | |
| 162 | - 'cover_font_size' => isset( $stored['cover_font_size'] ) ? $stored['cover_font_size'] : '14', | |
| 163 | - ); | |
| 164 | - $is_free = ctc_fs()->is_not_paying() ? 'is-free' : 'is-pro'; | |
| 165 | - ?> | |
| 166 | - <form id="ctc-style-form" class="<?php echo $is_free; ?>"> | |
| 167 | - | |
| 168 | - <?php if ( ctc_fs()->is_not_paying() ) { ?> | |
| 169 | - <div class="upgrade"> | |
| 170 | - <a href="<?php echo ctc_fs()->get_upgrade_url(); ?>"> | |
| 171 | - <?php esc_html_e( 'Upgrade to Premium to Access', 'copy-the-code' ); ?> | |
| 172 | - </a> | |
| 173 | - </div> | |
| 174 | - <?php } ?> | |
| 175 | - | |
| 176 | - <table class="style-svg-icon widefat striped"> | |
| 177 | - <tr> | |
| 178 | - <th colspan="2"> | |
| 179 | - <b>Normal Style</b> | |
| 180 | - </th> | |
| 181 | - </tr> | |
| 182 | - <tr> | |
| 183 | - <td>Icon Color</td> | |
| 184 | - <td> | |
| 185 | - <input type="color" class="ctc-svg-icon-color" name="ctc-svg-icon-color" value="<?php echo $data['svg_icon_color']; ?>" /> | |
| 186 | - </td> | |
| 187 | - </tr> | |
| 188 | - <tr> | |
| 189 | - <td>Icon Size</td> | |
| 190 | - <td> | |
| 191 | - <input type="number" class="ctc-svg-icon-width" name="ctc-svg-icon-width" value="<?php echo $data['svg_icon_width']; ?>" /> | |
| 192 | - </td> | |
| 193 | - </tr> | |
| 194 | - <tr> | |
| 195 | - <td>Icon Padding</td> | |
| 196 | - <td> | |
| 197 | - <input type="number" class="ctc-svg-icon-t-padding" name="ctc-svg-icon-t-padding" value="<?php echo $data['svg_icon_t_padding']; ?>" /> | |
| 198 | - <input type="number" class="ctc-svg-icon-r-padding" name="ctc-svg-icon-r-padding" value="<?php echo $data['svg_icon_r_padding']; ?>" /> | |
| 199 | - <input type="number" class="ctc-svg-icon-b-padding" name="ctc-svg-icon-b-padding" value="<?php echo $data['svg_icon_b_padding']; ?>" /> | |
| 200 | - <input type="number" class="ctc-svg-icon-l-padding" name="ctc-svg-icon-l-padding" value="<?php echo $data['svg_icon_l_padding']; ?>" /> | |
| 201 | - </td> | |
| 202 | - </tr> | |
| 203 | - <tr> | |
| 204 | - <th colspan="2"> | |
| 205 | - <b>Hover Style</b> | |
| 206 | - </th> | |
| 207 | - </tr> | |
| 208 | - <tr> | |
| 209 | - <td>Icon Color</td> | |
| 210 | - <td> | |
| 211 | - <input type="color" class="ctc-svg-icon-h-color" name="ctc-svg-icon-h-color" value="<?php echo $data['svg_icon_h_color']; ?>" /> | |
| 212 | - </td> | |
| 213 | - </tr> | |
| 214 | - <tr> | |
| 215 | - <td colspan="2" align="right"> | |
| 216 | - <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'ctc-save-style' ); ?>" /> | |
| 217 | - <input type="submit" class="button button-primary" value="Save Changes" /> | |
| 218 | - </td> | |
| 219 | - </tr> | |
| 220 | - </table> | |
| 221 | - <table class="style-cover widefat striped"> | |
| 222 | - <tr> | |
| 223 | - <td>Text Color</td> | |
| 224 | - <td> | |
| 225 | - <input type="color" class="ctc-cover-color" name="ctc-cover-color" value="<?php echo $data['cover_color']; ?>" /> | |
| 226 | - </td> | |
| 227 | - </tr> | |
| 228 | - <tr> | |
| 229 | - <td>Font Size</td> | |
| 230 | - <td> | |
| 231 | - <input type="number" class="ctc-cover-font-size" name="ctc-cover-font-size" value="<?php echo $data['cover_font_size']; ?>" /> | |
| 232 | - </tr> | |
| 233 | - <tr> | |
| 234 | - <tr> | |
| 235 | - <td colspan="2" align="right"> | |
| 236 | - <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'ctc-save-style' ); ?>" /> | |
| 237 | - <input type="submit" class="button button-primary" value="Save Changes" /> | |
| 238 | - </td> | |
| 239 | - </tr> | |
| 240 | - </table> | |
| 241 | - <table class="style-button widefat striped"> | |
| 242 | - <tr> | |
| 243 | - <th colspan="2"> | |
| 244 | - <b>Normal Style</b> | |
| 245 | - </th> | |
| 246 | - </tr> | |
| 247 | - <tr> | |
| 248 | - <td>Button Color</td> | |
| 249 | - <td> | |
| 250 | - <input type="color" class="ctc-btn-color" name="ctc-btn-color" value="<?php echo $data['btn_color']; ?>" /> | |
| 251 | - </td> | |
| 252 | - </tr> | |
| 253 | - <tr> | |
| 254 | - <td>Button Background Color</td> | |
| 255 | - <td> | |
| 256 | - <input type="color" class="ctc-btn-bg-color" name="ctc-btn-bg-color" value="<?php echo $data['btn_bg_color']; ?>" /> | |
| 257 | - </td> | |
| 258 | - </tr> | |
| 259 | - <tr> | |
| 260 | - <td>Font Size</td> | |
| 261 | - <td> | |
| 262 | - <input type="number" class="ctc-btn-font-size" name="ctc-btn-font-size" value="<?php echo $data['btn_font_size']; ?>" /> | |
| 263 | - </tr> | |
| 264 | - <tr> | |
| 265 | - <td>Line Height</td> | |
| 266 | - <td> | |
| 267 | - <input type="number" class="ctc-btn-line-height" name="ctc-btn-line-height" value="<?php echo $data['btn_line_height']; ?>" /> | |
| 268 | - </td> | |
| 269 | - </tr> | |
| 270 | - <tr> | |
| 271 | - <td>Button Padding</td> | |
| 272 | - <td> | |
| 273 | - <input type="number" class="ctc-btn-t-padding" name="ctc-btn-t-padding" value="<?php echo $data['btn_t_padding']; ?>" /> | |
| 274 | - <input type="number" class="ctc-btn-r-padding" name="ctc-btn-r-padding" value="<?php echo $data['btn_r_padding']; ?>" /> | |
| 275 | - <input type="number" class="ctc-btn-b-padding" name="ctc-btn-b-padding" value="<?php echo $data['btn_b_padding']; ?>" /> | |
| 276 | - <input type="number" class="ctc-btn-l-padding" name="ctc-btn-l-padding" value="<?php echo $data['btn_l_padding']; ?>" /> | |
| 277 | - </td> | |
| 278 | - </tr> | |
| 279 | - <tr> | |
| 280 | - <td>Button Margin</td> | |
| 281 | - <td> | |
| 282 | - <input type="number" class="ctc-btn-t-margin" name="ctc-btn-t-margin" value="<?php echo $data['btn_t_margin']; ?>" /> | |
| 283 | - <input type="number" class="ctc-btn-r-margin" name="ctc-btn-r-margin" value="<?php echo $data['btn_r_margin']; ?>" /> | |
| 284 | - <input type="number" class="ctc-btn-b-margin" name="ctc-btn-b-margin" value="<?php echo $data['btn_b_margin']; ?>" /> | |
| 285 | - <input type="number" class="ctc-btn-l-margin" name="ctc-btn-l-margin" value="<?php echo $data['btn_l_margin']; ?>" /> | |
| 286 | - </td> | |
| 287 | - </tr> | |
| 288 | - <tr> | |
| 289 | - <td>Border Radius</td> | |
| 290 | - <td> | |
| 291 | - <input type="number" class="ctc-btn-tl-radius" name="ctc-btn-tl-radius" value="<?php echo $data['btn_tl_radius']; ?>" /> | |
| 292 | - <input type="number" class="ctc-btn-tr-radius" name="ctc-btn-tr-radius" value="<?php echo $data['btn_tr_radius']; ?>" /> | |
| 293 | - <input type="number" class="ctc-btn-br-radius" name="ctc-btn-br-radius" value="<?php echo $data['btn_br_radius']; ?>" /> | |
| 294 | - <input type="number" class="ctc-btn-bl-radius" name="ctc-btn-bl-radius" value="<?php echo $data['btn_bl_radius']; ?>" /> | |
| 295 | - </td> | |
| 296 | - </tr> | |
| 297 | - <tr> | |
| 298 | - <th colspan="2"> | |
| 299 | - <b>Hover Style</b> | |
| 300 | - </th> | |
| 301 | - </tr> | |
| 302 | - <tr> | |
| 303 | - <td>Button Color</td> | |
| 304 | - <td> | |
| 305 | - <input type="color" class="ctc-btn-h-color" name="ctc-btn-h-color" value="<?php echo $data['btn_h_color']; ?>" /> | |
| 306 | - </td> | |
| 307 | - </tr> | |
| 308 | - <tr> | |
| 309 | - <td>Button Background Color</td> | |
| 310 | - <td> | |
| 311 | - <input type="color" class="ctc-btn-h-bg-color" name="ctc-btn-h-bg-color" value="<?php echo $data['btn_h_bg_color']; ?>" /> | |
| 312 | - </td> | |
| 313 | - </tr> | |
| 314 | - <tr> | |
| 315 | - <td colspan="2" align="right"> | |
| 316 | - <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'ctc-save-style' ); ?>" /> | |
| 317 | - <input type="submit" class="button button-primary" value="Save Changes" /> | |
| 318 | - </td> | |
| 319 | - </tr> | |
| 320 | - </table> | |
| 321 | - </form> | |
| 322 | - | |
| 323 | 105 | <div class="postbox"> |
| 324 | 106 | <h2 class="hndle"><span><?php _e( 'Getting Started', 'copy-the-code' ); ?></span></h2> |
| 325 | 107 | <div class="inside"> |
| 326 | - <div class="table-of-contents"> | |
| 327 | - <ol class="items"> | |
| 328 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Way 1 - Copy with Shortcode</a> | |
| 329 | - <ol> | |
| 330 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Example 1: Copy Same Display Text in | |
| 331 | - Clipboard</a></li> | |
| 332 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Example 2: Copy Different | |
| 333 | - Text than Display Text in Clipboard</a></li> | |
| 334 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Shortcode Parameters</a> | |
| 335 | - </li> | |
| 336 | - </ol> | |
| 337 | - </li> | |
| 338 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Way 2 - Copy with Target</a> | |
| 339 | - <ol> | |
| 340 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Use Case 1: How to add the copy | |
| 341 | - button to Blockquote</a></li> | |
| 342 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Use Case 2: How to add the copy | |
| 343 | - button to Code Snippet</a></li> | |
| 344 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Use Case 3: How to add the copy button | |
| 345 | - to HTML list</a> | |
| 346 | - </li> | |
| 347 | - </ol> | |
| 348 | - </li> | |
| 349 | - <li><a target="_blank" href="https://clipboard.agency/doc/">Other Customizations</a></li> | |
| 350 | - </ol> | |
| 351 | - </div> | |
| 108 | + <ul class="items"> | |
| 109 | + <li>» <a style="text-decoration: none;" target="_blank" href="https://maheshwaghmare.com/doc/copy-anything-to-clipboard/#how-does-it-work"><?php esc_html_e( 'How does it work?', 'copy-the-code' ); ?></a></li> | |
| 110 | + <li>» <a style="text-decoration: none;" target="_blank" href="https://maheshwaghmare.com/doc/copy-anything-to-clipboard/#what-is-the-selector"><?php esc_html_e( 'What is the selector?', 'copy-the-code' ); ?></a></li> | |
| 111 | + <li>» <a style="text-decoration: none;" target="_blank" href="https://maheshwaghmare.com/doc/copy-anything-to-clipboard/#example-1-using-html-tag-as-a-selector"><?php esc_html_e( 'Example 1 - Using HTML tag as a selector', 'copy-the-code' ); ?></a></li> | |
| 112 | + <li>» <a style="text-decoration: none;" target="_blank" href="https://maheshwaghmare.com/doc/copy-anything-to-clipboard/#example-2-using-class-as-a-selector"><?php esc_html_e( 'Example 2 - Using class as a selector', 'copy-the-code' ); ?></a></li> | |
| 113 | + <li>» <a style="text-decoration: none;" target="_blank" href="https://maheshwaghmare.com/doc/copy-anything-to-clipboard/#example-3-using-id-as-a-selector"><?php esc_html_e( 'Example 3 - Using ID as a selector', 'copy-the-code' ); ?></a></li> | |
| 114 | + <li>» <a style="text-decoration: none;" target="_blank" href="https://maheshwaghmare.com/doc/copy-anything-to-clipboard/#example-4-using-nested-selector"><?php esc_html_e( 'Example 4 - Using nested selector', 'copy-the-code' ); ?></a></li> | |
| 115 | + </ul> | |
| 352 | 116 | </div> |
| 353 | 117 | </div> |
| 354 | 118 | |
| 355 | 119 | <div class="postbox"> |
| @@ -355,22 +119,19 @@ | ||
| 355 | 119 | <div class="postbox"> |
| 356 | 120 | <h2 class="hndle"><span><?php _e( 'Support', 'copy-the-code' ); ?></span></h2> |
| 357 | 121 | <div class="inside"> |
| 358 | 122 | <p><?php _e( 'Do you have any issue with this plugin? Or Do you have any suggessions?', 'copy-the-code' ); ?></p> |
| 359 | - <p><?php _e( 'Please don\'t hesitate to <a href="https://clipboard.agency/doc/" target="_blank">send request »</a>.', 'copy-the-code' ); ?></p> | |
| 123 | + <p><?php _e( 'Please don\'t hesitate to <a href="http://maheshwaghmare.wordpress.com/?p=999" target="_blank">send request »</a>.', 'copy-the-code' ); ?></p> | |
| 360 | 124 | </div> |
| 361 | 125 | </div> |
| 362 | 126 | |
| 363 | - <?php if ( ctc_fs()->is_not_paying() ) { ?> | |
| 364 | - <div class="postbox"> | |
| 365 | - <h2 class="hndle"><span><?php _e( 'Donate', 'copy-the-code' ); ?></span></h2> | |
| 366 | - <div class="inside"> | |
| 367 | - <p><?php _e( 'Would you like to support the advancement of this plugin?', 'copy-the-code' ); ?></p> | |
| 368 | - <a href="https://www.paypal.me/mwaghmare7/" target="_blank" class="button button-primary"><?php _e( 'Donate Now!', 'copy-the-code' ); ?></a> | |
| 369 | - </div> | |
| 127 | + <div class="postbox"> | |
| 128 | + <h2 class="hndle"><span><?php _e( 'Donate', 'copy-the-code' ); ?></span></h2> | |
| 129 | + <div class="inside"> | |
| 130 | + <p><?php _e( 'Would you like to support the advancement of this plugin?', 'copy-the-code' ); ?></p> | |
| 131 | + <a href="https://www.paypal.me/mwaghmare7/" target="_blank" class="button button-primary"><?php _e( 'Donate Now!', 'copy-the-code' ); ?></a> | |
| 370 | 132 | </div> |
| 371 | - <?php } ?> | |
| 372 | - | |
| 133 | + </div> | |
| 373 | 134 | </div> |
| 374 | 135 | </div> |
| 375 | 136 | </div> |
| 376 | 137 | </div> |